Graphics.Rendering.Chart.SparkLine:renderSparkLine from Chart-1.5.3

Percentage Accurate: 97.1% → 99.6%
Time: 12.2s
Alternatives: 16
Speedup: 1.3×

Specification

?
\[\begin{array}{l} \\ x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (- x (/ (- y z) (/ (+ (- t z) 1.0) a))))
double code(double x, double y, double z, double t, double a) {
	return x - ((y - z) / (((t - z) + 1.0) / a));
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    code = x - ((y - z) / (((t - z) + 1.0d0) / a))
end function
public static double code(double x, double y, double z, double t, double a) {
	return x - ((y - z) / (((t - z) + 1.0) / a));
}
def code(x, y, z, t, a):
	return x - ((y - z) / (((t - z) + 1.0) / a))
function code(x, y, z, t, a)
	return Float64(x - Float64(Float64(y - z) / Float64(Float64(Float64(t - z) + 1.0) / a)))
end
function tmp = code(x, y, z, t, a)
	tmp = x - ((y - z) / (((t - z) + 1.0) / a));
end
code[x_, y_, z_, t_, a_] := N[(x - N[(N[(y - z), $MachinePrecision] / N[(N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

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

\[\begin{array}{l} \\ x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (- x (/ (- y z) (/ (+ (- t z) 1.0) a))))
double code(double x, double y, double z, double t, double a) {
	return x - ((y - z) / (((t - z) + 1.0) / a));
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    code = x - ((y - z) / (((t - z) + 1.0d0) / a))
end function
public static double code(double x, double y, double z, double t, double a) {
	return x - ((y - z) / (((t - z) + 1.0) / a));
}
def code(x, y, z, t, a):
	return x - ((y - z) / (((t - z) + 1.0) / a))
function code(x, y, z, t, a)
	return Float64(x - Float64(Float64(y - z) / Float64(Float64(Float64(t - z) + 1.0) / a)))
end
function tmp = code(x, y, z, t, a)
	tmp = x - ((y - z) / (((t - z) + 1.0) / a));
end
code[x_, y_, z_, t_, a_] := N[(x - N[(N[(y - z), $MachinePrecision] / N[(N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

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

Alternative 1: 99.6% accurate, 1.0× speedup?

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

\\
x + \frac{a}{\frac{\left(t - z\right) + 1}{z - y}}
\end{array}
Derivation
  1. Initial program 97.7%

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

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

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

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

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

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

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

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

      \[\leadsto x - \frac{a}{\frac{\color{blue}{\left(t - z\right)} + 1}{y - z}} \]
    9. --lowering--.f6499.5

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

    \[\leadsto x - \color{blue}{\frac{a}{\frac{\left(t - z\right) + 1}{y - z}}} \]
  5. Final simplification99.5%

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

Alternative 2: 56.9% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{y - z}{\frac{\left(t - z\right) + 1}{a}}\\ \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+113}:\\ \;\;\;\;0 - a\\ \mathbf{elif}\;t\_1 \leq 10^{+172}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;0 - a\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (/ (- y z) (/ (+ (- t z) 1.0) a))))
   (if (<= t_1 -4e+113) (- 0.0 a) (if (<= t_1 1e+172) x (- 0.0 a)))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = (y - z) / (((t - z) + 1.0) / a);
	double tmp;
	if (t_1 <= -4e+113) {
		tmp = 0.0 - a;
	} else if (t_1 <= 1e+172) {
		tmp = x;
	} else {
		tmp = 0.0 - a;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = (y - z) / (((t - z) + 1.0d0) / a)
    if (t_1 <= (-4d+113)) then
        tmp = 0.0d0 - a
    else if (t_1 <= 1d+172) then
        tmp = x
    else
        tmp = 0.0d0 - a
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = (y - z) / (((t - z) + 1.0) / a);
	double tmp;
	if (t_1 <= -4e+113) {
		tmp = 0.0 - a;
	} else if (t_1 <= 1e+172) {
		tmp = x;
	} else {
		tmp = 0.0 - a;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = (y - z) / (((t - z) + 1.0) / a)
	tmp = 0
	if t_1 <= -4e+113:
		tmp = 0.0 - a
	elif t_1 <= 1e+172:
		tmp = x
	else:
		tmp = 0.0 - a
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(Float64(y - z) / Float64(Float64(Float64(t - z) + 1.0) / a))
	tmp = 0.0
	if (t_1 <= -4e+113)
		tmp = Float64(0.0 - a);
	elseif (t_1 <= 1e+172)
		tmp = x;
	else
		tmp = Float64(0.0 - a);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = (y - z) / (((t - z) + 1.0) / a);
	tmp = 0.0;
	if (t_1 <= -4e+113)
		tmp = 0.0 - a;
	elseif (t_1 <= 1e+172)
		tmp = x;
	else
		tmp = 0.0 - a;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(y - z), $MachinePrecision] / N[(N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -4e+113], N[(0.0 - a), $MachinePrecision], If[LessEqual[t$95$1, 1e+172], x, N[(0.0 - a), $MachinePrecision]]]]
\begin{array}{l}

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

\mathbf{elif}\;t\_1 \leq 10^{+172}:\\
\;\;\;\;x\\

\mathbf{else}:\\
\;\;\;\;0 - a\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (/.f64 (-.f64 y z) (/.f64 (+.f64 (-.f64 t z) #s(literal 1 binary64)) a)) < -4e113 or 1.0000000000000001e172 < (/.f64 (-.f64 y z) (/.f64 (+.f64 (-.f64 t z) #s(literal 1 binary64)) a))

    1. Initial program 99.7%

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

      \[\leadsto x - \color{blue}{a} \]
    4. Step-by-step derivation
      1. Simplified43.0%

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

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

          \[\leadsto \color{blue}{\mathsf{neg}\left(a\right)} \]
        2. neg-sub0N/A

          \[\leadsto \color{blue}{0 - a} \]
        3. --lowering--.f6434.0

          \[\leadsto \color{blue}{0 - a} \]
      4. Simplified34.0%

        \[\leadsto \color{blue}{0 - a} \]
      5. Step-by-step derivation
        1. sub0-negN/A

          \[\leadsto \color{blue}{\mathsf{neg}\left(a\right)} \]
        2. neg-lowering-neg.f6434.0

          \[\leadsto \color{blue}{-a} \]
      6. Applied egg-rr34.0%

        \[\leadsto \color{blue}{-a} \]

      if -4e113 < (/.f64 (-.f64 y z) (/.f64 (+.f64 (-.f64 t z) #s(literal 1 binary64)) a)) < 1.0000000000000001e172

      1. Initial program 97.0%

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

        \[\leadsto \color{blue}{x} \]
      4. Step-by-step derivation
        1. Simplified69.8%

          \[\leadsto \color{blue}{x} \]
      5. Recombined 2 regimes into one program.
      6. Final simplification60.6%

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

      Alternative 3: 92.3% accurate, 1.0× speedup?

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

        1. Initial program 97.7%

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

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

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

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

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

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

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

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

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

            \[\leadsto \mathsf{fma}\left(\frac{y - z}{\mathsf{neg}\left(\color{blue}{\left(1 + \left(t - z\right)\right)}\right)}, a, x\right) \]
          10. distribute-neg-inN/A

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

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

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

            \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{-1 - \left(t - z\right)}}, a, x\right) \]
          14. --lowering--.f6499.9

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

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

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

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

          if -5.15000000000000009e64 < z < 5.49999999999999979e-13

          1. Initial program 99.9%

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

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

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

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(\frac{y - z}{\mathsf{neg}\left(\color{blue}{\left(1 + \left(t - z\right)\right)}\right)}, a, x\right) \]
            10. distribute-neg-inN/A

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

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

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

              \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{-1 - \left(t - z\right)}}, a, x\right) \]
            14. --lowering--.f6499.2

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

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

            \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{-1 \cdot \left(1 + t\right)}}, a, x\right) \]
          6. Step-by-step derivation
            1. distribute-lft-inN/A

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

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

              \[\leadsto \mathsf{fma}\left(\frac{y - z}{-1 + \color{blue}{\left(\mathsf{neg}\left(t\right)\right)}}, a, x\right) \]
            4. unsub-negN/A

              \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{-1 - t}}, a, x\right) \]
            5. --lowering--.f6496.7

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

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

          if 5.49999999999999979e-13 < z

          1. Initial program 92.8%

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(a, \frac{z}{\color{blue}{t + \left(1 - z\right)}}, x\right) \]
            11. --lowering--.f6483.6

              \[\leadsto \mathsf{fma}\left(a, \frac{z}{t + \color{blue}{\left(1 - z\right)}}, x\right) \]
          5. Simplified83.6%

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

        Alternative 4: 90.2% accurate, 1.0× speedup?

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

          1. Initial program 94.3%

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

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

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

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

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

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

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

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

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

              \[\leadsto \mathsf{fma}\left(\frac{y - z}{\mathsf{neg}\left(\color{blue}{\left(1 + \left(t - z\right)\right)}\right)}, a, x\right) \]
            10. distribute-neg-inN/A

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

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

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

              \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{-1 - \left(t - z\right)}}, a, x\right) \]
            14. --lowering--.f6499.8

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

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

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

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

            if -2.1499999999999998e38 < y < 1.2e37

            1. Initial program 99.8%

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \mathsf{fma}\left(a, \frac{z}{\color{blue}{t + \left(1 - z\right)}}, x\right) \]
              11. --lowering--.f6492.9

                \[\leadsto \mathsf{fma}\left(a, \frac{z}{t + \color{blue}{\left(1 - z\right)}}, x\right) \]
            5. Simplified92.9%

              \[\leadsto \color{blue}{\mathsf{fma}\left(a, \frac{z}{t + \left(1 - z\right)}, x\right)} \]
          7. Recombined 2 regimes into one program.
          8. Final simplification92.7%

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

          Alternative 5: 88.6% accurate, 1.0× speedup?

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

            1. Initial program 98.0%

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

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

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

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

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

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

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

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

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

                \[\leadsto \mathsf{fma}\left(\frac{y - z}{\mathsf{neg}\left(\color{blue}{\left(1 + \left(t - z\right)\right)}\right)}, a, x\right) \]
              10. distribute-neg-inN/A

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

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

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

                \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{-1 - \left(t - z\right)}}, a, x\right) \]
              14. --lowering--.f6499.9

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

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

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

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

              if -1.45000000000000003e38 < z < 1.4000000000000001e-13

              1. Initial program 99.9%

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

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

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

                  \[\leadsto x - \color{blue}{y \cdot \frac{a}{1 + t}} \]
                3. *-lowering-*.f64N/A

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

                  \[\leadsto x - y \cdot \color{blue}{\frac{a}{1 + t}} \]
                5. +-lowering-+.f6493.2

                  \[\leadsto x - y \cdot \frac{a}{\color{blue}{1 + t}} \]
              5. Simplified93.2%

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

              if 1.4000000000000001e-13 < z

              1. Initial program 92.8%

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \mathsf{fma}\left(a, \frac{z}{\color{blue}{t + \left(1 - z\right)}}, x\right) \]
                11. --lowering--.f6483.6

                  \[\leadsto \mathsf{fma}\left(a, \frac{z}{t + \color{blue}{\left(1 - z\right)}}, x\right) \]
              5. Simplified83.6%

                \[\leadsto \color{blue}{\mathsf{fma}\left(a, \frac{z}{t + \left(1 - z\right)}, x\right)} \]
            7. Recombined 3 regimes into one program.
            8. Final simplification90.7%

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

            Alternative 6: 88.5% accurate, 1.0× speedup?

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

              1. Initial program 95.7%

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

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

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

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

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

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

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

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

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

                  \[\leadsto \mathsf{fma}\left(\frac{y - z}{\mathsf{neg}\left(\color{blue}{\left(1 + \left(t - z\right)\right)}\right)}, a, x\right) \]
                10. distribute-neg-inN/A

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

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

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

                  \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{-1 - \left(t - z\right)}}, a, x\right) \]
                14. --lowering--.f6499.9

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

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

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

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

                if -1.66e38 < z < 2.79999999999999983e30

                1. Initial program 99.2%

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

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

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

                    \[\leadsto x - \color{blue}{y \cdot \frac{a}{1 + t}} \]
                  3. *-lowering-*.f64N/A

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

                    \[\leadsto x - y \cdot \color{blue}{\frac{a}{1 + t}} \]
                  5. +-lowering-+.f6490.3

                    \[\leadsto x - y \cdot \frac{a}{\color{blue}{1 + t}} \]
                5. Simplified90.3%

                  \[\leadsto x - \color{blue}{y \cdot \frac{a}{1 + t}} \]
              7. Recombined 2 regimes into one program.
              8. Final simplification89.7%

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

              Alternative 7: 88.9% accurate, 1.1× speedup?

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

                1. Initial program 95.7%

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

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

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

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

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

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

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

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

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

                    \[\leadsto \mathsf{fma}\left(\frac{y - z}{\mathsf{neg}\left(\color{blue}{\left(1 + \left(t - z\right)\right)}\right)}, a, x\right) \]
                  10. distribute-neg-inN/A

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

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

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

                    \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{-1 - \left(t - z\right)}}, a, x\right) \]
                  14. --lowering--.f6499.9

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

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

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

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

                  if -1.45000000000000003e38 < z < 2.8999999999999998e30

                  1. Initial program 99.2%

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

                    \[\leadsto \color{blue}{x - \frac{a \cdot y}{1 + t}} \]
                  4. Step-by-step derivation
                    1. sub-negN/A

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

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

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

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

                      \[\leadsto \color{blue}{\mathsf{fma}\left(a, \mathsf{neg}\left(\frac{y}{1 + t}\right), x\right)} \]
                    6. distribute-neg-frac2N/A

                      \[\leadsto \mathsf{fma}\left(a, \color{blue}{\frac{y}{\mathsf{neg}\left(\left(1 + t\right)\right)}}, x\right) \]
                    7. /-lowering-/.f64N/A

                      \[\leadsto \mathsf{fma}\left(a, \color{blue}{\frac{y}{\mathsf{neg}\left(\left(1 + t\right)\right)}}, x\right) \]
                    8. distribute-neg-inN/A

                      \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{\left(\mathsf{neg}\left(1\right)\right) + \left(\mathsf{neg}\left(t\right)\right)}}, x\right) \]
                    9. metadata-evalN/A

                      \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{-1} + \left(\mathsf{neg}\left(t\right)\right)}, x\right) \]
                    10. unsub-negN/A

                      \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{-1 - t}}, x\right) \]
                    11. --lowering--.f6490.3

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

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

                Alternative 8: 87.3% accurate, 1.1× speedup?

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

                  1. Initial program 95.7%

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

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

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

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

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

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

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

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

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

                      \[\leadsto \mathsf{fma}\left(\frac{y - z}{\mathsf{neg}\left(\color{blue}{\left(1 + \left(t - z\right)\right)}\right)}, a, x\right) \]
                    10. distribute-neg-inN/A

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

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

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

                      \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{-1 - \left(t - z\right)}}, a, x\right) \]
                    14. --lowering--.f6499.9

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

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

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

                      \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{z}}, a, x\right) \]
                    2. Step-by-step derivation
                      1. *-commutativeN/A

                        \[\leadsto \color{blue}{a \cdot \frac{y - z}{z}} + x \]
                      2. clear-numN/A

                        \[\leadsto a \cdot \color{blue}{\frac{1}{\frac{z}{y - z}}} + x \]
                      3. metadata-evalN/A

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

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

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

                        \[\leadsto \color{blue}{\frac{a}{z} \cdot \frac{-1 \cdot -1}{\frac{1}{y - z}}} + x \]
                      7. metadata-evalN/A

                        \[\leadsto \frac{a}{z} \cdot \frac{\color{blue}{1}}{\frac{1}{y - z}} + x \]
                      8. flip--N/A

                        \[\leadsto \frac{a}{z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{y \cdot y - z \cdot z}{y + z}}}} + x \]
                      9. clear-numN/A

                        \[\leadsto \frac{a}{z} \cdot \frac{1}{\color{blue}{\frac{y + z}{y \cdot y - z \cdot z}}} + x \]
                      10. clear-numN/A

                        \[\leadsto \frac{a}{z} \cdot \color{blue}{\frac{y \cdot y - z \cdot z}{y + z}} + x \]
                      11. flip--N/A

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

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

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

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

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

                    if -2.8e38 < z < 2.24999999999999997e30

                    1. Initial program 99.2%

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

                      \[\leadsto \color{blue}{x - \frac{a \cdot y}{1 + t}} \]
                    4. Step-by-step derivation
                      1. sub-negN/A

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

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

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

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

                        \[\leadsto \color{blue}{\mathsf{fma}\left(a, \mathsf{neg}\left(\frac{y}{1 + t}\right), x\right)} \]
                      6. distribute-neg-frac2N/A

                        \[\leadsto \mathsf{fma}\left(a, \color{blue}{\frac{y}{\mathsf{neg}\left(\left(1 + t\right)\right)}}, x\right) \]
                      7. /-lowering-/.f64N/A

                        \[\leadsto \mathsf{fma}\left(a, \color{blue}{\frac{y}{\mathsf{neg}\left(\left(1 + t\right)\right)}}, x\right) \]
                      8. distribute-neg-inN/A

                        \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{\left(\mathsf{neg}\left(1\right)\right) + \left(\mathsf{neg}\left(t\right)\right)}}, x\right) \]
                      9. metadata-evalN/A

                        \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{-1} + \left(\mathsf{neg}\left(t\right)\right)}, x\right) \]
                      10. unsub-negN/A

                        \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{-1 - t}}, x\right) \]
                      11. --lowering--.f6490.3

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

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

                  Alternative 9: 84.5% accurate, 1.1× speedup?

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

                    1. Initial program 97.6%

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

                      \[\leadsto x - \color{blue}{a} \]
                    4. Step-by-step derivation
                      1. Simplified83.7%

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

                      if -4.79999999999999974e70 < z < 6.0000000000000002e-6

                      1. Initial program 99.9%

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

                        \[\leadsto \color{blue}{x - \frac{a \cdot y}{1 + t}} \]
                      4. Step-by-step derivation
                        1. sub-negN/A

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

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

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

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

                          \[\leadsto \color{blue}{\mathsf{fma}\left(a, \mathsf{neg}\left(\frac{y}{1 + t}\right), x\right)} \]
                        6. distribute-neg-frac2N/A

                          \[\leadsto \mathsf{fma}\left(a, \color{blue}{\frac{y}{\mathsf{neg}\left(\left(1 + t\right)\right)}}, x\right) \]
                        7. /-lowering-/.f64N/A

                          \[\leadsto \mathsf{fma}\left(a, \color{blue}{\frac{y}{\mathsf{neg}\left(\left(1 + t\right)\right)}}, x\right) \]
                        8. distribute-neg-inN/A

                          \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{\left(\mathsf{neg}\left(1\right)\right) + \left(\mathsf{neg}\left(t\right)\right)}}, x\right) \]
                        9. metadata-evalN/A

                          \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{-1} + \left(\mathsf{neg}\left(t\right)\right)}, x\right) \]
                        10. unsub-negN/A

                          \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{-1 - t}}, x\right) \]
                        11. --lowering--.f6490.4

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

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

                      if 6.0000000000000002e-6 < z

                      1. Initial program 92.7%

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

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

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

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

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

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

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

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

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

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

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

                          \[\leadsto \mathsf{fma}\left(a, \frac{z}{\color{blue}{t + \left(1 - z\right)}}, x\right) \]
                        11. --lowering--.f6483.3

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

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

                        \[\leadsto \color{blue}{x + \frac{a \cdot z}{1 - z}} \]
                      7. Step-by-step derivation
                        1. +-commutativeN/A

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

                          \[\leadsto \color{blue}{a \cdot \frac{z}{1 - z}} + x \]
                        3. accelerator-lowering-fma.f64N/A

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

                          \[\leadsto \mathsf{fma}\left(a, \color{blue}{\frac{z}{1 - z}}, x\right) \]
                        5. --lowering--.f6470.2

                          \[\leadsto \mathsf{fma}\left(a, \frac{z}{\color{blue}{1 - z}}, x\right) \]
                      8. Simplified70.2%

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

                    Alternative 10: 84.8% accurate, 1.1× speedup?

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

                      1. Initial program 95.3%

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

                        \[\leadsto x - \color{blue}{a} \]
                      4. Step-by-step derivation
                        1. Simplified77.7%

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

                        if -7.0000000000000002e65 < z < 2.59999999999999988e30

                        1. Initial program 99.2%

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

                          \[\leadsto \color{blue}{x - \frac{a \cdot y}{1 + t}} \]
                        4. Step-by-step derivation
                          1. sub-negN/A

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

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

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

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

                            \[\leadsto \color{blue}{\mathsf{fma}\left(a, \mathsf{neg}\left(\frac{y}{1 + t}\right), x\right)} \]
                          6. distribute-neg-frac2N/A

                            \[\leadsto \mathsf{fma}\left(a, \color{blue}{\frac{y}{\mathsf{neg}\left(\left(1 + t\right)\right)}}, x\right) \]
                          7. /-lowering-/.f64N/A

                            \[\leadsto \mathsf{fma}\left(a, \color{blue}{\frac{y}{\mathsf{neg}\left(\left(1 + t\right)\right)}}, x\right) \]
                          8. distribute-neg-inN/A

                            \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{\left(\mathsf{neg}\left(1\right)\right) + \left(\mathsf{neg}\left(t\right)\right)}}, x\right) \]
                          9. metadata-evalN/A

                            \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{-1} + \left(\mathsf{neg}\left(t\right)\right)}, x\right) \]
                          10. unsub-negN/A

                            \[\leadsto \mathsf{fma}\left(a, \frac{y}{\color{blue}{-1 - t}}, x\right) \]
                          11. --lowering--.f6488.4

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

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

                      Alternative 11: 68.8% accurate, 1.1× speedup?

                      \[\begin{array}{l} \\ \begin{array}{l} t_1 := x - y \cdot \frac{a}{t}\\ \mathbf{if}\;t \leq -1.2 \cdot 10^{+32}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 2.95 \cdot 10^{+66}:\\ \;\;\;\;x - a\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                      (FPCore (x y z t a)
                       :precision binary64
                       (let* ((t_1 (- x (* y (/ a t)))))
                         (if (<= t -1.2e+32) t_1 (if (<= t 2.95e+66) (- x a) t_1))))
                      double code(double x, double y, double z, double t, double a) {
                      	double t_1 = x - (y * (a / t));
                      	double tmp;
                      	if (t <= -1.2e+32) {
                      		tmp = t_1;
                      	} else if (t <= 2.95e+66) {
                      		tmp = x - a;
                      	} else {
                      		tmp = t_1;
                      	}
                      	return tmp;
                      }
                      
                      real(8) function code(x, y, z, t, a)
                          real(8), intent (in) :: x
                          real(8), intent (in) :: y
                          real(8), intent (in) :: z
                          real(8), intent (in) :: t
                          real(8), intent (in) :: a
                          real(8) :: t_1
                          real(8) :: tmp
                          t_1 = x - (y * (a / t))
                          if (t <= (-1.2d+32)) then
                              tmp = t_1
                          else if (t <= 2.95d+66) then
                              tmp = x - a
                          else
                              tmp = t_1
                          end if
                          code = tmp
                      end function
                      
                      public static double code(double x, double y, double z, double t, double a) {
                      	double t_1 = x - (y * (a / t));
                      	double tmp;
                      	if (t <= -1.2e+32) {
                      		tmp = t_1;
                      	} else if (t <= 2.95e+66) {
                      		tmp = x - a;
                      	} else {
                      		tmp = t_1;
                      	}
                      	return tmp;
                      }
                      
                      def code(x, y, z, t, a):
                      	t_1 = x - (y * (a / t))
                      	tmp = 0
                      	if t <= -1.2e+32:
                      		tmp = t_1
                      	elif t <= 2.95e+66:
                      		tmp = x - a
                      	else:
                      		tmp = t_1
                      	return tmp
                      
                      function code(x, y, z, t, a)
                      	t_1 = Float64(x - Float64(y * Float64(a / t)))
                      	tmp = 0.0
                      	if (t <= -1.2e+32)
                      		tmp = t_1;
                      	elseif (t <= 2.95e+66)
                      		tmp = Float64(x - a);
                      	else
                      		tmp = t_1;
                      	end
                      	return tmp
                      end
                      
                      function tmp_2 = code(x, y, z, t, a)
                      	t_1 = x - (y * (a / t));
                      	tmp = 0.0;
                      	if (t <= -1.2e+32)
                      		tmp = t_1;
                      	elseif (t <= 2.95e+66)
                      		tmp = x - a;
                      	else
                      		tmp = t_1;
                      	end
                      	tmp_2 = tmp;
                      end
                      
                      code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x - N[(y * N[(a / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.2e+32], t$95$1, If[LessEqual[t, 2.95e+66], N[(x - a), $MachinePrecision], t$95$1]]]
                      
                      \begin{array}{l}
                      
                      \\
                      \begin{array}{l}
                      t_1 := x - y \cdot \frac{a}{t}\\
                      \mathbf{if}\;t \leq -1.2 \cdot 10^{+32}:\\
                      \;\;\;\;t\_1\\
                      
                      \mathbf{elif}\;t \leq 2.95 \cdot 10^{+66}:\\
                      \;\;\;\;x - a\\
                      
                      \mathbf{else}:\\
                      \;\;\;\;t\_1\\
                      
                      
                      \end{array}
                      \end{array}
                      
                      Derivation
                      1. Split input into 2 regimes
                      2. if t < -1.19999999999999996e32 or 2.94999999999999994e66 < t

                        1. Initial program 98.0%

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

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

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

                            \[\leadsto x - \color{blue}{y \cdot \frac{a}{1 + t}} \]
                          3. *-lowering-*.f64N/A

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

                            \[\leadsto x - y \cdot \color{blue}{\frac{a}{1 + t}} \]
                          5. +-lowering-+.f6484.0

                            \[\leadsto x - y \cdot \frac{a}{\color{blue}{1 + t}} \]
                        5. Simplified84.0%

                          \[\leadsto x - \color{blue}{y \cdot \frac{a}{1 + t}} \]
                        6. Taylor expanded in t around inf

                          \[\leadsto x - y \cdot \color{blue}{\frac{a}{t}} \]
                        7. Step-by-step derivation
                          1. /-lowering-/.f6484.0

                            \[\leadsto x - y \cdot \color{blue}{\frac{a}{t}} \]
                        8. Simplified84.0%

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

                        if -1.19999999999999996e32 < t < 2.94999999999999994e66

                        1. Initial program 97.5%

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

                          \[\leadsto x - \color{blue}{a} \]
                        4. Step-by-step derivation
                          1. Simplified66.1%

                            \[\leadsto x - \color{blue}{a} \]
                        5. Recombined 2 regimes into one program.
                        6. Add Preprocessing

                        Alternative 12: 99.7% accurate, 1.3× speedup?

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

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

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

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

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

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

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

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

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

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

                            \[\leadsto \mathsf{fma}\left(\frac{y - z}{\mathsf{neg}\left(\color{blue}{\left(1 + \left(t - z\right)\right)}\right)}, a, x\right) \]
                          10. distribute-neg-inN/A

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

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

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

                            \[\leadsto \mathsf{fma}\left(\frac{y - z}{\color{blue}{-1 - \left(t - z\right)}}, a, x\right) \]
                          14. --lowering--.f6499.5

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

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

                          \[\leadsto \mathsf{fma}\left(\frac{y - z}{-1 + \left(z - t\right)}, a, x\right) \]
                        6. Add Preprocessing

                        Alternative 13: 97.3% accurate, 1.3× speedup?

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

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

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

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

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

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

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

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

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

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

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

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

                          \[\leadsto \mathsf{fma}\left(\frac{a}{-1 + \left(z - t\right)}, y - z, x\right) \]
                        6. Add Preprocessing

                        Alternative 14: 72.1% accurate, 1.7× speedup?

                        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1 \cdot 10^{+69}:\\ \;\;\;\;x - a\\ \mathbf{elif}\;z \leq 58:\\ \;\;\;\;x - a \cdot y\\ \mathbf{else}:\\ \;\;\;\;x - a\\ \end{array} \end{array} \]
                        (FPCore (x y z t a)
                         :precision binary64
                         (if (<= z -1e+69) (- x a) (if (<= z 58.0) (- x (* a y)) (- x a))))
                        double code(double x, double y, double z, double t, double a) {
                        	double tmp;
                        	if (z <= -1e+69) {
                        		tmp = x - a;
                        	} else if (z <= 58.0) {
                        		tmp = x - (a * y);
                        	} else {
                        		tmp = x - a;
                        	}
                        	return tmp;
                        }
                        
                        real(8) function code(x, y, z, t, a)
                            real(8), intent (in) :: x
                            real(8), intent (in) :: y
                            real(8), intent (in) :: z
                            real(8), intent (in) :: t
                            real(8), intent (in) :: a
                            real(8) :: tmp
                            if (z <= (-1d+69)) then
                                tmp = x - a
                            else if (z <= 58.0d0) then
                                tmp = x - (a * y)
                            else
                                tmp = x - a
                            end if
                            code = tmp
                        end function
                        
                        public static double code(double x, double y, double z, double t, double a) {
                        	double tmp;
                        	if (z <= -1e+69) {
                        		tmp = x - a;
                        	} else if (z <= 58.0) {
                        		tmp = x - (a * y);
                        	} else {
                        		tmp = x - a;
                        	}
                        	return tmp;
                        }
                        
                        def code(x, y, z, t, a):
                        	tmp = 0
                        	if z <= -1e+69:
                        		tmp = x - a
                        	elif z <= 58.0:
                        		tmp = x - (a * y)
                        	else:
                        		tmp = x - a
                        	return tmp
                        
                        function code(x, y, z, t, a)
                        	tmp = 0.0
                        	if (z <= -1e+69)
                        		tmp = Float64(x - a);
                        	elseif (z <= 58.0)
                        		tmp = Float64(x - Float64(a * y));
                        	else
                        		tmp = Float64(x - a);
                        	end
                        	return tmp
                        end
                        
                        function tmp_2 = code(x, y, z, t, a)
                        	tmp = 0.0;
                        	if (z <= -1e+69)
                        		tmp = x - a;
                        	elseif (z <= 58.0)
                        		tmp = x - (a * y);
                        	else
                        		tmp = x - a;
                        	end
                        	tmp_2 = tmp;
                        end
                        
                        code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1e+69], N[(x - a), $MachinePrecision], If[LessEqual[z, 58.0], N[(x - N[(a * y), $MachinePrecision]), $MachinePrecision], N[(x - a), $MachinePrecision]]]
                        
                        \begin{array}{l}
                        
                        \\
                        \begin{array}{l}
                        \mathbf{if}\;z \leq -1 \cdot 10^{+69}:\\
                        \;\;\;\;x - a\\
                        
                        \mathbf{elif}\;z \leq 58:\\
                        \;\;\;\;x - a \cdot y\\
                        
                        \mathbf{else}:\\
                        \;\;\;\;x - a\\
                        
                        
                        \end{array}
                        \end{array}
                        
                        Derivation
                        1. Split input into 2 regimes
                        2. if z < -1.0000000000000001e69 or 58 < z

                          1. Initial program 94.6%

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

                            \[\leadsto x - \color{blue}{a} \]
                          4. Step-by-step derivation
                            1. Simplified75.2%

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

                            if -1.0000000000000001e69 < z < 58

                            1. Initial program 99.9%

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

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

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

                                \[\leadsto x - \color{blue}{y \cdot \frac{a}{1 + t}} \]
                              3. *-lowering-*.f64N/A

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

                                \[\leadsto x - y \cdot \color{blue}{\frac{a}{1 + t}} \]
                              5. +-lowering-+.f6489.9

                                \[\leadsto x - y \cdot \frac{a}{\color{blue}{1 + t}} \]
                            5. Simplified89.9%

                              \[\leadsto x - \color{blue}{y \cdot \frac{a}{1 + t}} \]
                            6. Taylor expanded in t around 0

                              \[\leadsto x - y \cdot \color{blue}{a} \]
                            7. Step-by-step derivation
                              1. Simplified69.7%

                                \[\leadsto x - y \cdot \color{blue}{a} \]
                            8. Recombined 2 regimes into one program.
                            9. Final simplification72.0%

                              \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1 \cdot 10^{+69}:\\ \;\;\;\;x - a\\ \mathbf{elif}\;z \leq 58:\\ \;\;\;\;x - a \cdot y\\ \mathbf{else}:\\ \;\;\;\;x - a\\ \end{array} \]
                            10. Add Preprocessing

                            Alternative 15: 65.4% accurate, 2.2× speedup?

                            \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -2 \cdot 10^{+44}:\\ \;\;\;\;x - a\\ \mathbf{elif}\;z \leq 4.3 \cdot 10^{+39}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;x - a\\ \end{array} \end{array} \]
                            (FPCore (x y z t a)
                             :precision binary64
                             (if (<= z -2e+44) (- x a) (if (<= z 4.3e+39) x (- x a))))
                            double code(double x, double y, double z, double t, double a) {
                            	double tmp;
                            	if (z <= -2e+44) {
                            		tmp = x - a;
                            	} else if (z <= 4.3e+39) {
                            		tmp = x;
                            	} else {
                            		tmp = x - a;
                            	}
                            	return tmp;
                            }
                            
                            real(8) function code(x, y, z, t, a)
                                real(8), intent (in) :: x
                                real(8), intent (in) :: y
                                real(8), intent (in) :: z
                                real(8), intent (in) :: t
                                real(8), intent (in) :: a
                                real(8) :: tmp
                                if (z <= (-2d+44)) then
                                    tmp = x - a
                                else if (z <= 4.3d+39) then
                                    tmp = x
                                else
                                    tmp = x - a
                                end if
                                code = tmp
                            end function
                            
                            public static double code(double x, double y, double z, double t, double a) {
                            	double tmp;
                            	if (z <= -2e+44) {
                            		tmp = x - a;
                            	} else if (z <= 4.3e+39) {
                            		tmp = x;
                            	} else {
                            		tmp = x - a;
                            	}
                            	return tmp;
                            }
                            
                            def code(x, y, z, t, a):
                            	tmp = 0
                            	if z <= -2e+44:
                            		tmp = x - a
                            	elif z <= 4.3e+39:
                            		tmp = x
                            	else:
                            		tmp = x - a
                            	return tmp
                            
                            function code(x, y, z, t, a)
                            	tmp = 0.0
                            	if (z <= -2e+44)
                            		tmp = Float64(x - a);
                            	elseif (z <= 4.3e+39)
                            		tmp = x;
                            	else
                            		tmp = Float64(x - a);
                            	end
                            	return tmp
                            end
                            
                            function tmp_2 = code(x, y, z, t, a)
                            	tmp = 0.0;
                            	if (z <= -2e+44)
                            		tmp = x - a;
                            	elseif (z <= 4.3e+39)
                            		tmp = x;
                            	else
                            		tmp = x - a;
                            	end
                            	tmp_2 = tmp;
                            end
                            
                            code[x_, y_, z_, t_, a_] := If[LessEqual[z, -2e+44], N[(x - a), $MachinePrecision], If[LessEqual[z, 4.3e+39], x, N[(x - a), $MachinePrecision]]]
                            
                            \begin{array}{l}
                            
                            \\
                            \begin{array}{l}
                            \mathbf{if}\;z \leq -2 \cdot 10^{+44}:\\
                            \;\;\;\;x - a\\
                            
                            \mathbf{elif}\;z \leq 4.3 \cdot 10^{+39}:\\
                            \;\;\;\;x\\
                            
                            \mathbf{else}:\\
                            \;\;\;\;x - a\\
                            
                            
                            \end{array}
                            \end{array}
                            
                            Derivation
                            1. Split input into 2 regimes
                            2. if z < -2.0000000000000002e44 or 4.3e39 < z

                              1. Initial program 95.5%

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

                                \[\leadsto x - \color{blue}{a} \]
                              4. Step-by-step derivation
                                1. Simplified76.9%

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

                                if -2.0000000000000002e44 < z < 4.3e39

                                1. Initial program 99.2%

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

                                  \[\leadsto \color{blue}{x} \]
                                4. Step-by-step derivation
                                  1. Simplified62.2%

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

                                Alternative 16: 53.2% accurate, 35.0× speedup?

                                \[\begin{array}{l} \\ x \end{array} \]
                                (FPCore (x y z t a) :precision binary64 x)
                                double code(double x, double y, double z, double t, double a) {
                                	return x;
                                }
                                
                                real(8) function code(x, y, z, t, a)
                                    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
                                end function
                                
                                public static double code(double x, double y, double z, double t, double a) {
                                	return x;
                                }
                                
                                def code(x, y, z, t, a):
                                	return x
                                
                                function code(x, y, z, t, a)
                                	return x
                                end
                                
                                function tmp = code(x, y, z, t, a)
                                	tmp = x;
                                end
                                
                                code[x_, y_, z_, t_, a_] := x
                                
                                \begin{array}{l}
                                
                                \\
                                x
                                \end{array}
                                
                                Derivation
                                1. Initial program 97.7%

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

                                  \[\leadsto \color{blue}{x} \]
                                4. Step-by-step derivation
                                  1. Simplified55.1%

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

                                  Developer Target 1: 99.7% accurate, 1.2× speedup?

                                  \[\begin{array}{l} \\ x - \frac{y - z}{\left(t - z\right) + 1} \cdot a \end{array} \]
                                  (FPCore (x y z t a)
                                   :precision binary64
                                   (- x (* (/ (- y z) (+ (- t z) 1.0)) a)))
                                  double code(double x, double y, double z, double t, double a) {
                                  	return x - (((y - z) / ((t - z) + 1.0)) * a);
                                  }
                                  
                                  real(8) function code(x, y, z, t, a)
                                      real(8), intent (in) :: x
                                      real(8), intent (in) :: y
                                      real(8), intent (in) :: z
                                      real(8), intent (in) :: t
                                      real(8), intent (in) :: a
                                      code = x - (((y - z) / ((t - z) + 1.0d0)) * a)
                                  end function
                                  
                                  public static double code(double x, double y, double z, double t, double a) {
                                  	return x - (((y - z) / ((t - z) + 1.0)) * a);
                                  }
                                  
                                  def code(x, y, z, t, a):
                                  	return x - (((y - z) / ((t - z) + 1.0)) * a)
                                  
                                  function code(x, y, z, t, a)
                                  	return Float64(x - Float64(Float64(Float64(y - z) / Float64(Float64(t - z) + 1.0)) * a))
                                  end
                                  
                                  function tmp = code(x, y, z, t, a)
                                  	tmp = x - (((y - z) / ((t - z) + 1.0)) * a);
                                  end
                                  
                                  code[x_, y_, z_, t_, a_] := N[(x - N[(N[(N[(y - z), $MachinePrecision] / N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  x - \frac{y - z}{\left(t - z\right) + 1} \cdot a
                                  \end{array}
                                  

                                  Reproduce

                                  ?
                                  herbie shell --seed 2024196 
                                  (FPCore (x y z t a)
                                    :name "Graphics.Rendering.Chart.SparkLine:renderSparkLine from Chart-1.5.3"
                                    :precision binary64
                                  
                                    :alt
                                    (! :herbie-platform default (- x (* (/ (- y z) (+ (- t z) 1)) a)))
                                  
                                    (- x (/ (- y z) (/ (+ (- t z) 1.0) a))))