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

Percentage Accurate: 98.4% → 98.4%
Time: 10.7s
Alternatives: 22
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ \frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))
double code(double x, double y, double z, double t, double a, double b) {
	return (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

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

real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    code = (x * exp((((y * log(z)) + ((t - 1.0d0) * log(a))) - b))) / y
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	return (x * Math.exp((((y * Math.log(z)) + ((t - 1.0) * Math.log(a))) - b))) / y;
}
def code(x, y, z, t, a, b):
	return (x * math.exp((((y * math.log(z)) + ((t - 1.0) * math.log(a))) - b))) / y
function code(x, y, z, t, a, b)
	return Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) + Float64(Float64(t - 1.0) * log(a))) - b))) / y)
end
function tmp = code(x, y, z, t, a, b)
	tmp = (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] + N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]
\begin{array}{l}

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 22 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: 98.4% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))
double code(double x, double y, double z, double t, double a, double b) {
	return (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

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

real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    code = (x * exp((((y * log(z)) + ((t - 1.0d0) * log(a))) - b))) / y
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	return (x * Math.exp((((y * Math.log(z)) + ((t - 1.0) * Math.log(a))) - b))) / y;
}
def code(x, y, z, t, a, b):
	return (x * math.exp((((y * math.log(z)) + ((t - 1.0) * math.log(a))) - b))) / y
function code(x, y, z, t, a, b)
	return Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) + Float64(Float64(t - 1.0) * log(a))) - b))) / y)
end
function tmp = code(x, y, z, t, a, b)
	tmp = (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] + N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]
\begin{array}{l}

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

Alternative 1: 98.4% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))
double code(double x, double y, double z, double t, double a, double b) {
	return (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

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

real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    code = (x * exp((((y * log(z)) + ((t - 1.0d0) * log(a))) - b))) / y
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	return (x * Math.exp((((y * Math.log(z)) + ((t - 1.0) * Math.log(a))) - b))) / y;
}
def code(x, y, z, t, a, b):
	return (x * math.exp((((y * math.log(z)) + ((t - 1.0) * math.log(a))) - b))) / y
function code(x, y, z, t, a, b)
	return Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) + Float64(Float64(t - 1.0) * log(a))) - b))) / y)
end
function tmp = code(x, y, z, t, a, b)
	tmp = (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] + N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]
\begin{array}{l}

\\
\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}
\end{array}
Derivation
  1. Initial program 98.3%

    \[\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y} \]
  2. Add Preprocessing
  3. Add Preprocessing

Alternative 2: 45.5% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
t_1 := \frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\\
\mathbf{if}\;t\_1 \leq -2 \cdot 10^{-188}:\\
\;\;\;\;\frac{\frac{x}{a}}{y}\\

\mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+14}:\\
\;\;\;\;\frac{x}{\mathsf{fma}\left(\left(-b\right) \cdot \mathsf{fma}\left(-0.5 \cdot y, a, \left(-a\right) \cdot \frac{y}{b}\right), b, a \cdot y\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y) < -1.9999999999999999e-188

    1. Initial program 98.8%

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

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

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

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

        \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
      4. exp-diffN/A

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

        \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
      6. exp-to-powN/A

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

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

        \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
      9. lower-exp.f64N/A

        \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
      10. lower-/.f6459.0

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

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

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

        \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
      2. Taylor expanded in b around 0

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

          \[\leadsto \frac{x}{a \cdot y} \]
        2. Taylor expanded in b around 0

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

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

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

          1. Initial program 97.3%

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

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

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

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

              \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
            4. exp-diffN/A

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

              \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
            6. exp-to-powN/A

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

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

              \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
            9. lower-exp.f64N/A

              \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
            10. lower-/.f6458.8

              \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
          5. Applied rewrites58.8%

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

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

              \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
            2. Taylor expanded in b around 0

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

                \[\leadsto \frac{x}{\mathsf{fma}\left(\mathsf{fma}\left(\left(b \cdot y\right) \cdot a, 0.5, a \cdot y\right), b, a \cdot y\right)} \]
              2. Taylor expanded in b around -inf

                \[\leadsto \frac{x}{\mathsf{fma}\left(-1 \cdot \left(b \cdot \left(-1 \cdot \frac{a \cdot y}{b} + \frac{-1}{2} \cdot \left(a \cdot y\right)\right)\right), b, a \cdot y\right)} \]
              3. Step-by-step derivation
                1. Applied rewrites59.5%

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

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

                1. Initial program 99.3%

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

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

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

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

                    \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                  4. exp-diffN/A

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

                    \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                  6. exp-to-powN/A

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

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

                    \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                  9. lower-exp.f64N/A

                    \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                  10. lower-/.f6454.1

                    \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                5. Applied rewrites54.1%

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

                  \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                7. Step-by-step derivation
                  1. Applied rewrites51.9%

                    \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                  2. Taylor expanded in b around 0

                    \[\leadsto -1 \cdot \frac{b \cdot x}{a \cdot y} + \frac{x}{\color{blue}{a \cdot y}} \]
                  3. Step-by-step derivation
                    1. Applied rewrites38.5%

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

                  Alternative 3: 43.9% accurate, 0.5× speedup?

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

                    1. Initial program 99.2%

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

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

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

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

                        \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                      4. exp-to-powN/A

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

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

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

                        \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                      8. exp-to-powN/A

                        \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot \color{blue}{{z}^{y}}\right)}{y} \]
                      9. lower-pow.f6472.2

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

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

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

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

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

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

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

                            \[\leadsto \frac{x \cdot \frac{1}{a}}{y} \]

                          if -4.0000000000000001e133 < (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y) < 2e143

                          1. Initial program 97.0%

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

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

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

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

                              \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                            4. exp-diffN/A

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

                              \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                            6. exp-to-powN/A

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

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

                              \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                            9. lower-exp.f64N/A

                              \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                            10. lower-/.f6460.8

                              \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                          5. Applied rewrites60.8%

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

                            \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                          7. Step-by-step derivation
                            1. Applied rewrites53.9%

                              \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                            2. Taylor expanded in b around 0

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

                                \[\leadsto \frac{x}{\mathsf{fma}\left(\mathsf{fma}\left(\left(b \cdot y\right) \cdot a, 0.5, a \cdot y\right), b, a \cdot y\right)} \]
                              2. Taylor expanded in b around inf

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

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

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

                                1. Initial program 99.6%

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

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

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

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

                                    \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                  4. exp-diffN/A

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

                                    \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                  6. exp-to-powN/A

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

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

                                    \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                  9. lower-exp.f64N/A

                                    \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                  10. lower-/.f6452.9

                                    \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                5. Applied rewrites52.9%

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

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

                                    \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                  2. Taylor expanded in b around 0

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

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

                                  Alternative 4: 40.3% accurate, 0.5× speedup?

                                  \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\\ \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+133}:\\ \;\;\;\;\frac{x \cdot \frac{1}{a}}{y}\\ \mathbf{elif}\;t\_1 \leq 0:\\ \;\;\;\;\frac{x}{\mathsf{fma}\left(b, y, y\right) \cdot a}\\ \mathbf{else}:\\ \;\;\;\;\frac{\mathsf{fma}\left(-x, b, x\right)}{a \cdot y}\\ \end{array} \end{array} \]
                                  (FPCore (x y z t a b)
                                   :precision binary64
                                   (let* ((t_1 (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y)))
                                     (if (<= t_1 -4e+133)
                                       (/ (* x (/ 1.0 a)) y)
                                       (if (<= t_1 0.0) (/ x (* (fma b y y) a)) (/ (fma (- x) b x) (* a y))))))
                                  double code(double x, double y, double z, double t, double a, double b) {
                                  	double t_1 = (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
                                  	double tmp;
                                  	if (t_1 <= -4e+133) {
                                  		tmp = (x * (1.0 / a)) / y;
                                  	} else if (t_1 <= 0.0) {
                                  		tmp = x / (fma(b, y, y) * a);
                                  	} else {
                                  		tmp = fma(-x, b, x) / (a * y);
                                  	}
                                  	return tmp;
                                  }
                                  
                                  function code(x, y, z, t, a, b)
                                  	t_1 = Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) + Float64(Float64(t - 1.0) * log(a))) - b))) / y)
                                  	tmp = 0.0
                                  	if (t_1 <= -4e+133)
                                  		tmp = Float64(Float64(x * Float64(1.0 / a)) / y);
                                  	elseif (t_1 <= 0.0)
                                  		tmp = Float64(x / Float64(fma(b, y, y) * a));
                                  	else
                                  		tmp = Float64(fma(Float64(-x), b, x) / Float64(a * y));
                                  	end
                                  	return tmp
                                  end
                                  
                                  code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] + N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]}, If[LessEqual[t$95$1, -4e+133], N[(N[(x * N[(1.0 / a), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[t$95$1, 0.0], N[(x / N[(N[(b * y + y), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision], N[(N[((-x) * b + x), $MachinePrecision] / N[(a * y), $MachinePrecision]), $MachinePrecision]]]]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  \begin{array}{l}
                                  t_1 := \frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\\
                                  \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+133}:\\
                                  \;\;\;\;\frac{x \cdot \frac{1}{a}}{y}\\
                                  
                                  \mathbf{elif}\;t\_1 \leq 0:\\
                                  \;\;\;\;\frac{x}{\mathsf{fma}\left(b, y, y\right) \cdot a}\\
                                  
                                  \mathbf{else}:\\
                                  \;\;\;\;\frac{\mathsf{fma}\left(-x, b, x\right)}{a \cdot y}\\
                                  
                                  
                                  \end{array}
                                  \end{array}
                                  
                                  Derivation
                                  1. Split input into 3 regimes
                                  2. if (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y) < -4.0000000000000001e133

                                    1. Initial program 99.2%

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

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

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

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

                                        \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                      4. exp-to-powN/A

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

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

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

                                        \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                      8. exp-to-powN/A

                                        \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot \color{blue}{{z}^{y}}\right)}{y} \]
                                      9. lower-pow.f6472.2

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

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

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

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

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

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

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

                                            \[\leadsto \frac{x \cdot \frac{1}{a}}{y} \]

                                          if -4.0000000000000001e133 < (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y) < 0.0

                                          1. Initial program 98.0%

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

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

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

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

                                              \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                            4. exp-diffN/A

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

                                              \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                            6. exp-to-powN/A

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

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

                                              \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                            9. lower-exp.f64N/A

                                              \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                            10. lower-/.f6458.8

                                              \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                          5. Applied rewrites58.8%

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

                                            \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                                          7. Step-by-step derivation
                                            1. Applied rewrites51.4%

                                              \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                            2. Taylor expanded in b around 0

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

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

                                              if 0.0 < (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y)

                                              1. Initial program 98.0%

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

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

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

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

                                                  \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                4. exp-diffN/A

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

                                                  \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                6. exp-to-powN/A

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

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

                                                  \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                9. lower-exp.f64N/A

                                                  \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                10. lower-/.f6456.4

                                                  \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                              5. Applied rewrites56.4%

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

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

                                                  \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                2. Taylor expanded in b around 0

                                                  \[\leadsto -1 \cdot \frac{b \cdot x}{a \cdot y} + \frac{x}{\color{blue}{a \cdot y}} \]
                                                3. Step-by-step derivation
                                                  1. Applied rewrites41.6%

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

                                                Alternative 5: 40.3% accurate, 0.5× speedup?

                                                \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\\ \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+133}:\\ \;\;\;\;\frac{\frac{x}{a}}{y}\\ \mathbf{elif}\;t\_1 \leq 0:\\ \;\;\;\;\frac{x}{\mathsf{fma}\left(b, y, y\right) \cdot a}\\ \mathbf{else}:\\ \;\;\;\;\frac{\mathsf{fma}\left(-x, b, x\right)}{a \cdot y}\\ \end{array} \end{array} \]
                                                (FPCore (x y z t a b)
                                                 :precision binary64
                                                 (let* ((t_1 (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y)))
                                                   (if (<= t_1 -4e+133)
                                                     (/ (/ x a) y)
                                                     (if (<= t_1 0.0) (/ x (* (fma b y y) a)) (/ (fma (- x) b x) (* a y))))))
                                                double code(double x, double y, double z, double t, double a, double b) {
                                                	double t_1 = (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
                                                	double tmp;
                                                	if (t_1 <= -4e+133) {
                                                		tmp = (x / a) / y;
                                                	} else if (t_1 <= 0.0) {
                                                		tmp = x / (fma(b, y, y) * a);
                                                	} else {
                                                		tmp = fma(-x, b, x) / (a * y);
                                                	}
                                                	return tmp;
                                                }
                                                
                                                function code(x, y, z, t, a, b)
                                                	t_1 = Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) + Float64(Float64(t - 1.0) * log(a))) - b))) / y)
                                                	tmp = 0.0
                                                	if (t_1 <= -4e+133)
                                                		tmp = Float64(Float64(x / a) / y);
                                                	elseif (t_1 <= 0.0)
                                                		tmp = Float64(x / Float64(fma(b, y, y) * a));
                                                	else
                                                		tmp = Float64(fma(Float64(-x), b, x) / Float64(a * y));
                                                	end
                                                	return tmp
                                                end
                                                
                                                code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] + N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]}, If[LessEqual[t$95$1, -4e+133], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[t$95$1, 0.0], N[(x / N[(N[(b * y + y), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision], N[(N[((-x) * b + x), $MachinePrecision] / N[(a * y), $MachinePrecision]), $MachinePrecision]]]]
                                                
                                                \begin{array}{l}
                                                
                                                \\
                                                \begin{array}{l}
                                                t_1 := \frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\\
                                                \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+133}:\\
                                                \;\;\;\;\frac{\frac{x}{a}}{y}\\
                                                
                                                \mathbf{elif}\;t\_1 \leq 0:\\
                                                \;\;\;\;\frac{x}{\mathsf{fma}\left(b, y, y\right) \cdot a}\\
                                                
                                                \mathbf{else}:\\
                                                \;\;\;\;\frac{\mathsf{fma}\left(-x, b, x\right)}{a \cdot y}\\
                                                
                                                
                                                \end{array}
                                                \end{array}
                                                
                                                Derivation
                                                1. Split input into 3 regimes
                                                2. if (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y) < -4.0000000000000001e133

                                                  1. Initial program 99.2%

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

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

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

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

                                                      \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                    4. exp-diffN/A

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

                                                      \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                    6. exp-to-powN/A

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

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

                                                      \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                    9. lower-exp.f64N/A

                                                      \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                    10. lower-/.f6456.8

                                                      \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                  5. Applied rewrites56.8%

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

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

                                                      \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                    2. Taylor expanded in b around 0

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

                                                        \[\leadsto \frac{x}{a \cdot y} \]
                                                      2. Taylor expanded in b around 0

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

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

                                                        if -4.0000000000000001e133 < (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y) < 0.0

                                                        1. Initial program 98.0%

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

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

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

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

                                                            \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                          4. exp-diffN/A

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

                                                            \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                          6. exp-to-powN/A

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

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

                                                            \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                          9. lower-exp.f64N/A

                                                            \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                          10. lower-/.f6458.8

                                                            \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                        5. Applied rewrites58.8%

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

                                                          \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                                                        7. Step-by-step derivation
                                                          1. Applied rewrites51.4%

                                                            \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                          2. Taylor expanded in b around 0

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

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

                                                            if 0.0 < (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y)

                                                            1. Initial program 98.0%

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

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

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

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

                                                                \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                              4. exp-diffN/A

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

                                                                \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                              6. exp-to-powN/A

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

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

                                                                \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                              9. lower-exp.f64N/A

                                                                \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                              10. lower-/.f6456.4

                                                                \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                            5. Applied rewrites56.4%

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

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

                                                                \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                              2. Taylor expanded in b around 0

                                                                \[\leadsto -1 \cdot \frac{b \cdot x}{a \cdot y} + \frac{x}{\color{blue}{a \cdot y}} \]
                                                              3. Step-by-step derivation
                                                                1. Applied rewrites41.6%

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

                                                              Alternative 6: 39.5% accurate, 0.5× speedup?

                                                              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\\ \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+133} \lor \neg \left(t\_1 \leq 5 \cdot 10^{-54}\right):\\ \;\;\;\;\frac{\frac{x}{a}}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{\mathsf{fma}\left(b, y, y\right) \cdot a}\\ \end{array} \end{array} \]
                                                              (FPCore (x y z t a b)
                                                               :precision binary64
                                                               (let* ((t_1 (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y)))
                                                                 (if (or (<= t_1 -4e+133) (not (<= t_1 5e-54)))
                                                                   (/ (/ x a) y)
                                                                   (/ x (* (fma b y y) a)))))
                                                              double code(double x, double y, double z, double t, double a, double b) {
                                                              	double t_1 = (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
                                                              	double tmp;
                                                              	if ((t_1 <= -4e+133) || !(t_1 <= 5e-54)) {
                                                              		tmp = (x / a) / y;
                                                              	} else {
                                                              		tmp = x / (fma(b, y, y) * a);
                                                              	}
                                                              	return tmp;
                                                              }
                                                              
                                                              function code(x, y, z, t, a, b)
                                                              	t_1 = Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) + Float64(Float64(t - 1.0) * log(a))) - b))) / y)
                                                              	tmp = 0.0
                                                              	if ((t_1 <= -4e+133) || !(t_1 <= 5e-54))
                                                              		tmp = Float64(Float64(x / a) / y);
                                                              	else
                                                              		tmp = Float64(x / Float64(fma(b, y, y) * a));
                                                              	end
                                                              	return tmp
                                                              end
                                                              
                                                              code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] + N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -4e+133], N[Not[LessEqual[t$95$1, 5e-54]], $MachinePrecision]], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision], N[(x / N[(N[(b * y + y), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision]]]
                                                              
                                                              \begin{array}{l}
                                                              
                                                              \\
                                                              \begin{array}{l}
                                                              t_1 := \frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\\
                                                              \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+133} \lor \neg \left(t\_1 \leq 5 \cdot 10^{-54}\right):\\
                                                              \;\;\;\;\frac{\frac{x}{a}}{y}\\
                                                              
                                                              \mathbf{else}:\\
                                                              \;\;\;\;\frac{x}{\mathsf{fma}\left(b, y, y\right) \cdot a}\\
                                                              
                                                              
                                                              \end{array}
                                                              \end{array}
                                                              
                                                              Derivation
                                                              1. Split input into 2 regimes
                                                              2. if (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y) < -4.0000000000000001e133 or 5.00000000000000015e-54 < (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y)

                                                                1. Initial program 99.2%

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

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

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

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

                                                                    \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                  4. exp-diffN/A

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

                                                                    \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                  6. exp-to-powN/A

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

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

                                                                    \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                  9. lower-exp.f64N/A

                                                                    \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                  10. lower-/.f6455.7

                                                                    \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                5. Applied rewrites55.7%

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

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

                                                                    \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                  2. Taylor expanded in b around 0

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

                                                                      \[\leadsto \frac{x}{a \cdot y} \]
                                                                    2. Taylor expanded in b around 0

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

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

                                                                      if -4.0000000000000001e133 < (/.f64 (*.f64 x (exp.f64 (-.f64 (+.f64 (*.f64 y (log.f64 z)) (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))) b))) y) < 5.00000000000000015e-54

                                                                      1. Initial program 97.2%

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

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

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

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

                                                                          \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                        4. exp-diffN/A

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

                                                                          \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                        6. exp-to-powN/A

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

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

                                                                          \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                        9. lower-exp.f64N/A

                                                                          \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                        10. lower-/.f6459.9

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

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

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

                                                                          \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                        2. Taylor expanded in b around 0

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

                                                                            \[\leadsto \frac{x}{\mathsf{fma}\left(b, y, y\right) \cdot a} \]
                                                                        4. Recombined 2 regimes into one program.
                                                                        5. Final simplification42.4%

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

                                                                        Alternative 7: 92.5% accurate, 0.6× speedup?

                                                                        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(t - 1\right) \cdot \log a\\ \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+72} \lor \neg \left(t\_1 \leq 1000\right):\\ \;\;\;\;\frac{x \cdot e^{\log a \cdot t - b}}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot e^{\mathsf{fma}\left(\log z, y, -\log a\right) - b}}{y}\\ \end{array} \end{array} \]
                                                                        (FPCore (x y z t a b)
                                                                         :precision binary64
                                                                         (let* ((t_1 (* (- t 1.0) (log a))))
                                                                           (if (or (<= t_1 -1e+72) (not (<= t_1 1000.0)))
                                                                             (/ (* x (exp (- (* (log a) t) b))) y)
                                                                             (/ (* x (exp (- (fma (log z) y (- (log a))) b))) y))))
                                                                        double code(double x, double y, double z, double t, double a, double b) {
                                                                        	double t_1 = (t - 1.0) * log(a);
                                                                        	double tmp;
                                                                        	if ((t_1 <= -1e+72) || !(t_1 <= 1000.0)) {
                                                                        		tmp = (x * exp(((log(a) * t) - b))) / y;
                                                                        	} else {
                                                                        		tmp = (x * exp((fma(log(z), y, -log(a)) - b))) / y;
                                                                        	}
                                                                        	return tmp;
                                                                        }
                                                                        
                                                                        function code(x, y, z, t, a, b)
                                                                        	t_1 = Float64(Float64(t - 1.0) * log(a))
                                                                        	tmp = 0.0
                                                                        	if ((t_1 <= -1e+72) || !(t_1 <= 1000.0))
                                                                        		tmp = Float64(Float64(x * exp(Float64(Float64(log(a) * t) - b))) / y);
                                                                        	else
                                                                        		tmp = Float64(Float64(x * exp(Float64(fma(log(z), y, Float64(-log(a))) - b))) / y);
                                                                        	end
                                                                        	return tmp
                                                                        end
                                                                        
                                                                        code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -1e+72], N[Not[LessEqual[t$95$1, 1000.0]], $MachinePrecision]], N[(N[(x * N[Exp[N[(N[(N[Log[a], $MachinePrecision] * t), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(N[(x * N[Exp[N[(N[(N[Log[z], $MachinePrecision] * y + (-N[Log[a], $MachinePrecision])), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]]
                                                                        
                                                                        \begin{array}{l}
                                                                        
                                                                        \\
                                                                        \begin{array}{l}
                                                                        t_1 := \left(t - 1\right) \cdot \log a\\
                                                                        \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+72} \lor \neg \left(t\_1 \leq 1000\right):\\
                                                                        \;\;\;\;\frac{x \cdot e^{\log a \cdot t - b}}{y}\\
                                                                        
                                                                        \mathbf{else}:\\
                                                                        \;\;\;\;\frac{x \cdot e^{\mathsf{fma}\left(\log z, y, -\log a\right) - b}}{y}\\
                                                                        
                                                                        
                                                                        \end{array}
                                                                        \end{array}
                                                                        
                                                                        Derivation
                                                                        1. Split input into 2 regimes
                                                                        2. if (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < -9.99999999999999944e71 or 1e3 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))

                                                                          1. Initial program 100.0%

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

                                                                            \[\leadsto \frac{x \cdot e^{\color{blue}{t \cdot \log a} - b}}{y} \]
                                                                          4. Step-by-step derivation
                                                                            1. *-commutativeN/A

                                                                              \[\leadsto \frac{x \cdot e^{\color{blue}{\log a \cdot t} - b}}{y} \]
                                                                            2. lower-*.f64N/A

                                                                              \[\leadsto \frac{x \cdot e^{\color{blue}{\log a \cdot t} - b}}{y} \]
                                                                            3. lower-log.f6491.0

                                                                              \[\leadsto \frac{x \cdot e^{\color{blue}{\log a} \cdot t - b}}{y} \]
                                                                          5. Applied rewrites91.0%

                                                                            \[\leadsto \frac{x \cdot e^{\color{blue}{\log a \cdot t} - b}}{y} \]

                                                                          if -9.99999999999999944e71 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < 1e3

                                                                          1. Initial program 96.9%

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

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

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

                                                                              \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z + \color{blue}{\log a \cdot -1}\right) - b}}{y} \]
                                                                            3. fp-cancel-sign-sub-invN/A

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

                                                                              \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \color{blue}{\left(\mathsf{neg}\left(\log a \cdot -1\right)\right)}\right) - b}}{y} \]
                                                                            5. distribute-rgt-neg-outN/A

                                                                              \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \color{blue}{\log a \cdot \left(\mathsf{neg}\left(-1\right)\right)}\right) - b}}{y} \]
                                                                            6. metadata-evalN/A

                                                                              \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \log a \cdot \color{blue}{1}\right) - b}}{y} \]
                                                                            7. fp-cancel-sub-sign-invN/A

                                                                              \[\leadsto \frac{x \cdot e^{\color{blue}{\left(y \cdot \log z + \left(\mathsf{neg}\left(\log a\right)\right) \cdot 1\right)} - b}}{y} \]
                                                                            8. *-commutativeN/A

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

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

                                                                              \[\leadsto \frac{x \cdot e^{\left(\log z \cdot y + \color{blue}{\log a \cdot \left(\mathsf{neg}\left(1\right)\right)}\right) - b}}{y} \]
                                                                            11. metadata-evalN/A

                                                                              \[\leadsto \frac{x \cdot e^{\left(\log z \cdot y + \log a \cdot \color{blue}{-1}\right) - b}}{y} \]
                                                                            12. *-commutativeN/A

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

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

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

                                                                              \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, \color{blue}{\mathsf{neg}\left(\log a\right)}\right) - b}}{y} \]
                                                                            16. lower-neg.f64N/A

                                                                              \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, \color{blue}{-\log a}\right) - b}}{y} \]
                                                                            17. lower-log.f6495.9

                                                                              \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, -\color{blue}{\log a}\right) - b}}{y} \]
                                                                          5. Applied rewrites95.9%

                                                                            \[\leadsto \frac{x \cdot e^{\color{blue}{\mathsf{fma}\left(\log z, y, -\log a\right)} - b}}{y} \]
                                                                        3. Recombined 2 regimes into one program.
                                                                        4. Final simplification93.6%

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

                                                                        Alternative 8: 75.0% accurate, 0.7× speedup?

                                                                        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(t - 1\right) \cdot \log a\\ t_2 := e^{b} \cdot y\\ t_3 := \frac{{a}^{\left(t - 1\right)}}{y} \cdot x\\ \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+74}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;t\_1 \leq -195:\\ \;\;\;\;\frac{x}{t\_2 \cdot a}\\ \mathbf{elif}\;t\_1 \leq 10^{+89}:\\ \;\;\;\;\frac{\frac{x}{t\_2}}{a}\\ \mathbf{else}:\\ \;\;\;\;t\_3\\ \end{array} \end{array} \]
                                                                        (FPCore (x y z t a b)
                                                                         :precision binary64
                                                                         (let* ((t_1 (* (- t 1.0) (log a)))
                                                                                (t_2 (* (exp b) y))
                                                                                (t_3 (* (/ (pow a (- t 1.0)) y) x)))
                                                                           (if (<= t_1 -2e+74)
                                                                             t_3
                                                                             (if (<= t_1 -195.0)
                                                                               (/ x (* t_2 a))
                                                                               (if (<= t_1 1e+89) (/ (/ x t_2) a) t_3)))))
                                                                        double code(double x, double y, double z, double t, double a, double b) {
                                                                        	double t_1 = (t - 1.0) * log(a);
                                                                        	double t_2 = exp(b) * y;
                                                                        	double t_3 = (pow(a, (t - 1.0)) / y) * x;
                                                                        	double tmp;
                                                                        	if (t_1 <= -2e+74) {
                                                                        		tmp = t_3;
                                                                        	} else if (t_1 <= -195.0) {
                                                                        		tmp = x / (t_2 * a);
                                                                        	} else if (t_1 <= 1e+89) {
                                                                        		tmp = (x / t_2) / a;
                                                                        	} else {
                                                                        		tmp = t_3;
                                                                        	}
                                                                        	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) :: t_2
                                                                            real(8) :: t_3
                                                                            real(8) :: tmp
                                                                            t_1 = (t - 1.0d0) * log(a)
                                                                            t_2 = exp(b) * y
                                                                            t_3 = ((a ** (t - 1.0d0)) / y) * x
                                                                            if (t_1 <= (-2d+74)) then
                                                                                tmp = t_3
                                                                            else if (t_1 <= (-195.0d0)) then
                                                                                tmp = x / (t_2 * a)
                                                                            else if (t_1 <= 1d+89) then
                                                                                tmp = (x / t_2) / a
                                                                            else
                                                                                tmp = t_3
                                                                            end if
                                                                            code = tmp
                                                                        end function
                                                                        
                                                                        public static double code(double x, double y, double z, double t, double a, double b) {
                                                                        	double t_1 = (t - 1.0) * Math.log(a);
                                                                        	double t_2 = Math.exp(b) * y;
                                                                        	double t_3 = (Math.pow(a, (t - 1.0)) / y) * x;
                                                                        	double tmp;
                                                                        	if (t_1 <= -2e+74) {
                                                                        		tmp = t_3;
                                                                        	} else if (t_1 <= -195.0) {
                                                                        		tmp = x / (t_2 * a);
                                                                        	} else if (t_1 <= 1e+89) {
                                                                        		tmp = (x / t_2) / a;
                                                                        	} else {
                                                                        		tmp = t_3;
                                                                        	}
                                                                        	return tmp;
                                                                        }
                                                                        
                                                                        def code(x, y, z, t, a, b):
                                                                        	t_1 = (t - 1.0) * math.log(a)
                                                                        	t_2 = math.exp(b) * y
                                                                        	t_3 = (math.pow(a, (t - 1.0)) / y) * x
                                                                        	tmp = 0
                                                                        	if t_1 <= -2e+74:
                                                                        		tmp = t_3
                                                                        	elif t_1 <= -195.0:
                                                                        		tmp = x / (t_2 * a)
                                                                        	elif t_1 <= 1e+89:
                                                                        		tmp = (x / t_2) / a
                                                                        	else:
                                                                        		tmp = t_3
                                                                        	return tmp
                                                                        
                                                                        function code(x, y, z, t, a, b)
                                                                        	t_1 = Float64(Float64(t - 1.0) * log(a))
                                                                        	t_2 = Float64(exp(b) * y)
                                                                        	t_3 = Float64(Float64((a ^ Float64(t - 1.0)) / y) * x)
                                                                        	tmp = 0.0
                                                                        	if (t_1 <= -2e+74)
                                                                        		tmp = t_3;
                                                                        	elseif (t_1 <= -195.0)
                                                                        		tmp = Float64(x / Float64(t_2 * a));
                                                                        	elseif (t_1 <= 1e+89)
                                                                        		tmp = Float64(Float64(x / t_2) / a);
                                                                        	else
                                                                        		tmp = t_3;
                                                                        	end
                                                                        	return tmp
                                                                        end
                                                                        
                                                                        function tmp_2 = code(x, y, z, t, a, b)
                                                                        	t_1 = (t - 1.0) * log(a);
                                                                        	t_2 = exp(b) * y;
                                                                        	t_3 = ((a ^ (t - 1.0)) / y) * x;
                                                                        	tmp = 0.0;
                                                                        	if (t_1 <= -2e+74)
                                                                        		tmp = t_3;
                                                                        	elseif (t_1 <= -195.0)
                                                                        		tmp = x / (t_2 * a);
                                                                        	elseif (t_1 <= 1e+89)
                                                                        		tmp = (x / t_2) / a;
                                                                        	else
                                                                        		tmp = t_3;
                                                                        	end
                                                                        	tmp_2 = tmp;
                                                                        end
                                                                        
                                                                        code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[Exp[b], $MachinePrecision] * y), $MachinePrecision]}, Block[{t$95$3 = N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision]}, If[LessEqual[t$95$1, -2e+74], t$95$3, If[LessEqual[t$95$1, -195.0], N[(x / N[(t$95$2 * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 1e+89], N[(N[(x / t$95$2), $MachinePrecision] / a), $MachinePrecision], t$95$3]]]]]]
                                                                        
                                                                        \begin{array}{l}
                                                                        
                                                                        \\
                                                                        \begin{array}{l}
                                                                        t_1 := \left(t - 1\right) \cdot \log a\\
                                                                        t_2 := e^{b} \cdot y\\
                                                                        t_3 := \frac{{a}^{\left(t - 1\right)}}{y} \cdot x\\
                                                                        \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+74}:\\
                                                                        \;\;\;\;t\_3\\
                                                                        
                                                                        \mathbf{elif}\;t\_1 \leq -195:\\
                                                                        \;\;\;\;\frac{x}{t\_2 \cdot a}\\
                                                                        
                                                                        \mathbf{elif}\;t\_1 \leq 10^{+89}:\\
                                                                        \;\;\;\;\frac{\frac{x}{t\_2}}{a}\\
                                                                        
                                                                        \mathbf{else}:\\
                                                                        \;\;\;\;t\_3\\
                                                                        
                                                                        
                                                                        \end{array}
                                                                        \end{array}
                                                                        
                                                                        Derivation
                                                                        1. Split input into 3 regimes
                                                                        2. if (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < -1.9999999999999999e74 or 9.99999999999999995e88 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))

                                                                          1. Initial program 100.0%

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

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

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

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

                                                                              \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                                                            4. exp-to-powN/A

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

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

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

                                                                              \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                                                            8. exp-to-powN/A

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

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

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

                                                                            \[\leadsto \frac{x \cdot e^{\log a \cdot \left(t - 1\right)}}{y} \]
                                                                          7. Step-by-step derivation
                                                                            1. Applied rewrites82.6%

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

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

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

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

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

                                                                                \[\leadsto \color{blue}{\frac{{a}^{\left(t - 1\right)}}{y} \cdot x} \]
                                                                              6. lower-/.f6482.6

                                                                                \[\leadsto \color{blue}{\frac{{a}^{\left(t - 1\right)}}{y}} \cdot x \]
                                                                            3. Applied rewrites82.6%

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

                                                                            if -1.9999999999999999e74 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < -195

                                                                            1. Initial program 96.9%

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

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

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

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

                                                                                \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                              4. exp-diffN/A

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

                                                                                \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                              6. exp-to-powN/A

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

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

                                                                                \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                              9. lower-exp.f64N/A

                                                                                \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                              10. lower-/.f6447.5

                                                                                \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                            5. Applied rewrites47.5%

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

                                                                              \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                                                                            7. Step-by-step derivation
                                                                              1. Applied rewrites67.4%

                                                                                \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]

                                                                              if -195 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < 9.99999999999999995e88

                                                                              1. Initial program 97.4%

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

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

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

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

                                                                                  \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                4. exp-diffN/A

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

                                                                                  \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                6. exp-to-powN/A

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

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

                                                                                  \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                9. lower-exp.f64N/A

                                                                                  \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                10. lower-/.f6464.5

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

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

                                                                                \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                                                                              7. Step-by-step derivation
                                                                                1. Applied rewrites65.2%

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

                                                                                    \[\leadsto \frac{\frac{x}{e^{b} \cdot y}}{a} \]
                                                                                3. Recombined 3 regimes into one program.
                                                                                4. Add Preprocessing

                                                                                Alternative 9: 79.4% accurate, 0.7× speedup?

                                                                                \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(t - 1\right) \cdot \log a\\ \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+36} \lor \neg \left(t\_1 \leq 560\right):\\ \;\;\;\;\frac{x \cdot e^{\log a \cdot t - b}}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot \frac{{z}^{y}}{a}}{y}\\ \end{array} \end{array} \]
                                                                                (FPCore (x y z t a b)
                                                                                 :precision binary64
                                                                                 (let* ((t_1 (* (- t 1.0) (log a))))
                                                                                   (if (or (<= t_1 -4e+36) (not (<= t_1 560.0)))
                                                                                     (/ (* x (exp (- (* (log a) t) b))) y)
                                                                                     (/ (* x (/ (pow z y) a)) y))))
                                                                                double code(double x, double y, double z, double t, double a, double b) {
                                                                                	double t_1 = (t - 1.0) * log(a);
                                                                                	double tmp;
                                                                                	if ((t_1 <= -4e+36) || !(t_1 <= 560.0)) {
                                                                                		tmp = (x * exp(((log(a) * t) - b))) / y;
                                                                                	} else {
                                                                                		tmp = (x * (pow(z, y) / a)) / y;
                                                                                	}
                                                                                	return tmp;
                                                                                }
                                                                                
                                                                                module fmin_fmax_functions
                                                                                    implicit none
                                                                                    private
                                                                                    public fmax
                                                                                    public fmin
                                                                                
                                                                                    interface fmax
                                                                                        module procedure fmax88
                                                                                        module procedure fmax44
                                                                                        module procedure fmax84
                                                                                        module procedure fmax48
                                                                                    end interface
                                                                                    interface fmin
                                                                                        module procedure fmin88
                                                                                        module procedure fmin44
                                                                                        module procedure fmin84
                                                                                        module procedure fmin48
                                                                                    end interface
                                                                                contains
                                                                                    real(8) function fmax88(x, y) result (res)
                                                                                        real(8), intent (in) :: x
                                                                                        real(8), intent (in) :: y
                                                                                        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                    end function
                                                                                    real(4) function fmax44(x, y) result (res)
                                                                                        real(4), intent (in) :: x
                                                                                        real(4), intent (in) :: y
                                                                                        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                    end function
                                                                                    real(8) function fmax84(x, y) result(res)
                                                                                        real(8), intent (in) :: x
                                                                                        real(4), intent (in) :: y
                                                                                        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                                    end function
                                                                                    real(8) function fmax48(x, y) result(res)
                                                                                        real(4), intent (in) :: x
                                                                                        real(8), intent (in) :: y
                                                                                        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                                    end function
                                                                                    real(8) function fmin88(x, y) result (res)
                                                                                        real(8), intent (in) :: x
                                                                                        real(8), intent (in) :: y
                                                                                        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                    end function
                                                                                    real(4) function fmin44(x, y) result (res)
                                                                                        real(4), intent (in) :: x
                                                                                        real(4), intent (in) :: y
                                                                                        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                    end function
                                                                                    real(8) function fmin84(x, y) result(res)
                                                                                        real(8), intent (in) :: x
                                                                                        real(4), intent (in) :: y
                                                                                        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                                    end function
                                                                                    real(8) function fmin48(x, y) result(res)
                                                                                        real(4), intent (in) :: x
                                                                                        real(8), intent (in) :: y
                                                                                        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                                    end function
                                                                                end module
                                                                                
                                                                                real(8) function code(x, y, z, t, a, b)
                                                                                use fmin_fmax_functions
                                                                                    real(8), intent (in) :: x
                                                                                    real(8), intent (in) :: y
                                                                                    real(8), intent (in) :: z
                                                                                    real(8), intent (in) :: t
                                                                                    real(8), intent (in) :: a
                                                                                    real(8), intent (in) :: b
                                                                                    real(8) :: t_1
                                                                                    real(8) :: tmp
                                                                                    t_1 = (t - 1.0d0) * log(a)
                                                                                    if ((t_1 <= (-4d+36)) .or. (.not. (t_1 <= 560.0d0))) then
                                                                                        tmp = (x * exp(((log(a) * t) - b))) / y
                                                                                    else
                                                                                        tmp = (x * ((z ** y) / a)) / y
                                                                                    end if
                                                                                    code = tmp
                                                                                end function
                                                                                
                                                                                public static double code(double x, double y, double z, double t, double a, double b) {
                                                                                	double t_1 = (t - 1.0) * Math.log(a);
                                                                                	double tmp;
                                                                                	if ((t_1 <= -4e+36) || !(t_1 <= 560.0)) {
                                                                                		tmp = (x * Math.exp(((Math.log(a) * t) - b))) / y;
                                                                                	} else {
                                                                                		tmp = (x * (Math.pow(z, y) / a)) / y;
                                                                                	}
                                                                                	return tmp;
                                                                                }
                                                                                
                                                                                def code(x, y, z, t, a, b):
                                                                                	t_1 = (t - 1.0) * math.log(a)
                                                                                	tmp = 0
                                                                                	if (t_1 <= -4e+36) or not (t_1 <= 560.0):
                                                                                		tmp = (x * math.exp(((math.log(a) * t) - b))) / y
                                                                                	else:
                                                                                		tmp = (x * (math.pow(z, y) / a)) / y
                                                                                	return tmp
                                                                                
                                                                                function code(x, y, z, t, a, b)
                                                                                	t_1 = Float64(Float64(t - 1.0) * log(a))
                                                                                	tmp = 0.0
                                                                                	if ((t_1 <= -4e+36) || !(t_1 <= 560.0))
                                                                                		tmp = Float64(Float64(x * exp(Float64(Float64(log(a) * t) - b))) / y);
                                                                                	else
                                                                                		tmp = Float64(Float64(x * Float64((z ^ y) / a)) / y);
                                                                                	end
                                                                                	return tmp
                                                                                end
                                                                                
                                                                                function tmp_2 = code(x, y, z, t, a, b)
                                                                                	t_1 = (t - 1.0) * log(a);
                                                                                	tmp = 0.0;
                                                                                	if ((t_1 <= -4e+36) || ~((t_1 <= 560.0)))
                                                                                		tmp = (x * exp(((log(a) * t) - b))) / y;
                                                                                	else
                                                                                		tmp = (x * ((z ^ y) / a)) / y;
                                                                                	end
                                                                                	tmp_2 = tmp;
                                                                                end
                                                                                
                                                                                code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -4e+36], N[Not[LessEqual[t$95$1, 560.0]], $MachinePrecision]], N[(N[(x * N[Exp[N[(N[(N[Log[a], $MachinePrecision] * t), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(N[(x * N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]]
                                                                                
                                                                                \begin{array}{l}
                                                                                
                                                                                \\
                                                                                \begin{array}{l}
                                                                                t_1 := \left(t - 1\right) \cdot \log a\\
                                                                                \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+36} \lor \neg \left(t\_1 \leq 560\right):\\
                                                                                \;\;\;\;\frac{x \cdot e^{\log a \cdot t - b}}{y}\\
                                                                                
                                                                                \mathbf{else}:\\
                                                                                \;\;\;\;\frac{x \cdot \frac{{z}^{y}}{a}}{y}\\
                                                                                
                                                                                
                                                                                \end{array}
                                                                                \end{array}
                                                                                
                                                                                Derivation
                                                                                1. Split input into 2 regimes
                                                                                2. if (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < -4.00000000000000017e36 or 560 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))

                                                                                  1. Initial program 100.0%

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

                                                                                    \[\leadsto \frac{x \cdot e^{\color{blue}{t \cdot \log a} - b}}{y} \]
                                                                                  4. Step-by-step derivation
                                                                                    1. *-commutativeN/A

                                                                                      \[\leadsto \frac{x \cdot e^{\color{blue}{\log a \cdot t} - b}}{y} \]
                                                                                    2. lower-*.f64N/A

                                                                                      \[\leadsto \frac{x \cdot e^{\color{blue}{\log a \cdot t} - b}}{y} \]
                                                                                    3. lower-log.f6490.1

                                                                                      \[\leadsto \frac{x \cdot e^{\color{blue}{\log a} \cdot t - b}}{y} \]
                                                                                  5. Applied rewrites90.1%

                                                                                    \[\leadsto \frac{x \cdot e^{\color{blue}{\log a \cdot t} - b}}{y} \]

                                                                                  if -4.00000000000000017e36 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < 560

                                                                                  1. Initial program 96.4%

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

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

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

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

                                                                                      \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                                                                    4. exp-to-powN/A

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

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

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

                                                                                      \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                                                                    8. exp-to-powN/A

                                                                                      \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot \color{blue}{{z}^{y}}\right)}{y} \]
                                                                                    9. lower-pow.f6481.2

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

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

                                                                                    \[\leadsto \frac{x \cdot \frac{{z}^{y}}{\color{blue}{a}}}{y} \]
                                                                                  7. Step-by-step derivation
                                                                                    1. Applied rewrites81.8%

                                                                                      \[\leadsto \frac{x \cdot \frac{{z}^{y}}{\color{blue}{a}}}{y} \]
                                                                                  8. Recombined 2 regimes into one program.
                                                                                  9. Final simplification86.3%

                                                                                    \[\leadsto \begin{array}{l} \mathbf{if}\;\left(t - 1\right) \cdot \log a \leq -4 \cdot 10^{+36} \lor \neg \left(\left(t - 1\right) \cdot \log a \leq 560\right):\\ \;\;\;\;\frac{x \cdot e^{\log a \cdot t - b}}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot \frac{{z}^{y}}{a}}{y}\\ \end{array} \]
                                                                                  10. Add Preprocessing

                                                                                  Alternative 10: 74.1% accurate, 1.0× speedup?

                                                                                  \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(t - 1\right) \cdot \log a\\ \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+74} \lor \neg \left(t\_1 \leq 200000000000\right):\\ \;\;\;\;\frac{{a}^{\left(t - 1\right)}}{y} \cdot x\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{\left(e^{b} \cdot y\right) \cdot a}\\ \end{array} \end{array} \]
                                                                                  (FPCore (x y z t a b)
                                                                                   :precision binary64
                                                                                   (let* ((t_1 (* (- t 1.0) (log a))))
                                                                                     (if (or (<= t_1 -2e+74) (not (<= t_1 200000000000.0)))
                                                                                       (* (/ (pow a (- t 1.0)) y) x)
                                                                                       (/ x (* (* (exp b) y) a)))))
                                                                                  double code(double x, double y, double z, double t, double a, double b) {
                                                                                  	double t_1 = (t - 1.0) * log(a);
                                                                                  	double tmp;
                                                                                  	if ((t_1 <= -2e+74) || !(t_1 <= 200000000000.0)) {
                                                                                  		tmp = (pow(a, (t - 1.0)) / y) * x;
                                                                                  	} else {
                                                                                  		tmp = x / ((exp(b) * y) * a);
                                                                                  	}
                                                                                  	return tmp;
                                                                                  }
                                                                                  
                                                                                  module fmin_fmax_functions
                                                                                      implicit none
                                                                                      private
                                                                                      public fmax
                                                                                      public fmin
                                                                                  
                                                                                      interface fmax
                                                                                          module procedure fmax88
                                                                                          module procedure fmax44
                                                                                          module procedure fmax84
                                                                                          module procedure fmax48
                                                                                      end interface
                                                                                      interface fmin
                                                                                          module procedure fmin88
                                                                                          module procedure fmin44
                                                                                          module procedure fmin84
                                                                                          module procedure fmin48
                                                                                      end interface
                                                                                  contains
                                                                                      real(8) function fmax88(x, y) result (res)
                                                                                          real(8), intent (in) :: x
                                                                                          real(8), intent (in) :: y
                                                                                          res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                      end function
                                                                                      real(4) function fmax44(x, y) result (res)
                                                                                          real(4), intent (in) :: x
                                                                                          real(4), intent (in) :: y
                                                                                          res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                      end function
                                                                                      real(8) function fmax84(x, y) result(res)
                                                                                          real(8), intent (in) :: x
                                                                                          real(4), intent (in) :: y
                                                                                          res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                                      end function
                                                                                      real(8) function fmax48(x, y) result(res)
                                                                                          real(4), intent (in) :: x
                                                                                          real(8), intent (in) :: y
                                                                                          res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                                      end function
                                                                                      real(8) function fmin88(x, y) result (res)
                                                                                          real(8), intent (in) :: x
                                                                                          real(8), intent (in) :: y
                                                                                          res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                      end function
                                                                                      real(4) function fmin44(x, y) result (res)
                                                                                          real(4), intent (in) :: x
                                                                                          real(4), intent (in) :: y
                                                                                          res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                      end function
                                                                                      real(8) function fmin84(x, y) result(res)
                                                                                          real(8), intent (in) :: x
                                                                                          real(4), intent (in) :: y
                                                                                          res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                                      end function
                                                                                      real(8) function fmin48(x, y) result(res)
                                                                                          real(4), intent (in) :: x
                                                                                          real(8), intent (in) :: y
                                                                                          res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                                      end function
                                                                                  end module
                                                                                  
                                                                                  real(8) function code(x, y, z, t, a, b)
                                                                                  use fmin_fmax_functions
                                                                                      real(8), intent (in) :: x
                                                                                      real(8), intent (in) :: y
                                                                                      real(8), intent (in) :: z
                                                                                      real(8), intent (in) :: t
                                                                                      real(8), intent (in) :: a
                                                                                      real(8), intent (in) :: b
                                                                                      real(8) :: t_1
                                                                                      real(8) :: tmp
                                                                                      t_1 = (t - 1.0d0) * log(a)
                                                                                      if ((t_1 <= (-2d+74)) .or. (.not. (t_1 <= 200000000000.0d0))) then
                                                                                          tmp = ((a ** (t - 1.0d0)) / y) * x
                                                                                      else
                                                                                          tmp = x / ((exp(b) * y) * 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 = (t - 1.0) * Math.log(a);
                                                                                  	double tmp;
                                                                                  	if ((t_1 <= -2e+74) || !(t_1 <= 200000000000.0)) {
                                                                                  		tmp = (Math.pow(a, (t - 1.0)) / y) * x;
                                                                                  	} else {
                                                                                  		tmp = x / ((Math.exp(b) * y) * a);
                                                                                  	}
                                                                                  	return tmp;
                                                                                  }
                                                                                  
                                                                                  def code(x, y, z, t, a, b):
                                                                                  	t_1 = (t - 1.0) * math.log(a)
                                                                                  	tmp = 0
                                                                                  	if (t_1 <= -2e+74) or not (t_1 <= 200000000000.0):
                                                                                  		tmp = (math.pow(a, (t - 1.0)) / y) * x
                                                                                  	else:
                                                                                  		tmp = x / ((math.exp(b) * y) * a)
                                                                                  	return tmp
                                                                                  
                                                                                  function code(x, y, z, t, a, b)
                                                                                  	t_1 = Float64(Float64(t - 1.0) * log(a))
                                                                                  	tmp = 0.0
                                                                                  	if ((t_1 <= -2e+74) || !(t_1 <= 200000000000.0))
                                                                                  		tmp = Float64(Float64((a ^ Float64(t - 1.0)) / y) * x);
                                                                                  	else
                                                                                  		tmp = Float64(x / Float64(Float64(exp(b) * y) * a));
                                                                                  	end
                                                                                  	return tmp
                                                                                  end
                                                                                  
                                                                                  function tmp_2 = code(x, y, z, t, a, b)
                                                                                  	t_1 = (t - 1.0) * log(a);
                                                                                  	tmp = 0.0;
                                                                                  	if ((t_1 <= -2e+74) || ~((t_1 <= 200000000000.0)))
                                                                                  		tmp = ((a ^ (t - 1.0)) / y) * x;
                                                                                  	else
                                                                                  		tmp = x / ((exp(b) * y) * a);
                                                                                  	end
                                                                                  	tmp_2 = tmp;
                                                                                  end
                                                                                  
                                                                                  code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -2e+74], N[Not[LessEqual[t$95$1, 200000000000.0]], $MachinePrecision]], N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision], N[(x / N[(N[(N[Exp[b], $MachinePrecision] * y), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision]]]
                                                                                  
                                                                                  \begin{array}{l}
                                                                                  
                                                                                  \\
                                                                                  \begin{array}{l}
                                                                                  t_1 := \left(t - 1\right) \cdot \log a\\
                                                                                  \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+74} \lor \neg \left(t\_1 \leq 200000000000\right):\\
                                                                                  \;\;\;\;\frac{{a}^{\left(t - 1\right)}}{y} \cdot x\\
                                                                                  
                                                                                  \mathbf{else}:\\
                                                                                  \;\;\;\;\frac{x}{\left(e^{b} \cdot y\right) \cdot a}\\
                                                                                  
                                                                                  
                                                                                  \end{array}
                                                                                  \end{array}
                                                                                  
                                                                                  Derivation
                                                                                  1. Split input into 2 regimes
                                                                                  2. if (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < -1.9999999999999999e74 or 2e11 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a))

                                                                                    1. Initial program 100.0%

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

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

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

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

                                                                                        \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                                                                      4. exp-to-powN/A

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

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

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

                                                                                        \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                                                                      8. exp-to-powN/A

                                                                                        \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot \color{blue}{{z}^{y}}\right)}{y} \]
                                                                                      9. lower-pow.f6467.1

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

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

                                                                                      \[\leadsto \frac{x \cdot e^{\log a \cdot \left(t - 1\right)}}{y} \]
                                                                                    7. Step-by-step derivation
                                                                                      1. Applied rewrites81.2%

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

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

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

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

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

                                                                                          \[\leadsto \color{blue}{\frac{{a}^{\left(t - 1\right)}}{y} \cdot x} \]
                                                                                        6. lower-/.f6481.2

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

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

                                                                                      if -1.9999999999999999e74 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < 2e11

                                                                                      1. Initial program 97.0%

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

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

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

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

                                                                                          \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                        4. exp-diffN/A

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

                                                                                          \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                        6. exp-to-powN/A

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

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

                                                                                          \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                        9. lower-exp.f64N/A

                                                                                          \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                        10. lower-/.f6459.0

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

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

                                                                                        \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                                                                                      7. Step-by-step derivation
                                                                                        1. Applied rewrites66.2%

                                                                                          \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                      8. Recombined 2 regimes into one program.
                                                                                      9. Final simplification72.9%

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

                                                                                      Alternative 11: 88.5% accurate, 1.4× speedup?

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

                                                                                        1. Initial program 100.0%

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

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

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

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

                                                                                            \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                                                                          4. exp-to-powN/A

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

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

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

                                                                                            \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                                                                          8. exp-to-powN/A

                                                                                            \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot \color{blue}{{z}^{y}}\right)}{y} \]
                                                                                          9. lower-pow.f6477.3

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

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

                                                                                          \[\leadsto \frac{x \cdot \frac{{z}^{y}}{\color{blue}{a}}}{y} \]
                                                                                        7. Step-by-step derivation
                                                                                          1. Applied rewrites94.4%

                                                                                            \[\leadsto \frac{x \cdot \frac{{z}^{y}}{\color{blue}{a}}}{y} \]
                                                                                          2. Step-by-step derivation
                                                                                            1. lift-/.f64N/A

                                                                                              \[\leadsto \color{blue}{\frac{x \cdot \frac{{z}^{y}}{a}}{y}} \]
                                                                                            2. lift-*.f64N/A

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

                                                                                              \[\leadsto \color{blue}{x \cdot \frac{\frac{{z}^{y}}{a}}{y}} \]
                                                                                            4. *-commutativeN/A

                                                                                              \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y} \cdot x} \]
                                                                                            5. lower-*.f64N/A

                                                                                              \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y} \cdot x} \]
                                                                                            6. lower-/.f6494.4

                                                                                              \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y}} \cdot x \]
                                                                                          3. Applied rewrites94.4%

                                                                                            \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y} \cdot x} \]

                                                                                          if -2.5500000000000001e107 < y < 1.2e136

                                                                                          1. Initial program 97.5%

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

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

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

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

                                                                                              \[\leadsto \frac{x \cdot e^{\color{blue}{\left(t - 1\right)} \cdot \log a - b}}{y} \]
                                                                                            4. lower-log.f6491.7

                                                                                              \[\leadsto \frac{x \cdot e^{\left(t - 1\right) \cdot \color{blue}{\log a} - b}}{y} \]
                                                                                          5. Applied rewrites91.7%

                                                                                            \[\leadsto \frac{x \cdot e^{\color{blue}{\left(t - 1\right) \cdot \log a} - b}}{y} \]
                                                                                        8. Recombined 2 regimes into one program.
                                                                                        9. Final simplification92.6%

                                                                                          \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.55 \cdot 10^{+107} \lor \neg \left(y \leq 1.2 \cdot 10^{+136}\right):\\ \;\;\;\;\frac{\frac{{z}^{y}}{a}}{y} \cdot x\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot e^{\left(t - 1\right) \cdot \log a - b}}{y}\\ \end{array} \]
                                                                                        10. Add Preprocessing

                                                                                        Alternative 12: 73.6% accurate, 2.4× speedup?

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

                                                                                          1. Initial program 100.0%

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

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

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

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

                                                                                              \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                                                                            4. exp-to-powN/A

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

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

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

                                                                                              \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                                                                            8. exp-to-powN/A

                                                                                              \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot \color{blue}{{z}^{y}}\right)}{y} \]
                                                                                            9. lower-pow.f6473.7

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

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

                                                                                            \[\leadsto \frac{x \cdot \frac{{z}^{y}}{\color{blue}{a}}}{y} \]
                                                                                          7. Step-by-step derivation
                                                                                            1. Applied rewrites88.4%

                                                                                              \[\leadsto \frac{x \cdot \frac{{z}^{y}}{\color{blue}{a}}}{y} \]
                                                                                            2. Step-by-step derivation
                                                                                              1. lift-/.f64N/A

                                                                                                \[\leadsto \color{blue}{\frac{x \cdot \frac{{z}^{y}}{a}}{y}} \]
                                                                                              2. lift-*.f64N/A

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

                                                                                                \[\leadsto \color{blue}{x \cdot \frac{\frac{{z}^{y}}{a}}{y}} \]
                                                                                              4. *-commutativeN/A

                                                                                                \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y} \cdot x} \]
                                                                                              5. lower-*.f64N/A

                                                                                                \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y} \cdot x} \]
                                                                                              6. lower-/.f6488.4

                                                                                                \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y}} \cdot x \]
                                                                                            3. Applied rewrites88.4%

                                                                                              \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y} \cdot x} \]

                                                                                            if -29000 < y < 7.00000000000000006e134

                                                                                            1. Initial program 97.1%

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

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

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

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

                                                                                                \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                                                                              4. exp-to-powN/A

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

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

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

                                                                                                \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                                                                              8. exp-to-powN/A

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

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

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

                                                                                              \[\leadsto \frac{x \cdot e^{\log a \cdot \left(t - 1\right)}}{y} \]
                                                                                            7. Step-by-step derivation
                                                                                              1. Applied rewrites74.7%

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

                                                                                                  \[\leadsto \frac{x \cdot \frac{{a}^{t}}{a}}{y} \]
                                                                                              3. Recombined 2 regimes into one program.
                                                                                              4. Final simplification80.6%

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

                                                                                              Alternative 13: 73.6% accurate, 2.4× speedup?

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

                                                                                                1. Initial program 100.0%

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

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

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

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

                                                                                                    \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                                                                                  4. exp-to-powN/A

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

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

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

                                                                                                    \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                                                                                  8. exp-to-powN/A

                                                                                                    \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot \color{blue}{{z}^{y}}\right)}{y} \]
                                                                                                  9. lower-pow.f6473.7

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

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

                                                                                                  \[\leadsto \frac{x \cdot \frac{{z}^{y}}{\color{blue}{a}}}{y} \]
                                                                                                7. Step-by-step derivation
                                                                                                  1. Applied rewrites88.4%

                                                                                                    \[\leadsto \frac{x \cdot \frac{{z}^{y}}{\color{blue}{a}}}{y} \]
                                                                                                  2. Step-by-step derivation
                                                                                                    1. lift-/.f64N/A

                                                                                                      \[\leadsto \color{blue}{\frac{x \cdot \frac{{z}^{y}}{a}}{y}} \]
                                                                                                    2. lift-*.f64N/A

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

                                                                                                      \[\leadsto \color{blue}{x \cdot \frac{\frac{{z}^{y}}{a}}{y}} \]
                                                                                                    4. *-commutativeN/A

                                                                                                      \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y} \cdot x} \]
                                                                                                    5. lower-*.f64N/A

                                                                                                      \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y} \cdot x} \]
                                                                                                    6. lower-/.f6488.4

                                                                                                      \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y}} \cdot x \]
                                                                                                  3. Applied rewrites88.4%

                                                                                                    \[\leadsto \color{blue}{\frac{\frac{{z}^{y}}{a}}{y} \cdot x} \]

                                                                                                  if -29000 < y < 7.00000000000000006e134

                                                                                                  1. Initial program 97.1%

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

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

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

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

                                                                                                      \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                                                                                    4. exp-to-powN/A

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

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

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

                                                                                                      \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                                                                                    8. exp-to-powN/A

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

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

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

                                                                                                    \[\leadsto \frac{x \cdot e^{\log a \cdot \left(t - 1\right)}}{y} \]
                                                                                                  7. Step-by-step derivation
                                                                                                    1. Applied rewrites74.7%

                                                                                                      \[\leadsto \frac{x \cdot {a}^{\color{blue}{\left(t - 1\right)}}}{y} \]
                                                                                                  8. Recombined 2 regimes into one program.
                                                                                                  9. Final simplification80.6%

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

                                                                                                  Alternative 14: 72.1% accurate, 2.5× speedup?

                                                                                                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -7.2 \cdot 10^{+62} \lor \neg \left(b \leq 5.1 \cdot 10^{+159}\right):\\ \;\;\;\;\frac{e^{-b}}{y} \cdot x\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot {a}^{\left(t - 1\right)}}{y}\\ \end{array} \end{array} \]
                                                                                                  (FPCore (x y z t a b)
                                                                                                   :precision binary64
                                                                                                   (if (or (<= b -7.2e+62) (not (<= b 5.1e+159)))
                                                                                                     (* (/ (exp (- b)) y) x)
                                                                                                     (/ (* x (pow a (- t 1.0))) y)))
                                                                                                  double code(double x, double y, double z, double t, double a, double b) {
                                                                                                  	double tmp;
                                                                                                  	if ((b <= -7.2e+62) || !(b <= 5.1e+159)) {
                                                                                                  		tmp = (exp(-b) / y) * x;
                                                                                                  	} else {
                                                                                                  		tmp = (x * pow(a, (t - 1.0))) / 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 ((b <= (-7.2d+62)) .or. (.not. (b <= 5.1d+159))) then
                                                                                                          tmp = (exp(-b) / y) * x
                                                                                                      else
                                                                                                          tmp = (x * (a ** (t - 1.0d0))) / 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 ((b <= -7.2e+62) || !(b <= 5.1e+159)) {
                                                                                                  		tmp = (Math.exp(-b) / y) * x;
                                                                                                  	} else {
                                                                                                  		tmp = (x * Math.pow(a, (t - 1.0))) / y;
                                                                                                  	}
                                                                                                  	return tmp;
                                                                                                  }
                                                                                                  
                                                                                                  def code(x, y, z, t, a, b):
                                                                                                  	tmp = 0
                                                                                                  	if (b <= -7.2e+62) or not (b <= 5.1e+159):
                                                                                                  		tmp = (math.exp(-b) / y) * x
                                                                                                  	else:
                                                                                                  		tmp = (x * math.pow(a, (t - 1.0))) / y
                                                                                                  	return tmp
                                                                                                  
                                                                                                  function code(x, y, z, t, a, b)
                                                                                                  	tmp = 0.0
                                                                                                  	if ((b <= -7.2e+62) || !(b <= 5.1e+159))
                                                                                                  		tmp = Float64(Float64(exp(Float64(-b)) / y) * x);
                                                                                                  	else
                                                                                                  		tmp = Float64(Float64(x * (a ^ Float64(t - 1.0))) / y);
                                                                                                  	end
                                                                                                  	return tmp
                                                                                                  end
                                                                                                  
                                                                                                  function tmp_2 = code(x, y, z, t, a, b)
                                                                                                  	tmp = 0.0;
                                                                                                  	if ((b <= -7.2e+62) || ~((b <= 5.1e+159)))
                                                                                                  		tmp = (exp(-b) / y) * x;
                                                                                                  	else
                                                                                                  		tmp = (x * (a ^ (t - 1.0))) / y;
                                                                                                  	end
                                                                                                  	tmp_2 = tmp;
                                                                                                  end
                                                                                                  
                                                                                                  code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -7.2e+62], N[Not[LessEqual[b, 5.1e+159]], $MachinePrecision]], N[(N[(N[Exp[(-b)], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision], N[(N[(x * N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]
                                                                                                  
                                                                                                  \begin{array}{l}
                                                                                                  
                                                                                                  \\
                                                                                                  \begin{array}{l}
                                                                                                  \mathbf{if}\;b \leq -7.2 \cdot 10^{+62} \lor \neg \left(b \leq 5.1 \cdot 10^{+159}\right):\\
                                                                                                  \;\;\;\;\frac{e^{-b}}{y} \cdot x\\
                                                                                                  
                                                                                                  \mathbf{else}:\\
                                                                                                  \;\;\;\;\frac{x \cdot {a}^{\left(t - 1\right)}}{y}\\
                                                                                                  
                                                                                                  
                                                                                                  \end{array}
                                                                                                  \end{array}
                                                                                                  
                                                                                                  Derivation
                                                                                                  1. Split input into 2 regimes
                                                                                                  2. if b < -7.2e62 or 5.09999999999999967e159 < b

                                                                                                    1. Initial program 100.0%

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

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

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

                                                                                                        \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z + \color{blue}{\log a \cdot -1}\right) - b}}{y} \]
                                                                                                      3. fp-cancel-sign-sub-invN/A

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

                                                                                                        \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \color{blue}{\left(\mathsf{neg}\left(\log a \cdot -1\right)\right)}\right) - b}}{y} \]
                                                                                                      5. distribute-rgt-neg-outN/A

                                                                                                        \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \color{blue}{\log a \cdot \left(\mathsf{neg}\left(-1\right)\right)}\right) - b}}{y} \]
                                                                                                      6. metadata-evalN/A

                                                                                                        \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \log a \cdot \color{blue}{1}\right) - b}}{y} \]
                                                                                                      7. fp-cancel-sub-sign-invN/A

                                                                                                        \[\leadsto \frac{x \cdot e^{\color{blue}{\left(y \cdot \log z + \left(\mathsf{neg}\left(\log a\right)\right) \cdot 1\right)} - b}}{y} \]
                                                                                                      8. *-commutativeN/A

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

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

                                                                                                        \[\leadsto \frac{x \cdot e^{\left(\log z \cdot y + \color{blue}{\log a \cdot \left(\mathsf{neg}\left(1\right)\right)}\right) - b}}{y} \]
                                                                                                      11. metadata-evalN/A

                                                                                                        \[\leadsto \frac{x \cdot e^{\left(\log z \cdot y + \log a \cdot \color{blue}{-1}\right) - b}}{y} \]
                                                                                                      12. *-commutativeN/A

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

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

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

                                                                                                        \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, \color{blue}{\mathsf{neg}\left(\log a\right)}\right) - b}}{y} \]
                                                                                                      16. lower-neg.f64N/A

                                                                                                        \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, \color{blue}{-\log a}\right) - b}}{y} \]
                                                                                                      17. lower-log.f6489.6

                                                                                                        \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, -\color{blue}{\log a}\right) - b}}{y} \]
                                                                                                    5. Applied rewrites89.6%

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

                                                                                                      \[\leadsto \frac{x \cdot e^{\color{blue}{-1 \cdot b}}}{y} \]
                                                                                                    7. Step-by-step derivation
                                                                                                      1. mul-1-negN/A

                                                                                                        \[\leadsto \frac{x \cdot e^{\color{blue}{\mathsf{neg}\left(b\right)}}}{y} \]
                                                                                                      2. lower-neg.f6481.5

                                                                                                        \[\leadsto \frac{x \cdot e^{\color{blue}{-b}}}{y} \]
                                                                                                    8. Applied rewrites81.5%

                                                                                                      \[\leadsto \frac{x \cdot e^{\color{blue}{-b}}}{y} \]
                                                                                                    9. Step-by-step derivation
                                                                                                      1. lift-/.f64N/A

                                                                                                        \[\leadsto \color{blue}{\frac{x \cdot e^{-b}}{y}} \]
                                                                                                      2. lift-*.f64N/A

                                                                                                        \[\leadsto \frac{\color{blue}{x \cdot e^{-b}}}{y} \]
                                                                                                      3. associate-/l*N/A

                                                                                                        \[\leadsto \color{blue}{x \cdot \frac{e^{-b}}{y}} \]
                                                                                                      4. *-commutativeN/A

                                                                                                        \[\leadsto \color{blue}{\frac{e^{-b}}{y} \cdot x} \]
                                                                                                      5. lower-*.f64N/A

                                                                                                        \[\leadsto \color{blue}{\frac{e^{-b}}{y} \cdot x} \]
                                                                                                      6. lower-/.f6481.5

                                                                                                        \[\leadsto \color{blue}{\frac{e^{-b}}{y}} \cdot x \]
                                                                                                    10. Applied rewrites81.5%

                                                                                                      \[\leadsto \color{blue}{\frac{e^{-b}}{y} \cdot x} \]

                                                                                                    if -7.2e62 < b < 5.09999999999999967e159

                                                                                                    1. Initial program 97.5%

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

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

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

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

                                                                                                        \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                                                                                      4. exp-to-powN/A

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

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

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

                                                                                                        \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                                                                                      8. exp-to-powN/A

                                                                                                        \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot \color{blue}{{z}^{y}}\right)}{y} \]
                                                                                                      9. lower-pow.f6480.9

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

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

                                                                                                      \[\leadsto \frac{x \cdot e^{\log a \cdot \left(t - 1\right)}}{y} \]
                                                                                                    7. Step-by-step derivation
                                                                                                      1. Applied rewrites67.6%

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

                                                                                                      \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -7.2 \cdot 10^{+62} \lor \neg \left(b \leq 5.1 \cdot 10^{+159}\right):\\ \;\;\;\;\frac{e^{-b}}{y} \cdot x\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot {a}^{\left(t - 1\right)}}{y}\\ \end{array} \]
                                                                                                    10. Add Preprocessing

                                                                                                    Alternative 15: 70.9% accurate, 2.5× speedup?

                                                                                                    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -3.5 \cdot 10^{+142} \lor \neg \left(b \leq 5.1 \cdot 10^{+159}\right):\\ \;\;\;\;\frac{e^{-b}}{y} \cdot x\\ \mathbf{else}:\\ \;\;\;\;\frac{{a}^{\left(t - 1\right)}}{y} \cdot x\\ \end{array} \end{array} \]
                                                                                                    (FPCore (x y z t a b)
                                                                                                     :precision binary64
                                                                                                     (if (or (<= b -3.5e+142) (not (<= b 5.1e+159)))
                                                                                                       (* (/ (exp (- b)) y) x)
                                                                                                       (* (/ (pow a (- t 1.0)) y) x)))
                                                                                                    double code(double x, double y, double z, double t, double a, double b) {
                                                                                                    	double tmp;
                                                                                                    	if ((b <= -3.5e+142) || !(b <= 5.1e+159)) {
                                                                                                    		tmp = (exp(-b) / y) * x;
                                                                                                    	} else {
                                                                                                    		tmp = (pow(a, (t - 1.0)) / y) * x;
                                                                                                    	}
                                                                                                    	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 ((b <= (-3.5d+142)) .or. (.not. (b <= 5.1d+159))) then
                                                                                                            tmp = (exp(-b) / y) * x
                                                                                                        else
                                                                                                            tmp = ((a ** (t - 1.0d0)) / y) * x
                                                                                                        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 ((b <= -3.5e+142) || !(b <= 5.1e+159)) {
                                                                                                    		tmp = (Math.exp(-b) / y) * x;
                                                                                                    	} else {
                                                                                                    		tmp = (Math.pow(a, (t - 1.0)) / y) * x;
                                                                                                    	}
                                                                                                    	return tmp;
                                                                                                    }
                                                                                                    
                                                                                                    def code(x, y, z, t, a, b):
                                                                                                    	tmp = 0
                                                                                                    	if (b <= -3.5e+142) or not (b <= 5.1e+159):
                                                                                                    		tmp = (math.exp(-b) / y) * x
                                                                                                    	else:
                                                                                                    		tmp = (math.pow(a, (t - 1.0)) / y) * x
                                                                                                    	return tmp
                                                                                                    
                                                                                                    function code(x, y, z, t, a, b)
                                                                                                    	tmp = 0.0
                                                                                                    	if ((b <= -3.5e+142) || !(b <= 5.1e+159))
                                                                                                    		tmp = Float64(Float64(exp(Float64(-b)) / y) * x);
                                                                                                    	else
                                                                                                    		tmp = Float64(Float64((a ^ Float64(t - 1.0)) / y) * x);
                                                                                                    	end
                                                                                                    	return tmp
                                                                                                    end
                                                                                                    
                                                                                                    function tmp_2 = code(x, y, z, t, a, b)
                                                                                                    	tmp = 0.0;
                                                                                                    	if ((b <= -3.5e+142) || ~((b <= 5.1e+159)))
                                                                                                    		tmp = (exp(-b) / y) * x;
                                                                                                    	else
                                                                                                    		tmp = ((a ^ (t - 1.0)) / y) * x;
                                                                                                    	end
                                                                                                    	tmp_2 = tmp;
                                                                                                    end
                                                                                                    
                                                                                                    code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -3.5e+142], N[Not[LessEqual[b, 5.1e+159]], $MachinePrecision]], N[(N[(N[Exp[(-b)], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision], N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision]]
                                                                                                    
                                                                                                    \begin{array}{l}
                                                                                                    
                                                                                                    \\
                                                                                                    \begin{array}{l}
                                                                                                    \mathbf{if}\;b \leq -3.5 \cdot 10^{+142} \lor \neg \left(b \leq 5.1 \cdot 10^{+159}\right):\\
                                                                                                    \;\;\;\;\frac{e^{-b}}{y} \cdot x\\
                                                                                                    
                                                                                                    \mathbf{else}:\\
                                                                                                    \;\;\;\;\frac{{a}^{\left(t - 1\right)}}{y} \cdot x\\
                                                                                                    
                                                                                                    
                                                                                                    \end{array}
                                                                                                    \end{array}
                                                                                                    
                                                                                                    Derivation
                                                                                                    1. Split input into 2 regimes
                                                                                                    2. if b < -3.49999999999999997e142 or 5.09999999999999967e159 < b

                                                                                                      1. Initial program 100.0%

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

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

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

                                                                                                          \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z + \color{blue}{\log a \cdot -1}\right) - b}}{y} \]
                                                                                                        3. fp-cancel-sign-sub-invN/A

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

                                                                                                          \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \color{blue}{\left(\mathsf{neg}\left(\log a \cdot -1\right)\right)}\right) - b}}{y} \]
                                                                                                        5. distribute-rgt-neg-outN/A

                                                                                                          \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \color{blue}{\log a \cdot \left(\mathsf{neg}\left(-1\right)\right)}\right) - b}}{y} \]
                                                                                                        6. metadata-evalN/A

                                                                                                          \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \log a \cdot \color{blue}{1}\right) - b}}{y} \]
                                                                                                        7. fp-cancel-sub-sign-invN/A

                                                                                                          \[\leadsto \frac{x \cdot e^{\color{blue}{\left(y \cdot \log z + \left(\mathsf{neg}\left(\log a\right)\right) \cdot 1\right)} - b}}{y} \]
                                                                                                        8. *-commutativeN/A

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

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

                                                                                                          \[\leadsto \frac{x \cdot e^{\left(\log z \cdot y + \color{blue}{\log a \cdot \left(\mathsf{neg}\left(1\right)\right)}\right) - b}}{y} \]
                                                                                                        11. metadata-evalN/A

                                                                                                          \[\leadsto \frac{x \cdot e^{\left(\log z \cdot y + \log a \cdot \color{blue}{-1}\right) - b}}{y} \]
                                                                                                        12. *-commutativeN/A

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

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

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

                                                                                                          \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, \color{blue}{\mathsf{neg}\left(\log a\right)}\right) - b}}{y} \]
                                                                                                        16. lower-neg.f64N/A

                                                                                                          \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, \color{blue}{-\log a}\right) - b}}{y} \]
                                                                                                        17. lower-log.f6492.8

                                                                                                          \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, -\color{blue}{\log a}\right) - b}}{y} \]
                                                                                                      5. Applied rewrites92.8%

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

                                                                                                        \[\leadsto \frac{x \cdot e^{\color{blue}{-1 \cdot b}}}{y} \]
                                                                                                      7. Step-by-step derivation
                                                                                                        1. mul-1-negN/A

                                                                                                          \[\leadsto \frac{x \cdot e^{\color{blue}{\mathsf{neg}\left(b\right)}}}{y} \]
                                                                                                        2. lower-neg.f6485.5

                                                                                                          \[\leadsto \frac{x \cdot e^{\color{blue}{-b}}}{y} \]
                                                                                                      8. Applied rewrites85.5%

                                                                                                        \[\leadsto \frac{x \cdot e^{\color{blue}{-b}}}{y} \]
                                                                                                      9. Step-by-step derivation
                                                                                                        1. lift-/.f64N/A

                                                                                                          \[\leadsto \color{blue}{\frac{x \cdot e^{-b}}{y}} \]
                                                                                                        2. lift-*.f64N/A

                                                                                                          \[\leadsto \frac{\color{blue}{x \cdot e^{-b}}}{y} \]
                                                                                                        3. associate-/l*N/A

                                                                                                          \[\leadsto \color{blue}{x \cdot \frac{e^{-b}}{y}} \]
                                                                                                        4. *-commutativeN/A

                                                                                                          \[\leadsto \color{blue}{\frac{e^{-b}}{y} \cdot x} \]
                                                                                                        5. lower-*.f64N/A

                                                                                                          \[\leadsto \color{blue}{\frac{e^{-b}}{y} \cdot x} \]
                                                                                                        6. lower-/.f6485.5

                                                                                                          \[\leadsto \color{blue}{\frac{e^{-b}}{y}} \cdot x \]
                                                                                                      10. Applied rewrites85.5%

                                                                                                        \[\leadsto \color{blue}{\frac{e^{-b}}{y} \cdot x} \]

                                                                                                      if -3.49999999999999997e142 < b < 5.09999999999999967e159

                                                                                                      1. Initial program 97.7%

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

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

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

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

                                                                                                          \[\leadsto \frac{x \cdot \color{blue}{\left(e^{\log a \cdot \left(t - 1\right)} \cdot e^{y \cdot \log z}\right)}}{y} \]
                                                                                                        4. exp-to-powN/A

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

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

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

                                                                                                          \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot e^{\color{blue}{\log z \cdot y}}\right)}{y} \]
                                                                                                        8. exp-to-powN/A

                                                                                                          \[\leadsto \frac{x \cdot \left({a}^{\left(t - 1\right)} \cdot \color{blue}{{z}^{y}}\right)}{y} \]
                                                                                                        9. lower-pow.f6478.9

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

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

                                                                                                        \[\leadsto \frac{x \cdot e^{\log a \cdot \left(t - 1\right)}}{y} \]
                                                                                                      7. Step-by-step derivation
                                                                                                        1. Applied rewrites66.4%

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

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

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

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

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

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

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

                                                                                                          \[\leadsto \color{blue}{\frac{{a}^{\left(t - 1\right)}}{y} \cdot x} \]
                                                                                                      8. Recombined 2 regimes into one program.
                                                                                                      9. Final simplification70.5%

                                                                                                        \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -3.5 \cdot 10^{+142} \lor \neg \left(b \leq 5.1 \cdot 10^{+159}\right):\\ \;\;\;\;\frac{e^{-b}}{y} \cdot x\\ \mathbf{else}:\\ \;\;\;\;\frac{{a}^{\left(t - 1\right)}}{y} \cdot x\\ \end{array} \]
                                                                                                      10. Add Preprocessing

                                                                                                      Alternative 16: 60.5% accurate, 2.6× speedup?

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

                                                                                                        1. Initial program 100.0%

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

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

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

                                                                                                            \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z + \color{blue}{\log a \cdot -1}\right) - b}}{y} \]
                                                                                                          3. fp-cancel-sign-sub-invN/A

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

                                                                                                            \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \color{blue}{\left(\mathsf{neg}\left(\log a \cdot -1\right)\right)}\right) - b}}{y} \]
                                                                                                          5. distribute-rgt-neg-outN/A

                                                                                                            \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \color{blue}{\log a \cdot \left(\mathsf{neg}\left(-1\right)\right)}\right) - b}}{y} \]
                                                                                                          6. metadata-evalN/A

                                                                                                            \[\leadsto \frac{x \cdot e^{\left(y \cdot \log z - \log a \cdot \color{blue}{1}\right) - b}}{y} \]
                                                                                                          7. fp-cancel-sub-sign-invN/A

                                                                                                            \[\leadsto \frac{x \cdot e^{\color{blue}{\left(y \cdot \log z + \left(\mathsf{neg}\left(\log a\right)\right) \cdot 1\right)} - b}}{y} \]
                                                                                                          8. *-commutativeN/A

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

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

                                                                                                            \[\leadsto \frac{x \cdot e^{\left(\log z \cdot y + \color{blue}{\log a \cdot \left(\mathsf{neg}\left(1\right)\right)}\right) - b}}{y} \]
                                                                                                          11. metadata-evalN/A

                                                                                                            \[\leadsto \frac{x \cdot e^{\left(\log z \cdot y + \log a \cdot \color{blue}{-1}\right) - b}}{y} \]
                                                                                                          12. *-commutativeN/A

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

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

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

                                                                                                            \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, \color{blue}{\mathsf{neg}\left(\log a\right)}\right) - b}}{y} \]
                                                                                                          16. lower-neg.f64N/A

                                                                                                            \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, \color{blue}{-\log a}\right) - b}}{y} \]
                                                                                                          17. lower-log.f6485.0

                                                                                                            \[\leadsto \frac{x \cdot e^{\mathsf{fma}\left(\log z, y, -\color{blue}{\log a}\right) - b}}{y} \]
                                                                                                        5. Applied rewrites85.0%

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

                                                                                                          \[\leadsto \frac{x \cdot e^{\color{blue}{-1 \cdot b}}}{y} \]
                                                                                                        7. Step-by-step derivation
                                                                                                          1. mul-1-negN/A

                                                                                                            \[\leadsto \frac{x \cdot e^{\color{blue}{\mathsf{neg}\left(b\right)}}}{y} \]
                                                                                                          2. lower-neg.f6470.1

                                                                                                            \[\leadsto \frac{x \cdot e^{\color{blue}{-b}}}{y} \]
                                                                                                        8. Applied rewrites70.1%

                                                                                                          \[\leadsto \frac{x \cdot e^{\color{blue}{-b}}}{y} \]
                                                                                                        9. Step-by-step derivation
                                                                                                          1. lift-/.f64N/A

                                                                                                            \[\leadsto \color{blue}{\frac{x \cdot e^{-b}}{y}} \]
                                                                                                          2. lift-*.f64N/A

                                                                                                            \[\leadsto \frac{\color{blue}{x \cdot e^{-b}}}{y} \]
                                                                                                          3. associate-/l*N/A

                                                                                                            \[\leadsto \color{blue}{x \cdot \frac{e^{-b}}{y}} \]
                                                                                                          4. *-commutativeN/A

                                                                                                            \[\leadsto \color{blue}{\frac{e^{-b}}{y} \cdot x} \]
                                                                                                          5. lower-*.f64N/A

                                                                                                            \[\leadsto \color{blue}{\frac{e^{-b}}{y} \cdot x} \]
                                                                                                          6. lower-/.f6470.1

                                                                                                            \[\leadsto \color{blue}{\frac{e^{-b}}{y}} \cdot x \]
                                                                                                        10. Applied rewrites70.1%

                                                                                                          \[\leadsto \color{blue}{\frac{e^{-b}}{y} \cdot x} \]

                                                                                                        if -160 < b < 1.6e13

                                                                                                        1. Initial program 96.7%

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

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

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

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

                                                                                                            \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                          4. exp-diffN/A

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

                                                                                                            \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                          6. exp-to-powN/A

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

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

                                                                                                            \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                          9. lower-exp.f64N/A

                                                                                                            \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                          10. lower-/.f6461.9

                                                                                                            \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                                                        5. Applied rewrites61.9%

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

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

                                                                                                            \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                          2. Taylor expanded in b around 0

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

                                                                                                              \[\leadsto \frac{x}{\mathsf{fma}\left(\mathsf{fma}\left(\left(b \cdot y\right) \cdot a, 0.5, a \cdot y\right), b, a \cdot y\right)} \]
                                                                                                            2. Taylor expanded in b around -inf

                                                                                                              \[\leadsto \frac{x}{\mathsf{fma}\left(-1 \cdot \left(b \cdot \left(-1 \cdot \frac{a \cdot y}{b} + \frac{-1}{2} \cdot \left(a \cdot y\right)\right)\right), b, a \cdot y\right)} \]
                                                                                                            3. Step-by-step derivation
                                                                                                              1. Applied rewrites48.6%

                                                                                                                \[\leadsto \frac{x}{\mathsf{fma}\left(\left(-b\right) \cdot \mathsf{fma}\left(-0.5 \cdot y, a, \left(-a\right) \cdot \frac{y}{b}\right), b, a \cdot y\right)} \]
                                                                                                            4. Recombined 2 regimes into one program.
                                                                                                            5. Final simplification59.1%

                                                                                                              \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -160 \lor \neg \left(b \leq 16000000000000\right):\\ \;\;\;\;\frac{e^{-b}}{y} \cdot x\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{\mathsf{fma}\left(\left(-b\right) \cdot \mathsf{fma}\left(-0.5 \cdot y, a, \left(-a\right) \cdot \frac{y}{b}\right), b, a \cdot y\right)}\\ \end{array} \]
                                                                                                            6. Add Preprocessing

                                                                                                            Alternative 17: 46.8% accurate, 3.7× speedup?

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

                                                                                                              1. Initial program 100.0%

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

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

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

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

                                                                                                                  \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                4. exp-diffN/A

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

                                                                                                                  \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                6. exp-to-powN/A

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

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

                                                                                                                  \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                9. lower-exp.f64N/A

                                                                                                                  \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                10. lower-/.f6455.4

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

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

                                                                                                                \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                                                                                                              7. Step-by-step derivation
                                                                                                                1. Applied rewrites75.0%

                                                                                                                  \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                2. Taylor expanded in b around 0

                                                                                                                  \[\leadsto \frac{x}{a \cdot y} \]
                                                                                                                3. Step-by-step derivation
                                                                                                                  1. Applied rewrites35.4%

                                                                                                                    \[\leadsto \frac{x}{a \cdot y} \]
                                                                                                                  2. Taylor expanded in b around 0

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

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

                                                                                                                    if -0.14000000000000001 < b

                                                                                                                    1. Initial program 97.7%

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

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

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

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

                                                                                                                        \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                      4. exp-diffN/A

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

                                                                                                                        \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                      6. exp-to-powN/A

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

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

                                                                                                                        \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                      9. lower-exp.f64N/A

                                                                                                                        \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                      10. lower-/.f6458.3

                                                                                                                        \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                                                                    5. Applied rewrites58.3%

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

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

                                                                                                                        \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                      2. Taylor expanded in b around 0

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

                                                                                                                          \[\leadsto \frac{x}{\mathsf{fma}\left(\mathsf{fma}\left(\left(b \cdot y\right) \cdot a, 0.5, a \cdot y\right), b, a \cdot y\right)} \]
                                                                                                                        2. Taylor expanded in b around -inf

                                                                                                                          \[\leadsto \frac{x}{\mathsf{fma}\left(-1 \cdot \left(b \cdot \left(-1 \cdot \frac{a \cdot y}{b} + \frac{-1}{2} \cdot \left(a \cdot y\right)\right)\right), b, a \cdot y\right)} \]
                                                                                                                        3. Step-by-step derivation
                                                                                                                          1. Applied rewrites46.9%

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

                                                                                                                        Alternative 18: 47.5% accurate, 4.5× speedup?

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

                                                                                                                          1. Initial program 98.6%

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

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

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

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

                                                                                                                              \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                            4. exp-diffN/A

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

                                                                                                                              \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                            6. exp-to-powN/A

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

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

                                                                                                                              \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                            9. lower-exp.f64N/A

                                                                                                                              \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                            10. lower-/.f6455.6

                                                                                                                              \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                                                                          5. Applied rewrites55.6%

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

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

                                                                                                                              \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                            2. Taylor expanded in b around 0

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

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

                                                                                                                              if -1.2399999999999999e-120 < b

                                                                                                                              1. Initial program 98.2%

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

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

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

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

                                                                                                                                  \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                                4. exp-diffN/A

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

                                                                                                                                  \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                6. exp-to-powN/A

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

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

                                                                                                                                  \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                                9. lower-exp.f64N/A

                                                                                                                                  \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                10. lower-/.f6458.5

                                                                                                                                  \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                                                                              5. Applied rewrites58.5%

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

                                                                                                                                \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                                                                                                                              7. Step-by-step derivation
                                                                                                                                1. Applied rewrites48.2%

                                                                                                                                  \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                                2. Taylor expanded in b around 0

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

                                                                                                                                    \[\leadsto \frac{x}{\mathsf{fma}\left(\mathsf{fma}\left(\left(b \cdot y\right) \cdot a, 0.5, a \cdot y\right), b, a \cdot y\right)} \]
                                                                                                                                  2. Taylor expanded in b around -inf

                                                                                                                                    \[\leadsto \frac{x}{\mathsf{fma}\left(-1 \cdot \left(b \cdot \left(-1 \cdot \frac{a \cdot y}{b} + \frac{-1}{2} \cdot \left(a \cdot y\right)\right)\right), b, a \cdot y\right)} \]
                                                                                                                                  3. Step-by-step derivation
                                                                                                                                    1. Applied rewrites47.5%

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

                                                                                                                                  Alternative 19: 44.4% accurate, 6.5× speedup?

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

                                                                                                                                    1. Initial program 98.6%

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

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

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

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

                                                                                                                                        \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                                      4. exp-diffN/A

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

                                                                                                                                        \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                      6. exp-to-powN/A

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

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

                                                                                                                                        \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                                      9. lower-exp.f64N/A

                                                                                                                                        \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                      10. lower-/.f6454.4

                                                                                                                                        \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                                                                                    5. Applied rewrites54.4%

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

                                                                                                                                      \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                                                                                                                                    7. Step-by-step derivation
                                                                                                                                      1. Applied rewrites66.0%

                                                                                                                                        \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                                      2. Taylor expanded in b around 0

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

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

                                                                                                                                        if -1.5999999999999999e-125 < b

                                                                                                                                        1. Initial program 98.2%

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

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

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

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

                                                                                                                                            \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                                          4. exp-diffN/A

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

                                                                                                                                            \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                          6. exp-to-powN/A

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

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

                                                                                                                                            \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                                          9. lower-exp.f64N/A

                                                                                                                                            \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                          10. lower-/.f6459.2

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

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

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

                                                                                                                                            \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                                          2. Step-by-step derivation
                                                                                                                                            1. Applied rewrites46.0%

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

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

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

                                                                                                                                            Alternative 20: 41.9% accurate, 7.3× speedup?

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

                                                                                                                                              1. Initial program 100.0%

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

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

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

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

                                                                                                                                                  \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                                                4. exp-diffN/A

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

                                                                                                                                                  \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                                6. exp-to-powN/A

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

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

                                                                                                                                                  \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                                                9. lower-exp.f64N/A

                                                                                                                                                  \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                                10. lower-/.f6457.3

                                                                                                                                                  \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                                                                                              5. Applied rewrites57.3%

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

                                                                                                                                                \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                                                                                                                                              7. Step-by-step derivation
                                                                                                                                                1. Applied rewrites83.6%

                                                                                                                                                  \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                                                2. Taylor expanded in b around 0

                                                                                                                                                  \[\leadsto -1 \cdot \frac{b \cdot x}{a \cdot y} + \frac{x}{\color{blue}{a \cdot y}} \]
                                                                                                                                                3. Step-by-step derivation
                                                                                                                                                  1. Applied rewrites53.8%

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

                                                                                                                                                  if -1.05e142 < b

                                                                                                                                                  1. Initial program 98.0%

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

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

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

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

                                                                                                                                                      \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                                                    4. exp-diffN/A

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

                                                                                                                                                      \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                                    6. exp-to-powN/A

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

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

                                                                                                                                                      \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                                                    9. lower-exp.f64N/A

                                                                                                                                                      \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                                    10. lower-/.f6457.6

                                                                                                                                                      \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                                                                                                  5. Applied rewrites57.6%

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

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

                                                                                                                                                      \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                                                    2. Step-by-step derivation
                                                                                                                                                      1. Applied rewrites46.5%

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

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

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

                                                                                                                                                      Alternative 21: 33.4% accurate, 11.6× speedup?

                                                                                                                                                      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;a \leq 2 \cdot 10^{-34}:\\ \;\;\;\;\frac{\frac{x}{a}}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{a \cdot y}\\ \end{array} \end{array} \]
                                                                                                                                                      (FPCore (x y z t a b)
                                                                                                                                                       :precision binary64
                                                                                                                                                       (if (<= a 2e-34) (/ (/ x a) y) (/ x (* a y))))
                                                                                                                                                      double code(double x, double y, double z, double t, double a, double b) {
                                                                                                                                                      	double tmp;
                                                                                                                                                      	if (a <= 2e-34) {
                                                                                                                                                      		tmp = (x / a) / y;
                                                                                                                                                      	} else {
                                                                                                                                                      		tmp = x / (a * y);
                                                                                                                                                      	}
                                                                                                                                                      	return tmp;
                                                                                                                                                      }
                                                                                                                                                      
                                                                                                                                                      module fmin_fmax_functions
                                                                                                                                                          implicit none
                                                                                                                                                          private
                                                                                                                                                          public fmax
                                                                                                                                                          public fmin
                                                                                                                                                      
                                                                                                                                                          interface fmax
                                                                                                                                                              module procedure fmax88
                                                                                                                                                              module procedure fmax44
                                                                                                                                                              module procedure fmax84
                                                                                                                                                              module procedure fmax48
                                                                                                                                                          end interface
                                                                                                                                                          interface fmin
                                                                                                                                                              module procedure fmin88
                                                                                                                                                              module procedure fmin44
                                                                                                                                                              module procedure fmin84
                                                                                                                                                              module procedure fmin48
                                                                                                                                                          end interface
                                                                                                                                                      contains
                                                                                                                                                          real(8) function fmax88(x, y) result (res)
                                                                                                                                                              real(8), intent (in) :: x
                                                                                                                                                              real(8), intent (in) :: y
                                                                                                                                                              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                                                                                          end function
                                                                                                                                                          real(4) function fmax44(x, y) result (res)
                                                                                                                                                              real(4), intent (in) :: x
                                                                                                                                                              real(4), intent (in) :: y
                                                                                                                                                              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                                                                                          end function
                                                                                                                                                          real(8) function fmax84(x, y) result(res)
                                                                                                                                                              real(8), intent (in) :: x
                                                                                                                                                              real(4), intent (in) :: y
                                                                                                                                                              res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                                                                                                          end function
                                                                                                                                                          real(8) function fmax48(x, y) result(res)
                                                                                                                                                              real(4), intent (in) :: x
                                                                                                                                                              real(8), intent (in) :: y
                                                                                                                                                              res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                                                                                                          end function
                                                                                                                                                          real(8) function fmin88(x, y) result (res)
                                                                                                                                                              real(8), intent (in) :: x
                                                                                                                                                              real(8), intent (in) :: y
                                                                                                                                                              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                                                                                          end function
                                                                                                                                                          real(4) function fmin44(x, y) result (res)
                                                                                                                                                              real(4), intent (in) :: x
                                                                                                                                                              real(4), intent (in) :: y
                                                                                                                                                              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                                                                                          end function
                                                                                                                                                          real(8) function fmin84(x, y) result(res)
                                                                                                                                                              real(8), intent (in) :: x
                                                                                                                                                              real(4), intent (in) :: y
                                                                                                                                                              res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                                                                                                          end function
                                                                                                                                                          real(8) function fmin48(x, y) result(res)
                                                                                                                                                              real(4), intent (in) :: x
                                                                                                                                                              real(8), intent (in) :: y
                                                                                                                                                              res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                                                                                                          end function
                                                                                                                                                      end module
                                                                                                                                                      
                                                                                                                                                      real(8) function code(x, y, z, t, a, b)
                                                                                                                                                      use fmin_fmax_functions
                                                                                                                                                          real(8), intent (in) :: x
                                                                                                                                                          real(8), intent (in) :: y
                                                                                                                                                          real(8), intent (in) :: z
                                                                                                                                                          real(8), intent (in) :: t
                                                                                                                                                          real(8), intent (in) :: a
                                                                                                                                                          real(8), intent (in) :: b
                                                                                                                                                          real(8) :: tmp
                                                                                                                                                          if (a <= 2d-34) then
                                                                                                                                                              tmp = (x / a) / y
                                                                                                                                                          else
                                                                                                                                                              tmp = x / (a * y)
                                                                                                                                                          end if
                                                                                                                                                          code = tmp
                                                                                                                                                      end function
                                                                                                                                                      
                                                                                                                                                      public static double code(double x, double y, double z, double t, double a, double b) {
                                                                                                                                                      	double tmp;
                                                                                                                                                      	if (a <= 2e-34) {
                                                                                                                                                      		tmp = (x / a) / y;
                                                                                                                                                      	} else {
                                                                                                                                                      		tmp = x / (a * y);
                                                                                                                                                      	}
                                                                                                                                                      	return tmp;
                                                                                                                                                      }
                                                                                                                                                      
                                                                                                                                                      def code(x, y, z, t, a, b):
                                                                                                                                                      	tmp = 0
                                                                                                                                                      	if a <= 2e-34:
                                                                                                                                                      		tmp = (x / a) / y
                                                                                                                                                      	else:
                                                                                                                                                      		tmp = x / (a * y)
                                                                                                                                                      	return tmp
                                                                                                                                                      
                                                                                                                                                      function code(x, y, z, t, a, b)
                                                                                                                                                      	tmp = 0.0
                                                                                                                                                      	if (a <= 2e-34)
                                                                                                                                                      		tmp = Float64(Float64(x / a) / y);
                                                                                                                                                      	else
                                                                                                                                                      		tmp = Float64(x / Float64(a * y));
                                                                                                                                                      	end
                                                                                                                                                      	return tmp
                                                                                                                                                      end
                                                                                                                                                      
                                                                                                                                                      function tmp_2 = code(x, y, z, t, a, b)
                                                                                                                                                      	tmp = 0.0;
                                                                                                                                                      	if (a <= 2e-34)
                                                                                                                                                      		tmp = (x / a) / y;
                                                                                                                                                      	else
                                                                                                                                                      		tmp = x / (a * y);
                                                                                                                                                      	end
                                                                                                                                                      	tmp_2 = tmp;
                                                                                                                                                      end
                                                                                                                                                      
                                                                                                                                                      code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, 2e-34], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision], N[(x / N[(a * y), $MachinePrecision]), $MachinePrecision]]
                                                                                                                                                      
                                                                                                                                                      \begin{array}{l}
                                                                                                                                                      
                                                                                                                                                      \\
                                                                                                                                                      \begin{array}{l}
                                                                                                                                                      \mathbf{if}\;a \leq 2 \cdot 10^{-34}:\\
                                                                                                                                                      \;\;\;\;\frac{\frac{x}{a}}{y}\\
                                                                                                                                                      
                                                                                                                                                      \mathbf{else}:\\
                                                                                                                                                      \;\;\;\;\frac{x}{a \cdot y}\\
                                                                                                                                                      
                                                                                                                                                      
                                                                                                                                                      \end{array}
                                                                                                                                                      \end{array}
                                                                                                                                                      
                                                                                                                                                      Derivation
                                                                                                                                                      1. Split input into 2 regimes
                                                                                                                                                      2. if a < 1.99999999999999986e-34

                                                                                                                                                        1. Initial program 99.4%

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

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

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

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

                                                                                                                                                            \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                                                          4. exp-diffN/A

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

                                                                                                                                                            \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                                          6. exp-to-powN/A

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

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

                                                                                                                                                            \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                                                          9. lower-exp.f64N/A

                                                                                                                                                            \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                                          10. lower-/.f6461.2

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

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

                                                                                                                                                          \[\leadsto \frac{x}{\color{blue}{a \cdot \left(y \cdot e^{b}\right)}} \]
                                                                                                                                                        7. Step-by-step derivation
                                                                                                                                                          1. Applied rewrites51.0%

                                                                                                                                                            \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                                                          2. Taylor expanded in b around 0

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

                                                                                                                                                              \[\leadsto \frac{x}{a \cdot y} \]
                                                                                                                                                            2. Taylor expanded in b around 0

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

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

                                                                                                                                                              if 1.99999999999999986e-34 < a

                                                                                                                                                              1. Initial program 97.3%

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

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

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

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

                                                                                                                                                                  \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                                                                4. exp-diffN/A

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

                                                                                                                                                                  \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                                                6. exp-to-powN/A

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

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

                                                                                                                                                                  \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                                                                9. lower-exp.f64N/A

                                                                                                                                                                  \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                                                10. lower-/.f6454.1

                                                                                                                                                                  \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                                                                                                              5. Applied rewrites54.1%

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

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

                                                                                                                                                                  \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                                                                2. Taylor expanded in b around 0

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

                                                                                                                                                                    \[\leadsto \frac{x}{a \cdot y} \]
                                                                                                                                                                4. Recombined 2 regimes into one program.
                                                                                                                                                                5. Add Preprocessing

                                                                                                                                                                Alternative 22: 31.7% accurate, 19.8× speedup?

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

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

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

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

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

                                                                                                                                                                    \[\leadsto \color{blue}{e^{\log a \cdot \left(t - 1\right) - b} \cdot \frac{x}{y}} \]
                                                                                                                                                                  4. exp-diffN/A

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

                                                                                                                                                                    \[\leadsto \color{blue}{\frac{e^{\log a \cdot \left(t - 1\right)}}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                                                  6. exp-to-powN/A

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

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

                                                                                                                                                                    \[\leadsto \frac{{a}^{\color{blue}{\left(t - 1\right)}}}{e^{b}} \cdot \frac{x}{y} \]
                                                                                                                                                                  9. lower-exp.f64N/A

                                                                                                                                                                    \[\leadsto \frac{{a}^{\left(t - 1\right)}}{\color{blue}{e^{b}}} \cdot \frac{x}{y} \]
                                                                                                                                                                  10. lower-/.f6457.5

                                                                                                                                                                    \[\leadsto \frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot \color{blue}{\frac{x}{y}} \]
                                                                                                                                                                5. Applied rewrites57.5%

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

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

                                                                                                                                                                    \[\leadsto \frac{x}{\color{blue}{\left(e^{b} \cdot y\right) \cdot a}} \]
                                                                                                                                                                  2. Taylor expanded in b around 0

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

                                                                                                                                                                      \[\leadsto \frac{x}{a \cdot y} \]
                                                                                                                                                                    2. Add Preprocessing

                                                                                                                                                                    Developer Target 1: 71.7% accurate, 1.0× speedup?

                                                                                                                                                                    \[\begin{array}{l} \\ \begin{array}{l} t_1 := {a}^{\left(t - 1\right)}\\ t_2 := \frac{x \cdot \frac{t\_1}{y}}{\left(b + 1\right) - y \cdot \log z}\\ \mathbf{if}\;t < -0.8845848504127471:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t < 852031.2288374073:\\ \;\;\;\;\frac{\frac{x}{y} \cdot t\_1}{e^{b - \log z \cdot y}}\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
                                                                                                                                                                    (FPCore (x y z t a b)
                                                                                                                                                                     :precision binary64
                                                                                                                                                                     (let* ((t_1 (pow a (- t 1.0)))
                                                                                                                                                                            (t_2 (/ (* x (/ t_1 y)) (- (+ b 1.0) (* y (log z))))))
                                                                                                                                                                       (if (< t -0.8845848504127471)
                                                                                                                                                                         t_2
                                                                                                                                                                         (if (< t 852031.2288374073)
                                                                                                                                                                           (/ (* (/ x y) t_1) (exp (- b (* (log z) y))))
                                                                                                                                                                           t_2))))
                                                                                                                                                                    double code(double x, double y, double z, double t, double a, double b) {
                                                                                                                                                                    	double t_1 = pow(a, (t - 1.0));
                                                                                                                                                                    	double t_2 = (x * (t_1 / y)) / ((b + 1.0) - (y * log(z)));
                                                                                                                                                                    	double tmp;
                                                                                                                                                                    	if (t < -0.8845848504127471) {
                                                                                                                                                                    		tmp = t_2;
                                                                                                                                                                    	} else if (t < 852031.2288374073) {
                                                                                                                                                                    		tmp = ((x / y) * t_1) / exp((b - (log(z) * y)));
                                                                                                                                                                    	} else {
                                                                                                                                                                    		tmp = t_2;
                                                                                                                                                                    	}
                                                                                                                                                                    	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) :: t_2
                                                                                                                                                                        real(8) :: tmp
                                                                                                                                                                        t_1 = a ** (t - 1.0d0)
                                                                                                                                                                        t_2 = (x * (t_1 / y)) / ((b + 1.0d0) - (y * log(z)))
                                                                                                                                                                        if (t < (-0.8845848504127471d0)) then
                                                                                                                                                                            tmp = t_2
                                                                                                                                                                        else if (t < 852031.2288374073d0) then
                                                                                                                                                                            tmp = ((x / y) * t_1) / exp((b - (log(z) * y)))
                                                                                                                                                                        else
                                                                                                                                                                            tmp = t_2
                                                                                                                                                                        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 = Math.pow(a, (t - 1.0));
                                                                                                                                                                    	double t_2 = (x * (t_1 / y)) / ((b + 1.0) - (y * Math.log(z)));
                                                                                                                                                                    	double tmp;
                                                                                                                                                                    	if (t < -0.8845848504127471) {
                                                                                                                                                                    		tmp = t_2;
                                                                                                                                                                    	} else if (t < 852031.2288374073) {
                                                                                                                                                                    		tmp = ((x / y) * t_1) / Math.exp((b - (Math.log(z) * y)));
                                                                                                                                                                    	} else {
                                                                                                                                                                    		tmp = t_2;
                                                                                                                                                                    	}
                                                                                                                                                                    	return tmp;
                                                                                                                                                                    }
                                                                                                                                                                    
                                                                                                                                                                    def code(x, y, z, t, a, b):
                                                                                                                                                                    	t_1 = math.pow(a, (t - 1.0))
                                                                                                                                                                    	t_2 = (x * (t_1 / y)) / ((b + 1.0) - (y * math.log(z)))
                                                                                                                                                                    	tmp = 0
                                                                                                                                                                    	if t < -0.8845848504127471:
                                                                                                                                                                    		tmp = t_2
                                                                                                                                                                    	elif t < 852031.2288374073:
                                                                                                                                                                    		tmp = ((x / y) * t_1) / math.exp((b - (math.log(z) * y)))
                                                                                                                                                                    	else:
                                                                                                                                                                    		tmp = t_2
                                                                                                                                                                    	return tmp
                                                                                                                                                                    
                                                                                                                                                                    function code(x, y, z, t, a, b)
                                                                                                                                                                    	t_1 = a ^ Float64(t - 1.0)
                                                                                                                                                                    	t_2 = Float64(Float64(x * Float64(t_1 / y)) / Float64(Float64(b + 1.0) - Float64(y * log(z))))
                                                                                                                                                                    	tmp = 0.0
                                                                                                                                                                    	if (t < -0.8845848504127471)
                                                                                                                                                                    		tmp = t_2;
                                                                                                                                                                    	elseif (t < 852031.2288374073)
                                                                                                                                                                    		tmp = Float64(Float64(Float64(x / y) * t_1) / exp(Float64(b - Float64(log(z) * y))));
                                                                                                                                                                    	else
                                                                                                                                                                    		tmp = t_2;
                                                                                                                                                                    	end
                                                                                                                                                                    	return tmp
                                                                                                                                                                    end
                                                                                                                                                                    
                                                                                                                                                                    function tmp_2 = code(x, y, z, t, a, b)
                                                                                                                                                                    	t_1 = a ^ (t - 1.0);
                                                                                                                                                                    	t_2 = (x * (t_1 / y)) / ((b + 1.0) - (y * log(z)));
                                                                                                                                                                    	tmp = 0.0;
                                                                                                                                                                    	if (t < -0.8845848504127471)
                                                                                                                                                                    		tmp = t_2;
                                                                                                                                                                    	elseif (t < 852031.2288374073)
                                                                                                                                                                    		tmp = ((x / y) * t_1) / exp((b - (log(z) * y)));
                                                                                                                                                                    	else
                                                                                                                                                                    		tmp = t_2;
                                                                                                                                                                    	end
                                                                                                                                                                    	tmp_2 = tmp;
                                                                                                                                                                    end
                                                                                                                                                                    
                                                                                                                                                                    code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * N[(t$95$1 / y), $MachinePrecision]), $MachinePrecision] / N[(N[(b + 1.0), $MachinePrecision] - N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[t, -0.8845848504127471], t$95$2, If[Less[t, 852031.2288374073], N[(N[(N[(x / y), $MachinePrecision] * t$95$1), $MachinePrecision] / N[Exp[N[(b - N[(N[Log[z], $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], t$95$2]]]]
                                                                                                                                                                    
                                                                                                                                                                    \begin{array}{l}
                                                                                                                                                                    
                                                                                                                                                                    \\
                                                                                                                                                                    \begin{array}{l}
                                                                                                                                                                    t_1 := {a}^{\left(t - 1\right)}\\
                                                                                                                                                                    t_2 := \frac{x \cdot \frac{t\_1}{y}}{\left(b + 1\right) - y \cdot \log z}\\
                                                                                                                                                                    \mathbf{if}\;t < -0.8845848504127471:\\
                                                                                                                                                                    \;\;\;\;t\_2\\
                                                                                                                                                                    
                                                                                                                                                                    \mathbf{elif}\;t < 852031.2288374073:\\
                                                                                                                                                                    \;\;\;\;\frac{\frac{x}{y} \cdot t\_1}{e^{b - \log z \cdot y}}\\
                                                                                                                                                                    
                                                                                                                                                                    \mathbf{else}:\\
                                                                                                                                                                    \;\;\;\;t\_2\\
                                                                                                                                                                    
                                                                                                                                                                    
                                                                                                                                                                    \end{array}
                                                                                                                                                                    \end{array}
                                                                                                                                                                    

                                                                                                                                                                    Reproduce

                                                                                                                                                                    ?
                                                                                                                                                                    herbie shell --seed 2025016 
                                                                                                                                                                    (FPCore (x y z t a b)
                                                                                                                                                                      :name "Numeric.SpecFunctions:incompleteBetaWorker from math-functions-0.1.5.2, A"
                                                                                                                                                                      :precision binary64
                                                                                                                                                                    
                                                                                                                                                                      :alt
                                                                                                                                                                      (! :herbie-platform default (if (< t -8845848504127471/10000000000000000) (/ (* x (/ (pow a (- t 1)) y)) (- (+ b 1) (* y (log z)))) (if (< t 8520312288374073/10000000000) (/ (* (/ x y) (pow a (- t 1))) (exp (- b (* (log z) y)))) (/ (* x (/ (pow a (- t 1)) y)) (- (+ b 1) (* y (log z)))))))
                                                                                                                                                                    
                                                                                                                                                                      (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))