Graphics.Rendering.Chart.Axis.Types:linMap from Chart-1.5.3

Percentage Accurate: 68.1% → 89.7%
Time: 4.9s
Alternatives: 16
Speedup: 0.8×

Specification

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

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

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

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

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 16 alternatives:

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

Initial Program: 68.1% accurate, 1.0× speedup?

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

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

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

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

Alternative 1: 89.7% accurate, 0.7× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -4.5e150 or 1.15e139 < t

    1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
      10. sub-negate-revN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y + -1 \cdot \frac{z \cdot \left(y - x\right) - a \cdot \left(y - x\right)}{t} \]
      8. lower--.f6446.0

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

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

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

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

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

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

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

        \[\leadsto y - \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(\frac{z \cdot \left(y - x\right) - a \cdot \left(y - x\right)}{t}\right)\right)\right)\right) \]
      7. distribute-neg-fracN/A

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \left(y - x\right) \cdot \color{blue}{\left(\left(z - a\right) \cdot \frac{1}{t}\right)} \]
      17. mult-flip-revN/A

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

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

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

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

    if -4.5e150 < t < 1.15e139

    1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
      10. sub-negate-revN/A

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

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

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

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

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

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

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

Alternative 2: 77.5% accurate, 0.8× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -2.85e29 or 4.3e43 < a

    1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
      10. sub-negate-revN/A

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

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

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

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

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

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

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

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

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

      if -2.85e29 < a < 4.3e43

      1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

          \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
        10. sub-negate-revN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto y + -1 \cdot \frac{z \cdot \left(y - x\right) - a \cdot \left(y - x\right)}{t} \]
        8. lower--.f6446.0

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

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

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

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

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

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

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

          \[\leadsto y - \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(\frac{z \cdot \left(y - x\right) - a \cdot \left(y - x\right)}{t}\right)\right)\right)\right) \]
        7. distribute-neg-fracN/A

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

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

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

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

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

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

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

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

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

          \[\leadsto y - \left(y - x\right) \cdot \color{blue}{\left(\left(z - a\right) \cdot \frac{1}{t}\right)} \]
        17. mult-flip-revN/A

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

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

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

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

    Alternative 3: 72.3% accurate, 0.8× speedup?

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

      1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

          \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y - x\right) \cdot \frac{1}{a - t}, z - t, x\right)} \]
        10. mult-flip-revN/A

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

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

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

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

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

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

          \[\leadsto \mathsf{fma}\left(\frac{x - y}{\mathsf{neg}\left(\color{blue}{\left(a - t\right)}\right)}, z - t, x\right) \]
        17. sub-negate-revN/A

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

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

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

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

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

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

          \[\leadsto \frac{z \cdot \left(x - y\right)}{t - a} \]
        4. lower--.f6438.1

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

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

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

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

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

          \[\leadsto z \cdot \frac{x - y}{\color{blue}{t} - a} \]
        5. sub-divN/A

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

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

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

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

          \[\leadsto \left(\frac{x}{t - a} - \frac{y}{t - a}\right) \cdot \color{blue}{z} \]
        10. lower-*.f6442.4

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

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

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

          \[\leadsto \left(\frac{x}{t - a} - \frac{y}{t - a}\right) \cdot z \]
        14. sub-divN/A

          \[\leadsto \frac{x - y}{t - a} \cdot z \]
        15. lift--.f64N/A

          \[\leadsto \frac{x - y}{t - a} \cdot z \]
        16. lower-/.f6442.6

          \[\leadsto \frac{x - y}{t - a} \cdot z \]
      8. Applied rewrites42.6%

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

      if -2.24999999999999999e55 < z < 2.2e198

      1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

          \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
        10. sub-negate-revN/A

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

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

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

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

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

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

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

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

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

        if 2.2e198 < z

        1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

            \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y - x\right) \cdot \frac{1}{a - t}, z - t, x\right)} \]
          10. mult-flip-revN/A

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

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

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

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

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

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

            \[\leadsto \mathsf{fma}\left(\frac{x - y}{\mathsf{neg}\left(\color{blue}{\left(a - t\right)}\right)}, z - t, x\right) \]
          17. sub-negate-revN/A

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

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

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

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

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

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

            \[\leadsto \frac{z \cdot \left(x - y\right)}{t - a} \]
          4. lower--.f6438.1

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

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

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

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

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

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

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

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

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

      Alternative 4: 65.7% accurate, 0.7× speedup?

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

        1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

            \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y - x\right) \cdot \frac{1}{a - t}, z - t, x\right)} \]
          10. mult-flip-revN/A

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

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

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

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

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

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

            \[\leadsto \mathsf{fma}\left(\frac{x - y}{\mathsf{neg}\left(\color{blue}{\left(a - t\right)}\right)}, z - t, x\right) \]
          17. sub-negate-revN/A

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

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

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

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

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

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

            \[\leadsto \frac{z \cdot \left(x - y\right)}{t - a} \]
          4. lower--.f6438.1

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

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

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

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

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

            \[\leadsto z \cdot \frac{x - y}{\color{blue}{t} - a} \]
          5. sub-divN/A

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

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

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

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

            \[\leadsto \left(\frac{x}{t - a} - \frac{y}{t - a}\right) \cdot \color{blue}{z} \]
          10. lower-*.f6442.4

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

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

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

            \[\leadsto \left(\frac{x}{t - a} - \frac{y}{t - a}\right) \cdot z \]
          14. sub-divN/A

            \[\leadsto \frac{x - y}{t - a} \cdot z \]
          15. lift--.f64N/A

            \[\leadsto \frac{x - y}{t - a} \cdot z \]
          16. lower-/.f6442.6

            \[\leadsto \frac{x - y}{t - a} \cdot z \]
        8. Applied rewrites42.6%

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

        if -3.7000000000000002e83 < z < -1.64999999999999991e-78

        1. Initial program 68.1%

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

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

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

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

            \[\leadsto \frac{y \cdot \left(z - t\right)}{a - t} \]
          4. lower--.f6440.1

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

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

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

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

            \[\leadsto y \cdot \color{blue}{\frac{z - t}{a - t}} \]
          4. lift--.f64N/A

            \[\leadsto y \cdot \frac{z - t}{\color{blue}{a} - t} \]
          5. sub-negate-revN/A

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

            \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{a - t} \]
          7. lift--.f64N/A

            \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{a - \color{blue}{t}} \]
          8. sub-negate-revN/A

            \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \]
          9. lift--.f64N/A

            \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \]
          10. frac-2negN/A

            \[\leadsto y \cdot \frac{t - z}{\color{blue}{t - a}} \]
          11. lift-/.f64N/A

            \[\leadsto y \cdot \frac{t - z}{\color{blue}{t - a}} \]
          12. *-commutativeN/A

            \[\leadsto \frac{t - z}{t - a} \cdot \color{blue}{y} \]
          13. lower-*.f6451.7

            \[\leadsto \frac{t - z}{t - a} \cdot \color{blue}{y} \]
          14. lift-/.f64N/A

            \[\leadsto \frac{t - z}{t - a} \cdot y \]
          15. frac-2negN/A

            \[\leadsto \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
          16. lift--.f64N/A

            \[\leadsto \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
          17. sub-negate-revN/A

            \[\leadsto \frac{z - t}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
          18. lift--.f64N/A

            \[\leadsto \frac{z - t}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
          19. lift--.f64N/A

            \[\leadsto \frac{z - t}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
          20. sub-negate-revN/A

            \[\leadsto \frac{z - t}{a - t} \cdot y \]
          21. lift--.f64N/A

            \[\leadsto \frac{z - t}{a - t} \cdot y \]
          22. lower-/.f6451.7

            \[\leadsto \frac{z - t}{a - t} \cdot y \]
        6. Applied rewrites51.7%

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

        if -1.64999999999999991e-78 < z < 2.1999999999999998e140

        1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

            \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
          10. sub-negate-revN/A

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

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

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

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

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

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

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

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

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

          if 2.1999999999999998e140 < z

          1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

              \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y - x\right) \cdot \frac{1}{a - t}, z - t, x\right)} \]
            10. mult-flip-revN/A

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(\frac{x - y}{\mathsf{neg}\left(\color{blue}{\left(a - t\right)}\right)}, z - t, x\right) \]
            17. sub-negate-revN/A

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

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

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

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

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

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

              \[\leadsto \frac{z \cdot \left(x - y\right)}{t - a} \]
            4. lower--.f6438.1

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

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

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

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

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

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

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

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

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

        Alternative 5: 64.9% accurate, 0.8× speedup?

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

          1. Initial program 68.1%

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

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

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

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

              \[\leadsto \frac{y \cdot \left(z - t\right)}{a - t} \]
            4. lower--.f6440.1

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

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

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

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

              \[\leadsto y \cdot \color{blue}{\frac{z - t}{a - t}} \]
            4. lift--.f64N/A

              \[\leadsto y \cdot \frac{z - t}{\color{blue}{a} - t} \]
            5. sub-negate-revN/A

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

              \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{a - t} \]
            7. lift--.f64N/A

              \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{a - \color{blue}{t}} \]
            8. sub-negate-revN/A

              \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \]
            9. lift--.f64N/A

              \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \]
            10. frac-2negN/A

              \[\leadsto y \cdot \frac{t - z}{\color{blue}{t - a}} \]
            11. lift-/.f64N/A

              \[\leadsto y \cdot \frac{t - z}{\color{blue}{t - a}} \]
            12. *-commutativeN/A

              \[\leadsto \frac{t - z}{t - a} \cdot \color{blue}{y} \]
            13. lower-*.f6451.7

              \[\leadsto \frac{t - z}{t - a} \cdot \color{blue}{y} \]
            14. lift-/.f64N/A

              \[\leadsto \frac{t - z}{t - a} \cdot y \]
            15. frac-2negN/A

              \[\leadsto \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
            16. lift--.f64N/A

              \[\leadsto \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
            17. sub-negate-revN/A

              \[\leadsto \frac{z - t}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
            18. lift--.f64N/A

              \[\leadsto \frac{z - t}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
            19. lift--.f64N/A

              \[\leadsto \frac{z - t}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
            20. sub-negate-revN/A

              \[\leadsto \frac{z - t}{a - t} \cdot y \]
            21. lift--.f64N/A

              \[\leadsto \frac{z - t}{a - t} \cdot y \]
            22. lower-/.f6451.7

              \[\leadsto \frac{z - t}{a - t} \cdot y \]
          6. Applied rewrites51.7%

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

          if -0.065000000000000002 < y < 1.4000000000000001e-29

          1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

              \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y - x\right) \cdot \frac{1}{a - t}, z - t, x\right)} \]
            10. mult-flip-revN/A

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(\frac{x - y}{\mathsf{neg}\left(\color{blue}{\left(a - t\right)}\right)}, z - t, x\right) \]
            17. sub-negate-revN/A

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

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

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

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

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

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

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

        Alternative 6: 64.6% accurate, 0.9× speedup?

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

          1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
            10. sub-negate-revN/A

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

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

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

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

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

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

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

            \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{z}{a}}, y - x, x\right) \]
          5. Step-by-step derivation
            1. lower-/.f6449.4

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

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

          if -2.7e98 < a < 8.4999999999999998e79

          1. Initial program 68.1%

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

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

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

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

              \[\leadsto \frac{y \cdot \left(z - t\right)}{a - t} \]
            4. lower--.f6440.1

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

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

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

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

              \[\leadsto y \cdot \color{blue}{\frac{z - t}{a - t}} \]
            4. lift--.f64N/A

              \[\leadsto y \cdot \frac{z - t}{\color{blue}{a} - t} \]
            5. sub-negate-revN/A

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

              \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{a - t} \]
            7. lift--.f64N/A

              \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{a - \color{blue}{t}} \]
            8. sub-negate-revN/A

              \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \]
            9. lift--.f64N/A

              \[\leadsto y \cdot \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \]
            10. frac-2negN/A

              \[\leadsto y \cdot \frac{t - z}{\color{blue}{t - a}} \]
            11. lift-/.f64N/A

              \[\leadsto y \cdot \frac{t - z}{\color{blue}{t - a}} \]
            12. *-commutativeN/A

              \[\leadsto \frac{t - z}{t - a} \cdot \color{blue}{y} \]
            13. lower-*.f6451.7

              \[\leadsto \frac{t - z}{t - a} \cdot \color{blue}{y} \]
            14. lift-/.f64N/A

              \[\leadsto \frac{t - z}{t - a} \cdot y \]
            15. frac-2negN/A

              \[\leadsto \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
            16. lift--.f64N/A

              \[\leadsto \frac{\mathsf{neg}\left(\left(t - z\right)\right)}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
            17. sub-negate-revN/A

              \[\leadsto \frac{z - t}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
            18. lift--.f64N/A

              \[\leadsto \frac{z - t}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
            19. lift--.f64N/A

              \[\leadsto \frac{z - t}{\mathsf{neg}\left(\left(t - a\right)\right)} \cdot y \]
            20. sub-negate-revN/A

              \[\leadsto \frac{z - t}{a - t} \cdot y \]
            21. lift--.f64N/A

              \[\leadsto \frac{z - t}{a - t} \cdot y \]
            22. lower-/.f6451.7

              \[\leadsto \frac{z - t}{a - t} \cdot y \]
          6. Applied rewrites51.7%

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

        Alternative 7: 61.3% accurate, 0.9× speedup?

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

          1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
            10. sub-negate-revN/A

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

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

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

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

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

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

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

            \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{z}{a}}, y - x, x\right) \]
          5. Step-by-step derivation
            1. lower-/.f6449.4

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

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

          if -4.99999999999999999e97 < a < 8.4999999999999998e79

          1. Initial program 68.1%

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

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

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

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

              \[\leadsto \frac{y \cdot \left(z - t\right)}{a - t} \]
            4. lower--.f6440.1

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

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

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

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

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

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

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

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

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

        Alternative 8: 60.4% accurate, 0.9× speedup?

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

          1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
            10. sub-negate-revN/A

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

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

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

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(\frac{t - z}{t}, y - x, x\right) \]
          6. Applied rewrites38.2%

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

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

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

            if -9.5000000000000005e-57 < t < 4e14

            1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
              10. sub-negate-revN/A

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

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{z}{a}}, y - x, x\right) \]
            5. Step-by-step derivation
              1. lower-/.f6449.4

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

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

          Alternative 9: 57.0% accurate, 0.9× speedup?

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

            1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
              10. sub-negate-revN/A

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

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(\color{blue}{1}, y - x, x\right) \]
            5. Step-by-step derivation
              1. Applied rewrites19.4%

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

              if -1.11999999999999992e149 < t < 9.80000000000000021e120

              1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                  \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
                10. sub-negate-revN/A

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

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

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

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

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

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

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

                \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{z}{a}}, y - x, x\right) \]
              5. Step-by-step derivation
                1. lower-/.f6449.4

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

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

            Alternative 10: 32.2% accurate, 1.0× speedup?

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

              1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                  \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y - x\right) \cdot \frac{1}{a - t}, z - t, x\right)} \]
                10. mult-flip-revN/A

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

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

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

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

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

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

                  \[\leadsto \mathsf{fma}\left(\frac{x - y}{\mathsf{neg}\left(\color{blue}{\left(a - t\right)}\right)}, z - t, x\right) \]
                17. sub-negate-revN/A

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto z \cdot \frac{x - y}{\color{blue}{t}} \]
              8. Step-by-step derivation
                1. lower-/.f64N/A

                  \[\leadsto z \cdot \frac{x - y}{t} \]
                2. lower--.f6425.5

                  \[\leadsto z \cdot \frac{x - y}{t} \]
              9. Applied rewrites25.5%

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

              if -4.59999999999999988e54 < z < 1.59999999999999997e158

              1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                  \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
                10. sub-negate-revN/A

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

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

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

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

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

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

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

                \[\leadsto \mathsf{fma}\left(\color{blue}{1}, y - x, x\right) \]
              5. Step-by-step derivation
                1. Applied rewrites19.4%

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

                if 1.59999999999999997e158 < z

                1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y - x\right) \cdot \frac{1}{a - t}, z - t, x\right)} \]
                  10. mult-flip-revN/A

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

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

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

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

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

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

                    \[\leadsto \mathsf{fma}\left(\frac{x - y}{\mathsf{neg}\left(\color{blue}{\left(a - t\right)}\right)}, z - t, x\right) \]
                  17. sub-negate-revN/A

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

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

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

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

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

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

                    \[\leadsto \frac{z \cdot \left(x - y\right)}{t - a} \]
                  4. lower--.f6438.1

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

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

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

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

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

                    \[\leadsto \frac{z \cdot \left(x - y\right)}{t} \]
                9. Applied rewrites23.7%

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

              Alternative 11: 31.4% accurate, 1.0× speedup?

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

                1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y - x\right) \cdot \frac{1}{a - t}, z - t, x\right)} \]
                  10. mult-flip-revN/A

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

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

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

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

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

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

                    \[\leadsto \mathsf{fma}\left(\frac{x - y}{\mathsf{neg}\left(\color{blue}{\left(a - t\right)}\right)}, z - t, x\right) \]
                  17. sub-negate-revN/A

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

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

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

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

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

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

                    \[\leadsto \frac{z \cdot \left(x - y\right)}{t - a} \]
                  4. lower--.f6438.1

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

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

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

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

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

                    \[\leadsto \frac{z \cdot \left(x - y\right)}{t} \]
                9. Applied rewrites23.7%

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

                if -4.59999999999999988e54 < z < 1.59999999999999997e158

                1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                    \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
                  10. sub-negate-revN/A

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

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

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

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

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

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

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

                  \[\leadsto \mathsf{fma}\left(\color{blue}{1}, y - x, x\right) \]
                5. Step-by-step derivation
                  1. Applied rewrites19.4%

                    \[\leadsto \mathsf{fma}\left(\color{blue}{1}, y - x, x\right) \]
                6. Recombined 2 regimes into one program.
                7. Add Preprocessing

                Alternative 12: 30.2% accurate, 1.0× speedup?

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

                  1. Initial program 68.1%

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

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

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

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

                      \[\leadsto \frac{y \cdot \left(z - t\right)}{a - t} \]
                    4. lower--.f6440.1

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

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

                    \[\leadsto \frac{y \cdot z}{\color{blue}{a} - t} \]
                  6. Step-by-step derivation
                    1. lower-*.f6421.6

                      \[\leadsto \frac{y \cdot z}{a - t} \]
                  7. Applied rewrites21.6%

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

                  if -7.30000000000000045e-56 < y < 9.4999999999999997e-94

                  1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                      \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
                    10. sub-negate-revN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto y + -1 \cdot \frac{z \cdot \left(y - x\right) - a \cdot \left(y - x\right)}{t} \]
                    8. lower--.f6446.0

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

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

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

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

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

                      \[\leadsto \frac{x \cdot \left(z - a\right)}{t} \]
                  9. Applied rewrites19.8%

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

                  if 9.4999999999999997e-94 < y

                  1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                      \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
                    10. sub-negate-revN/A

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

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

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

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

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

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

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

                    \[\leadsto \mathsf{fma}\left(\color{blue}{1}, y - x, x\right) \]
                  5. Step-by-step derivation
                    1. Applied rewrites19.4%

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

                  Alternative 13: 29.1% accurate, 1.0× speedup?

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

                    1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                        \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
                      10. sub-negate-revN/A

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

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

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

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

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

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

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

                      \[\leadsto \mathsf{fma}\left(\color{blue}{1}, y - x, x\right) \]
                    5. Step-by-step derivation
                      1. Applied rewrites19.4%

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

                      if -3.79999999999999997e80 < t < 1.10000000000000004e23

                      1. Initial program 68.1%

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

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

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

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

                          \[\leadsto \frac{y \cdot \left(z - t\right)}{a - t} \]
                        4. lower--.f6440.1

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

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

                        \[\leadsto \frac{y \cdot z}{\color{blue}{a} - t} \]
                      6. Step-by-step derivation
                        1. lower-*.f6421.6

                          \[\leadsto \frac{y \cdot z}{a - t} \]
                      7. Applied rewrites21.6%

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

                    Alternative 14: 28.5% accurate, 1.1× speedup?

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

                      1. Initial program 68.1%

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

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

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

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

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

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

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

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

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

                          \[\leadsto \mathsf{fma}\left(\frac{\mathsf{neg}\left(\color{blue}{\left(z - t\right)}\right)}{\mathsf{neg}\left(\left(a - t\right)\right)}, y - x, x\right) \]
                        10. sub-negate-revN/A

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

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

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

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

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

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

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

                        \[\leadsto \mathsf{fma}\left(\color{blue}{1}, y - x, x\right) \]
                      5. Step-by-step derivation
                        1. Applied rewrites19.4%

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

                        if -1.6e19 < t < 26.5

                        1. Initial program 68.1%

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

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

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

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

                            \[\leadsto \frac{y \cdot \left(z - t\right)}{a - t} \]
                          4. lower--.f6440.1

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

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

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

                            \[\leadsto \frac{y \cdot z}{a} \]
                          2. lower-*.f6417.1

                            \[\leadsto \frac{y \cdot z}{a} \]
                        7. Applied rewrites17.1%

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

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

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

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

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

                            \[\leadsto \frac{z}{a} \cdot y \]
                          6. lower-/.f6419.5

                            \[\leadsto \frac{z}{a} \cdot y \]
                        9. Applied rewrites19.5%

                          \[\leadsto \frac{z}{a} \cdot y \]
                      6. Recombined 2 regimes into one program.
                      7. Add Preprocessing

                      Alternative 15: 19.5% accurate, 2.4× speedup?

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

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

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

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

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

                          \[\leadsto \frac{y \cdot \left(z - t\right)}{a - t} \]
                        4. lower--.f6440.1

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

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

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

                          \[\leadsto \frac{y \cdot z}{a} \]
                        2. lower-*.f6417.1

                          \[\leadsto \frac{y \cdot z}{a} \]
                      7. Applied rewrites17.1%

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

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

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

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

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

                          \[\leadsto \frac{z}{a} \cdot y \]
                        6. lower-/.f6419.5

                          \[\leadsto \frac{z}{a} \cdot y \]
                      9. Applied rewrites19.5%

                        \[\leadsto \frac{z}{a} \cdot y \]
                      10. Add Preprocessing

                      Alternative 16: 18.6% accurate, 2.4× speedup?

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

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

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

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

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

                          \[\leadsto \frac{y \cdot \left(z - t\right)}{a - t} \]
                        4. lower--.f6440.1

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

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

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

                          \[\leadsto \frac{y \cdot z}{a} \]
                        2. lower-*.f6417.1

                          \[\leadsto \frac{y \cdot z}{a} \]
                      7. Applied rewrites17.1%

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

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

                          \[\leadsto \frac{y \cdot z}{a} \]
                        3. *-commutativeN/A

                          \[\leadsto \frac{z \cdot y}{a} \]
                        4. associate-/l*N/A

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

                          \[\leadsto z \cdot \frac{y}{\color{blue}{a}} \]
                        6. lower-/.f6418.6

                          \[\leadsto z \cdot \frac{y}{a} \]
                      9. Applied rewrites18.6%

                        \[\leadsto z \cdot \frac{y}{\color{blue}{a}} \]
                      10. Add Preprocessing

                      Reproduce

                      ?
                      herbie shell --seed 2025155 
                      (FPCore (x y z t a)
                        :name "Graphics.Rendering.Chart.Axis.Types:linMap from Chart-1.5.3"
                        :precision binary64
                        (+ x (/ (* (- y x) (- z t)) (- a t))))