Statistics.Distribution.Poisson.Internal:probability from math-functions-0.1.5.2

Percentage Accurate: 100.0% → 100.0%
Time: 11.1s
Alternatives: 19
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ e^{\left(x + y \cdot \log y\right) - z} \end{array} \]
(FPCore (x y z) :precision binary64 (exp (- (+ x (* y (log y))) z)))
double code(double x, double y, double z) {
	return exp(((x + (y * log(y))) - z));
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = exp(((x + (y * log(y))) - z))
end function
public static double code(double x, double y, double z) {
	return Math.exp(((x + (y * Math.log(y))) - z));
}
def code(x, y, z):
	return math.exp(((x + (y * math.log(y))) - z))
function code(x, y, z)
	return exp(Float64(Float64(x + Float64(y * log(y))) - z))
end
function tmp = code(x, y, z)
	tmp = exp(((x + (y * log(y))) - z));
end
code[x_, y_, z_] := N[Exp[N[(N[(x + N[(y * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - z), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
e^{\left(x + y \cdot \log y\right) - z}
\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 19 alternatives:

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

Initial Program: 100.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ e^{\left(x + y \cdot \log y\right) - z} \end{array} \]
(FPCore (x y z) :precision binary64 (exp (- (+ x (* y (log y))) z)))
double code(double x, double y, double z) {
	return exp(((x + (y * log(y))) - z));
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = exp(((x + (y * log(y))) - z))
end function
public static double code(double x, double y, double z) {
	return Math.exp(((x + (y * Math.log(y))) - z));
}
def code(x, y, z):
	return math.exp(((x + (y * math.log(y))) - z))
function code(x, y, z)
	return exp(Float64(Float64(x + Float64(y * log(y))) - z))
end
function tmp = code(x, y, z)
	tmp = exp(((x + (y * log(y))) - z));
end
code[x_, y_, z_] := N[Exp[N[(N[(x + N[(y * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - z), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
e^{\left(x + y \cdot \log y\right) - z}
\end{array}

Alternative 1: 100.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ e^{\left(x + y \cdot \log y\right) - z} \end{array} \]
(FPCore (x y z) :precision binary64 (exp (- (+ x (* y (log y))) z)))
double code(double x, double y, double z) {
	return exp(((x + (y * log(y))) - z));
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = exp(((x + (y * log(y))) - z))
end function
public static double code(double x, double y, double z) {
	return Math.exp(((x + (y * Math.log(y))) - z));
}
def code(x, y, z):
	return math.exp(((x + (y * math.log(y))) - z))
function code(x, y, z)
	return exp(Float64(Float64(x + Float64(y * log(y))) - z))
end
function tmp = code(x, y, z)
	tmp = exp(((x + (y * log(y))) - z));
end
code[x_, y_, z_] := N[Exp[N[(N[(x + N[(y * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - z), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

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

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

Alternative 2: 56.6% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \left(x + y \cdot \log y\right) - z\\ \mathbf{if}\;t\_0 \leq -5 \cdot 10^{+146}:\\ \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\ \mathbf{elif}\;t\_0 \leq -1 \cdot 10^{+14}:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;t\_0 \leq 5 \cdot 10^{+17}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(z \cdot \mathsf{fma}\left(0.25, z \cdot z, -1\right), \frac{2 + \frac{-4 - \frac{\frac{16}{z} + -8}{z}}{z}}{z}, 1\right)\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (- (+ x (* y (log y))) z)))
   (if (<= t_0 -5e+146)
     (/ -1.0 (fma z (fma z 0.5 -1.0) -1.0))
     (if (<= t_0 -1e+14)
       (* -0.16666666666666666 (* z (* z z)))
       (if (<= t_0 5e+17)
         (fma x (fma x (fma x 0.16666666666666666 0.5) 1.0) 1.0)
         (fma
          (* z (fma 0.25 (* z z) -1.0))
          (/ (+ 2.0 (/ (- -4.0 (/ (+ (/ 16.0 z) -8.0) z)) z)) z)
          1.0))))))
double code(double x, double y, double z) {
	double t_0 = (x + (y * log(y))) - z;
	double tmp;
	if (t_0 <= -5e+146) {
		tmp = -1.0 / fma(z, fma(z, 0.5, -1.0), -1.0);
	} else if (t_0 <= -1e+14) {
		tmp = -0.16666666666666666 * (z * (z * z));
	} else if (t_0 <= 5e+17) {
		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
	} else {
		tmp = fma((z * fma(0.25, (z * z), -1.0)), ((2.0 + ((-4.0 - (((16.0 / z) + -8.0) / z)) / z)) / z), 1.0);
	}
	return tmp;
}
function code(x, y, z)
	t_0 = Float64(Float64(x + Float64(y * log(y))) - z)
	tmp = 0.0
	if (t_0 <= -5e+146)
		tmp = Float64(-1.0 / fma(z, fma(z, 0.5, -1.0), -1.0));
	elseif (t_0 <= -1e+14)
		tmp = Float64(-0.16666666666666666 * Float64(z * Float64(z * z)));
	elseif (t_0 <= 5e+17)
		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
	else
		tmp = fma(Float64(z * fma(0.25, Float64(z * z), -1.0)), Float64(Float64(2.0 + Float64(Float64(-4.0 - Float64(Float64(Float64(16.0 / z) + -8.0) / z)) / z)) / z), 1.0);
	end
	return tmp
end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(x + N[(y * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - z), $MachinePrecision]}, If[LessEqual[t$95$0, -5e+146], N[(-1.0 / N[(z * N[(z * 0.5 + -1.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$0, -1e+14], N[(-0.16666666666666666 * N[(z * N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$0, 5e+17], N[(x * N[(x * N[(x * 0.16666666666666666 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] + 1.0), $MachinePrecision], N[(N[(z * N[(0.25 * N[(z * z), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision] * N[(N[(2.0 + N[(N[(-4.0 - N[(N[(N[(16.0 / z), $MachinePrecision] + -8.0), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision] + 1.0), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \left(x + y \cdot \log y\right) - z\\
\mathbf{if}\;t\_0 \leq -5 \cdot 10^{+146}:\\
\;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\

\mathbf{elif}\;t\_0 \leq -1 \cdot 10^{+14}:\\
\;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\

\mathbf{elif}\;t\_0 \leq 5 \cdot 10^{+17}:\\
\;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(z \cdot \mathsf{fma}\left(0.25, z \cdot z, -1\right), \frac{2 + \frac{-4 - \frac{\frac{16}{z} + -8}{z}}{z}}{z}, 1\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z) < -4.9999999999999999e146

    1. Initial program 100.0%

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

      \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
    4. Step-by-step derivation
      1. mul-1-negN/A

        \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
      2. neg-lowering-neg.f6460.6

        \[\leadsto e^{\color{blue}{-z}} \]
    5. Simplified60.6%

      \[\leadsto e^{\color{blue}{-z}} \]
    6. Taylor expanded in z around 0

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

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

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
      3. sub-negN/A

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

        \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
      5. accelerator-lowering-fma.f642.1

        \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
    8. Simplified2.1%

      \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
    9. Step-by-step derivation
      1. flip-+N/A

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

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

        \[\leadsto \frac{\left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) \cdot \left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) - \color{blue}{1}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
      4. sub-negN/A

        \[\leadsto \frac{\color{blue}{\left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) \cdot \left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) + \left(\mathsf{neg}\left(1\right)\right)}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
      5. swap-sqrN/A

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

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

        \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(z \cdot z, \left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
      8. *-lowering-*.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{z \cdot z}, \left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
      9. *-lowering-*.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \color{blue}{\left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right)}, -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
      10. *-commutativeN/A

        \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \left(\color{blue}{z \cdot \frac{1}{2}} + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
      11. accelerator-lowering-fma.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2}, -1\right)} \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
      12. *-commutativeN/A

        \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \left(\color{blue}{z \cdot \frac{1}{2}} + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
      13. accelerator-lowering-fma.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \color{blue}{\mathsf{fma}\left(z, \frac{1}{2}, -1\right)}, -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
      14. sub-negN/A

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

        \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) + \color{blue}{-1}} \]
      16. accelerator-lowering-fma.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)}{\color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z + -1, -1\right)}} \]
    10. Applied egg-rr1.3%

      \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, 0.5, -1\right) \cdot \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}} \]
    11. Taylor expanded in z around 0

      \[\leadsto \frac{\color{blue}{-1}}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)} \]
    12. Step-by-step derivation
      1. Simplified51.3%

        \[\leadsto \frac{\color{blue}{-1}}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)} \]

      if -4.9999999999999999e146 < (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z) < -1e14

      1. Initial program 100.0%

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

        \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
      4. Step-by-step derivation
        1. mul-1-negN/A

          \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
        2. neg-lowering-neg.f6443.8

          \[\leadsto e^{\color{blue}{-z}} \]
      5. Simplified43.8%

        \[\leadsto e^{\color{blue}{-z}} \]
      6. Taylor expanded in z around 0

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

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

          \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
        3. sub-negN/A

          \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
        4. metadata-evalN/A

          \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
        5. accelerator-lowering-fma.f64N/A

          \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
        6. +-commutativeN/A

          \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
        7. *-commutativeN/A

          \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
        8. accelerator-lowering-fma.f642.6

          \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
      8. Simplified2.6%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
      9. Taylor expanded in z around inf

        \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
      10. Step-by-step derivation
        1. *-lowering-*.f64N/A

          \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
        2. cube-multN/A

          \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot \left(z \cdot z\right)\right)} \]
        3. unpow2N/A

          \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{{z}^{2}}\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot {z}^{2}\right)} \]
        5. unpow2N/A

          \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
        6. *-lowering-*.f6449.3

          \[\leadsto -0.16666666666666666 \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
      11. Simplified49.3%

        \[\leadsto \color{blue}{-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)} \]

      if -1e14 < (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z) < 5e17

      1. Initial program 100.0%

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

        \[\leadsto e^{\color{blue}{x}} \]
      4. Step-by-step derivation
        1. Simplified86.6%

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

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

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

            \[\leadsto \color{blue}{\mathsf{fma}\left(x, 1 + x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right), 1\right)} \]
          3. +-commutativeN/A

            \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right) + 1}, 1\right) \]
          4. accelerator-lowering-fma.f64N/A

            \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, \frac{1}{2} + \frac{1}{6} \cdot x, 1\right)}, 1\right) \]
          5. +-commutativeN/A

            \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\frac{1}{6} \cdot x + \frac{1}{2}}, 1\right), 1\right) \]
          6. *-commutativeN/A

            \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{6}} + \frac{1}{2}, 1\right), 1\right) \]
          7. accelerator-lowering-fma.f6480.4

            \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.16666666666666666, 0.5\right)}, 1\right), 1\right) \]
        4. Simplified80.4%

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

        if 5e17 < (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z)

        1. Initial program 100.0%

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

          \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
        4. Step-by-step derivation
          1. mul-1-negN/A

            \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
          2. neg-lowering-neg.f6435.8

            \[\leadsto e^{\color{blue}{-z}} \]
        5. Simplified35.8%

          \[\leadsto e^{\color{blue}{-z}} \]
        6. Taylor expanded in z around 0

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

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

            \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
          3. sub-negN/A

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

            \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
          5. accelerator-lowering-fma.f6423.9

            \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
        8. Simplified23.9%

          \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
        9. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \color{blue}{\left(\frac{1}{2} \cdot z + -1\right) \cdot z} + 1 \]
          2. flip-+N/A

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

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

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

            \[\leadsto \color{blue}{\mathsf{fma}\left(\left(\left(\frac{1}{2} \cdot z\right) \cdot \left(\frac{1}{2} \cdot z\right) - -1 \cdot -1\right) \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right)} \]
          6. *-lowering-*.f64N/A

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

            \[\leadsto \mathsf{fma}\left(\left(\left(\frac{1}{2} \cdot z\right) \cdot \left(\frac{1}{2} \cdot z\right) - \color{blue}{1}\right) \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right) \]
          8. sub-negN/A

            \[\leadsto \mathsf{fma}\left(\color{blue}{\left(\left(\frac{1}{2} \cdot z\right) \cdot \left(\frac{1}{2} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right) \]
          9. swap-sqrN/A

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

            \[\leadsto \mathsf{fma}\left(\left(\left(\frac{1}{2} \cdot \frac{1}{2}\right) \cdot \left(z \cdot z\right) + \color{blue}{-1}\right) \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right) \]
          11. accelerator-lowering-fma.f64N/A

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

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

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

            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \color{blue}{\frac{1}{\frac{1}{2} \cdot z - -1}}, 1\right) \]
          15. sub-negN/A

            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{1}{\color{blue}{\frac{1}{2} \cdot z + \left(\mathsf{neg}\left(-1\right)\right)}}, 1\right) \]
          16. *-commutativeN/A

            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{1}{\color{blue}{z \cdot \frac{1}{2}} + \left(\mathsf{neg}\left(-1\right)\right)}, 1\right) \]
          17. metadata-evalN/A

            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{1}{z \cdot \frac{1}{2} + \color{blue}{1}}, 1\right) \]
          18. accelerator-lowering-fma.f6432.0

            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \frac{1}{\color{blue}{\mathsf{fma}\left(z, 0.5, 1\right)}}, 1\right) \]
        10. Applied egg-rr32.0%

          \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \frac{1}{\mathsf{fma}\left(z, 0.5, 1\right)}, 1\right)} \]
        11. Taylor expanded in z around inf

          \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \color{blue}{\frac{\left(2 + \frac{8}{{z}^{2}}\right) - \left(4 \cdot \frac{1}{z} + 16 \cdot \frac{1}{{z}^{3}}\right)}{z}}, 1\right) \]
        12. Simplified55.1%

          \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \color{blue}{\frac{2 + \frac{-4 - \frac{\frac{16}{z} + -8}{z}}{z}}{z}}, 1\right) \]
      5. Recombined 4 regimes into one program.
      6. Final simplification57.1%

        \[\leadsto \begin{array}{l} \mathbf{if}\;\left(x + y \cdot \log y\right) - z \leq -5 \cdot 10^{+146}:\\ \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\ \mathbf{elif}\;\left(x + y \cdot \log y\right) - z \leq -1 \cdot 10^{+14}:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;\left(x + y \cdot \log y\right) - z \leq 5 \cdot 10^{+17}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(z \cdot \mathsf{fma}\left(0.25, z \cdot z, -1\right), \frac{2 + \frac{-4 - \frac{\frac{16}{z} + -8}{z}}{z}}{z}, 1\right)\\ \end{array} \]
      7. Add Preprocessing

      Alternative 3: 52.9% accurate, 0.5× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} t_0 := \left(x + y \cdot \log y\right) - z\\ \mathbf{if}\;t\_0 \leq -5 \cdot 10^{+146}:\\ \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\ \mathbf{elif}\;t\_0 \leq -1 \cdot 10^{+14}:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;t\_0 \leq 5 \cdot 10^{+17}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(z \cdot \mathsf{fma}\left(0.25, z \cdot z, -1\right), \frac{2 + \frac{-4}{z}}{z}, 1\right)\\ \end{array} \end{array} \]
      (FPCore (x y z)
       :precision binary64
       (let* ((t_0 (- (+ x (* y (log y))) z)))
         (if (<= t_0 -5e+146)
           (/ -1.0 (fma z (fma z 0.5 -1.0) -1.0))
           (if (<= t_0 -1e+14)
             (* -0.16666666666666666 (* z (* z z)))
             (if (<= t_0 5e+17)
               (fma x (fma x (fma x 0.16666666666666666 0.5) 1.0) 1.0)
               (fma (* z (fma 0.25 (* z z) -1.0)) (/ (+ 2.0 (/ -4.0 z)) z) 1.0))))))
      double code(double x, double y, double z) {
      	double t_0 = (x + (y * log(y))) - z;
      	double tmp;
      	if (t_0 <= -5e+146) {
      		tmp = -1.0 / fma(z, fma(z, 0.5, -1.0), -1.0);
      	} else if (t_0 <= -1e+14) {
      		tmp = -0.16666666666666666 * (z * (z * z));
      	} else if (t_0 <= 5e+17) {
      		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
      	} else {
      		tmp = fma((z * fma(0.25, (z * z), -1.0)), ((2.0 + (-4.0 / z)) / z), 1.0);
      	}
      	return tmp;
      }
      
      function code(x, y, z)
      	t_0 = Float64(Float64(x + Float64(y * log(y))) - z)
      	tmp = 0.0
      	if (t_0 <= -5e+146)
      		tmp = Float64(-1.0 / fma(z, fma(z, 0.5, -1.0), -1.0));
      	elseif (t_0 <= -1e+14)
      		tmp = Float64(-0.16666666666666666 * Float64(z * Float64(z * z)));
      	elseif (t_0 <= 5e+17)
      		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
      	else
      		tmp = fma(Float64(z * fma(0.25, Float64(z * z), -1.0)), Float64(Float64(2.0 + Float64(-4.0 / z)) / z), 1.0);
      	end
      	return tmp
      end
      
      code[x_, y_, z_] := Block[{t$95$0 = N[(N[(x + N[(y * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - z), $MachinePrecision]}, If[LessEqual[t$95$0, -5e+146], N[(-1.0 / N[(z * N[(z * 0.5 + -1.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$0, -1e+14], N[(-0.16666666666666666 * N[(z * N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$0, 5e+17], N[(x * N[(x * N[(x * 0.16666666666666666 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] + 1.0), $MachinePrecision], N[(N[(z * N[(0.25 * N[(z * z), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision] * N[(N[(2.0 + N[(-4.0 / z), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision] + 1.0), $MachinePrecision]]]]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      t_0 := \left(x + y \cdot \log y\right) - z\\
      \mathbf{if}\;t\_0 \leq -5 \cdot 10^{+146}:\\
      \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\
      
      \mathbf{elif}\;t\_0 \leq -1 \cdot 10^{+14}:\\
      \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\
      
      \mathbf{elif}\;t\_0 \leq 5 \cdot 10^{+17}:\\
      \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;\mathsf{fma}\left(z \cdot \mathsf{fma}\left(0.25, z \cdot z, -1\right), \frac{2 + \frac{-4}{z}}{z}, 1\right)\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 4 regimes
      2. if (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z) < -4.9999999999999999e146

        1. Initial program 100.0%

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

          \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
        4. Step-by-step derivation
          1. mul-1-negN/A

            \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
          2. neg-lowering-neg.f6460.6

            \[\leadsto e^{\color{blue}{-z}} \]
        5. Simplified60.6%

          \[\leadsto e^{\color{blue}{-z}} \]
        6. Taylor expanded in z around 0

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

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

            \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
          3. sub-negN/A

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

            \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
          5. accelerator-lowering-fma.f642.1

            \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
        8. Simplified2.1%

          \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
        9. Step-by-step derivation
          1. flip-+N/A

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

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

            \[\leadsto \frac{\left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) \cdot \left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) - \color{blue}{1}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
          4. sub-negN/A

            \[\leadsto \frac{\color{blue}{\left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) \cdot \left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) + \left(\mathsf{neg}\left(1\right)\right)}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
          5. swap-sqrN/A

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

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

            \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(z \cdot z, \left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
          8. *-lowering-*.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{z \cdot z}, \left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
          9. *-lowering-*.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \color{blue}{\left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right)}, -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
          10. *-commutativeN/A

            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \left(\color{blue}{z \cdot \frac{1}{2}} + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
          11. accelerator-lowering-fma.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2}, -1\right)} \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
          12. *-commutativeN/A

            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \left(\color{blue}{z \cdot \frac{1}{2}} + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
          13. accelerator-lowering-fma.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \color{blue}{\mathsf{fma}\left(z, \frac{1}{2}, -1\right)}, -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
          14. sub-negN/A

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

            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) + \color{blue}{-1}} \]
          16. accelerator-lowering-fma.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)}{\color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z + -1, -1\right)}} \]
        10. Applied egg-rr1.3%

          \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, 0.5, -1\right) \cdot \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}} \]
        11. Taylor expanded in z around 0

          \[\leadsto \frac{\color{blue}{-1}}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)} \]
        12. Step-by-step derivation
          1. Simplified51.3%

            \[\leadsto \frac{\color{blue}{-1}}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)} \]

          if -4.9999999999999999e146 < (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z) < -1e14

          1. Initial program 100.0%

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

            \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
          4. Step-by-step derivation
            1. mul-1-negN/A

              \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
            2. neg-lowering-neg.f6443.8

              \[\leadsto e^{\color{blue}{-z}} \]
          5. Simplified43.8%

            \[\leadsto e^{\color{blue}{-z}} \]
          6. Taylor expanded in z around 0

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

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

              \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
            3. sub-negN/A

              \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
            4. metadata-evalN/A

              \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
            5. accelerator-lowering-fma.f64N/A

              \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
            6. +-commutativeN/A

              \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
            7. *-commutativeN/A

              \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
            8. accelerator-lowering-fma.f642.6

              \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
          8. Simplified2.6%

            \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
          9. Taylor expanded in z around inf

            \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
          10. Step-by-step derivation
            1. *-lowering-*.f64N/A

              \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
            2. cube-multN/A

              \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot \left(z \cdot z\right)\right)} \]
            3. unpow2N/A

              \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{{z}^{2}}\right) \]
            4. *-lowering-*.f64N/A

              \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot {z}^{2}\right)} \]
            5. unpow2N/A

              \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
            6. *-lowering-*.f6449.3

              \[\leadsto -0.16666666666666666 \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
          11. Simplified49.3%

            \[\leadsto \color{blue}{-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)} \]

          if -1e14 < (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z) < 5e17

          1. Initial program 100.0%

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

            \[\leadsto e^{\color{blue}{x}} \]
          4. Step-by-step derivation
            1. Simplified86.6%

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

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

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

                \[\leadsto \color{blue}{\mathsf{fma}\left(x, 1 + x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right), 1\right)} \]
              3. +-commutativeN/A

                \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right) + 1}, 1\right) \]
              4. accelerator-lowering-fma.f64N/A

                \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, \frac{1}{2} + \frac{1}{6} \cdot x, 1\right)}, 1\right) \]
              5. +-commutativeN/A

                \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\frac{1}{6} \cdot x + \frac{1}{2}}, 1\right), 1\right) \]
              6. *-commutativeN/A

                \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{6}} + \frac{1}{2}, 1\right), 1\right) \]
              7. accelerator-lowering-fma.f6480.4

                \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.16666666666666666, 0.5\right)}, 1\right), 1\right) \]
            4. Simplified80.4%

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

            if 5e17 < (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z)

            1. Initial program 100.0%

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

              \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
            4. Step-by-step derivation
              1. mul-1-negN/A

                \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
              2. neg-lowering-neg.f6435.8

                \[\leadsto e^{\color{blue}{-z}} \]
            5. Simplified35.8%

              \[\leadsto e^{\color{blue}{-z}} \]
            6. Taylor expanded in z around 0

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

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

                \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
              3. sub-negN/A

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

                \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
              5. accelerator-lowering-fma.f6423.9

                \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
            8. Simplified23.9%

              \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
            9. Step-by-step derivation
              1. *-commutativeN/A

                \[\leadsto \color{blue}{\left(\frac{1}{2} \cdot z + -1\right) \cdot z} + 1 \]
              2. flip-+N/A

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

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

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

                \[\leadsto \color{blue}{\mathsf{fma}\left(\left(\left(\frac{1}{2} \cdot z\right) \cdot \left(\frac{1}{2} \cdot z\right) - -1 \cdot -1\right) \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right)} \]
              6. *-lowering-*.f64N/A

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

                \[\leadsto \mathsf{fma}\left(\left(\left(\frac{1}{2} \cdot z\right) \cdot \left(\frac{1}{2} \cdot z\right) - \color{blue}{1}\right) \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right) \]
              8. sub-negN/A

                \[\leadsto \mathsf{fma}\left(\color{blue}{\left(\left(\frac{1}{2} \cdot z\right) \cdot \left(\frac{1}{2} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right) \]
              9. swap-sqrN/A

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

                \[\leadsto \mathsf{fma}\left(\left(\left(\frac{1}{2} \cdot \frac{1}{2}\right) \cdot \left(z \cdot z\right) + \color{blue}{-1}\right) \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right) \]
              11. accelerator-lowering-fma.f64N/A

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

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

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

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \color{blue}{\frac{1}{\frac{1}{2} \cdot z - -1}}, 1\right) \]
              15. sub-negN/A

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{1}{\color{blue}{\frac{1}{2} \cdot z + \left(\mathsf{neg}\left(-1\right)\right)}}, 1\right) \]
              16. *-commutativeN/A

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{1}{\color{blue}{z \cdot \frac{1}{2}} + \left(\mathsf{neg}\left(-1\right)\right)}, 1\right) \]
              17. metadata-evalN/A

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{1}{z \cdot \frac{1}{2} + \color{blue}{1}}, 1\right) \]
              18. accelerator-lowering-fma.f6432.0

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \frac{1}{\color{blue}{\mathsf{fma}\left(z, 0.5, 1\right)}}, 1\right) \]
            10. Applied egg-rr32.0%

              \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \frac{1}{\mathsf{fma}\left(z, 0.5, 1\right)}, 1\right)} \]
            11. Taylor expanded in z around inf

              \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \color{blue}{\frac{2 - 4 \cdot \frac{1}{z}}{z}}, 1\right) \]
            12. Step-by-step derivation
              1. /-lowering-/.f64N/A

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \color{blue}{\frac{2 - 4 \cdot \frac{1}{z}}{z}}, 1\right) \]
              2. sub-negN/A

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{\color{blue}{2 + \left(\mathsf{neg}\left(4 \cdot \frac{1}{z}\right)\right)}}{z}, 1\right) \]
              3. +-lowering-+.f64N/A

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{\color{blue}{2 + \left(\mathsf{neg}\left(4 \cdot \frac{1}{z}\right)\right)}}{z}, 1\right) \]
              4. associate-*r/N/A

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{2 + \left(\mathsf{neg}\left(\color{blue}{\frac{4 \cdot 1}{z}}\right)\right)}{z}, 1\right) \]
              5. metadata-evalN/A

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{2 + \left(\mathsf{neg}\left(\frac{\color{blue}{4}}{z}\right)\right)}{z}, 1\right) \]
              6. distribute-neg-fracN/A

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{2 + \color{blue}{\frac{\mathsf{neg}\left(4\right)}{z}}}{z}, 1\right) \]
              7. /-lowering-/.f64N/A

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{2 + \color{blue}{\frac{\mathsf{neg}\left(4\right)}{z}}}{z}, 1\right) \]
              8. metadata-eval50.3

                \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \frac{2 + \frac{\color{blue}{-4}}{z}}{z}, 1\right) \]
            13. Simplified50.3%

              \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \color{blue}{\frac{2 + \frac{-4}{z}}{z}}, 1\right) \]
          5. Recombined 4 regimes into one program.
          6. Final simplification54.0%

            \[\leadsto \begin{array}{l} \mathbf{if}\;\left(x + y \cdot \log y\right) - z \leq -5 \cdot 10^{+146}:\\ \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\ \mathbf{elif}\;\left(x + y \cdot \log y\right) - z \leq -1 \cdot 10^{+14}:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;\left(x + y \cdot \log y\right) - z \leq 5 \cdot 10^{+17}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(z \cdot \mathsf{fma}\left(0.25, z \cdot z, -1\right), \frac{2 + \frac{-4}{z}}{z}, 1\right)\\ \end{array} \]
          7. Add Preprocessing

          Alternative 4: 79.0% accurate, 0.6× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} t_0 := x + y \cdot \log y\\ \mathbf{if}\;t\_0 \leq -1 \cdot 10^{+14}:\\ \;\;\;\;e^{x}\\ \mathbf{elif}\;t\_0 \leq 10^{+69}:\\ \;\;\;\;e^{-z}\\ \mathbf{else}:\\ \;\;\;\;{y}^{y}\\ \end{array} \end{array} \]
          (FPCore (x y z)
           :precision binary64
           (let* ((t_0 (+ x (* y (log y)))))
             (if (<= t_0 -1e+14) (exp x) (if (<= t_0 1e+69) (exp (- z)) (pow y y)))))
          double code(double x, double y, double z) {
          	double t_0 = x + (y * log(y));
          	double tmp;
          	if (t_0 <= -1e+14) {
          		tmp = exp(x);
          	} else if (t_0 <= 1e+69) {
          		tmp = exp(-z);
          	} else {
          		tmp = pow(y, y);
          	}
          	return tmp;
          }
          
          real(8) function code(x, y, z)
              real(8), intent (in) :: x
              real(8), intent (in) :: y
              real(8), intent (in) :: z
              real(8) :: t_0
              real(8) :: tmp
              t_0 = x + (y * log(y))
              if (t_0 <= (-1d+14)) then
                  tmp = exp(x)
              else if (t_0 <= 1d+69) then
                  tmp = exp(-z)
              else
                  tmp = y ** y
              end if
              code = tmp
          end function
          
          public static double code(double x, double y, double z) {
          	double t_0 = x + (y * Math.log(y));
          	double tmp;
          	if (t_0 <= -1e+14) {
          		tmp = Math.exp(x);
          	} else if (t_0 <= 1e+69) {
          		tmp = Math.exp(-z);
          	} else {
          		tmp = Math.pow(y, y);
          	}
          	return tmp;
          }
          
          def code(x, y, z):
          	t_0 = x + (y * math.log(y))
          	tmp = 0
          	if t_0 <= -1e+14:
          		tmp = math.exp(x)
          	elif t_0 <= 1e+69:
          		tmp = math.exp(-z)
          	else:
          		tmp = math.pow(y, y)
          	return tmp
          
          function code(x, y, z)
          	t_0 = Float64(x + Float64(y * log(y)))
          	tmp = 0.0
          	if (t_0 <= -1e+14)
          		tmp = exp(x);
          	elseif (t_0 <= 1e+69)
          		tmp = exp(Float64(-z));
          	else
          		tmp = y ^ y;
          	end
          	return tmp
          end
          
          function tmp_2 = code(x, y, z)
          	t_0 = x + (y * log(y));
          	tmp = 0.0;
          	if (t_0 <= -1e+14)
          		tmp = exp(x);
          	elseif (t_0 <= 1e+69)
          		tmp = exp(-z);
          	else
          		tmp = y ^ y;
          	end
          	tmp_2 = tmp;
          end
          
          code[x_, y_, z_] := Block[{t$95$0 = N[(x + N[(y * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$0, -1e+14], N[Exp[x], $MachinePrecision], If[LessEqual[t$95$0, 1e+69], N[Exp[(-z)], $MachinePrecision], N[Power[y, y], $MachinePrecision]]]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          t_0 := x + y \cdot \log y\\
          \mathbf{if}\;t\_0 \leq -1 \cdot 10^{+14}:\\
          \;\;\;\;e^{x}\\
          
          \mathbf{elif}\;t\_0 \leq 10^{+69}:\\
          \;\;\;\;e^{-z}\\
          
          \mathbf{else}:\\
          \;\;\;\;{y}^{y}\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if (+.f64 x (*.f64 y (log.f64 y))) < -1e14

            1. Initial program 100.0%

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

              \[\leadsto e^{\color{blue}{x}} \]
            4. Step-by-step derivation
              1. Simplified93.7%

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

              if -1e14 < (+.f64 x (*.f64 y (log.f64 y))) < 1.0000000000000001e69

              1. Initial program 100.0%

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

                \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
              4. Step-by-step derivation
                1. mul-1-negN/A

                  \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                2. neg-lowering-neg.f6478.6

                  \[\leadsto e^{\color{blue}{-z}} \]
              5. Simplified78.6%

                \[\leadsto e^{\color{blue}{-z}} \]

              if 1.0000000000000001e69 < (+.f64 x (*.f64 y (log.f64 y)))

              1. Initial program 100.0%

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

                \[\leadsto e^{\color{blue}{-1 \cdot \left(y \cdot \log \left(\frac{1}{y}\right)\right)}} \]
              4. Step-by-step derivation
                1. mul-1-negN/A

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

                  \[\leadsto e^{\color{blue}{y \cdot \left(\mathsf{neg}\left(\log \left(\frac{1}{y}\right)\right)\right)}} \]
                3. log-recN/A

                  \[\leadsto e^{y \cdot \left(\mathsf{neg}\left(\color{blue}{\left(\mathsf{neg}\left(\log y\right)\right)}\right)\right)} \]
                4. remove-double-negN/A

                  \[\leadsto e^{y \cdot \color{blue}{\log y}} \]
                5. *-lowering-*.f64N/A

                  \[\leadsto e^{\color{blue}{y \cdot \log y}} \]
                6. log-lowering-log.f6482.8

                  \[\leadsto e^{y \cdot \color{blue}{\log y}} \]
              5. Simplified82.8%

                \[\leadsto e^{\color{blue}{y \cdot \log y}} \]
              6. Step-by-step derivation
                1. *-commutativeN/A

                  \[\leadsto e^{\color{blue}{\log y \cdot y}} \]
                2. exp-to-powN/A

                  \[\leadsto \color{blue}{{y}^{y}} \]
                3. pow-lowering-pow.f6482.8

                  \[\leadsto \color{blue}{{y}^{y}} \]
              7. Applied egg-rr82.8%

                \[\leadsto \color{blue}{{y}^{y}} \]
            5. Recombined 3 regimes into one program.
            6. Add Preprocessing

            Alternative 5: 33.0% accurate, 0.9× speedup?

            \[\begin{array}{l} \\ \begin{array}{l} t_0 := \left(x + y \cdot \log y\right) - z\\ t_1 := \left(z \cdot z\right) \cdot 0.5\\ \mathbf{if}\;t\_0 \leq -1 \cdot 10^{+14}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_0 \leq 4 \cdot 10^{+125}:\\ \;\;\;\;x + 1\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
            (FPCore (x y z)
             :precision binary64
             (let* ((t_0 (- (+ x (* y (log y))) z)) (t_1 (* (* z z) 0.5)))
               (if (<= t_0 -1e+14) t_1 (if (<= t_0 4e+125) (+ x 1.0) t_1))))
            double code(double x, double y, double z) {
            	double t_0 = (x + (y * log(y))) - z;
            	double t_1 = (z * z) * 0.5;
            	double tmp;
            	if (t_0 <= -1e+14) {
            		tmp = t_1;
            	} else if (t_0 <= 4e+125) {
            		tmp = x + 1.0;
            	} else {
            		tmp = t_1;
            	}
            	return tmp;
            }
            
            real(8) function code(x, y, z)
                real(8), intent (in) :: x
                real(8), intent (in) :: y
                real(8), intent (in) :: z
                real(8) :: t_0
                real(8) :: t_1
                real(8) :: tmp
                t_0 = (x + (y * log(y))) - z
                t_1 = (z * z) * 0.5d0
                if (t_0 <= (-1d+14)) then
                    tmp = t_1
                else if (t_0 <= 4d+125) then
                    tmp = x + 1.0d0
                else
                    tmp = t_1
                end if
                code = tmp
            end function
            
            public static double code(double x, double y, double z) {
            	double t_0 = (x + (y * Math.log(y))) - z;
            	double t_1 = (z * z) * 0.5;
            	double tmp;
            	if (t_0 <= -1e+14) {
            		tmp = t_1;
            	} else if (t_0 <= 4e+125) {
            		tmp = x + 1.0;
            	} else {
            		tmp = t_1;
            	}
            	return tmp;
            }
            
            def code(x, y, z):
            	t_0 = (x + (y * math.log(y))) - z
            	t_1 = (z * z) * 0.5
            	tmp = 0
            	if t_0 <= -1e+14:
            		tmp = t_1
            	elif t_0 <= 4e+125:
            		tmp = x + 1.0
            	else:
            		tmp = t_1
            	return tmp
            
            function code(x, y, z)
            	t_0 = Float64(Float64(x + Float64(y * log(y))) - z)
            	t_1 = Float64(Float64(z * z) * 0.5)
            	tmp = 0.0
            	if (t_0 <= -1e+14)
            		tmp = t_1;
            	elseif (t_0 <= 4e+125)
            		tmp = Float64(x + 1.0);
            	else
            		tmp = t_1;
            	end
            	return tmp
            end
            
            function tmp_2 = code(x, y, z)
            	t_0 = (x + (y * log(y))) - z;
            	t_1 = (z * z) * 0.5;
            	tmp = 0.0;
            	if (t_0 <= -1e+14)
            		tmp = t_1;
            	elseif (t_0 <= 4e+125)
            		tmp = x + 1.0;
            	else
            		tmp = t_1;
            	end
            	tmp_2 = tmp;
            end
            
            code[x_, y_, z_] := Block[{t$95$0 = N[(N[(x + N[(y * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - z), $MachinePrecision]}, Block[{t$95$1 = N[(N[(z * z), $MachinePrecision] * 0.5), $MachinePrecision]}, If[LessEqual[t$95$0, -1e+14], t$95$1, If[LessEqual[t$95$0, 4e+125], N[(x + 1.0), $MachinePrecision], t$95$1]]]]
            
            \begin{array}{l}
            
            \\
            \begin{array}{l}
            t_0 := \left(x + y \cdot \log y\right) - z\\
            t_1 := \left(z \cdot z\right) \cdot 0.5\\
            \mathbf{if}\;t\_0 \leq -1 \cdot 10^{+14}:\\
            \;\;\;\;t\_1\\
            
            \mathbf{elif}\;t\_0 \leq 4 \cdot 10^{+125}:\\
            \;\;\;\;x + 1\\
            
            \mathbf{else}:\\
            \;\;\;\;t\_1\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 2 regimes
            2. if (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z) < -1e14 or 3.9999999999999997e125 < (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z)

              1. Initial program 100.0%

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

                \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
              4. Step-by-step derivation
                1. mul-1-negN/A

                  \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                2. neg-lowering-neg.f6446.2

                  \[\leadsto e^{\color{blue}{-z}} \]
              5. Simplified46.2%

                \[\leadsto e^{\color{blue}{-z}} \]
              6. Taylor expanded in z around 0

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

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

                  \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                3. sub-negN/A

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

                  \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                5. accelerator-lowering-fma.f6420.4

                  \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
              8. Simplified20.4%

                \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
              9. Taylor expanded in z around inf

                \[\leadsto \color{blue}{\frac{1}{2} \cdot {z}^{2}} \]
              10. Step-by-step derivation
                1. *-lowering-*.f64N/A

                  \[\leadsto \color{blue}{\frac{1}{2} \cdot {z}^{2}} \]
                2. unpow2N/A

                  \[\leadsto \frac{1}{2} \cdot \color{blue}{\left(z \cdot z\right)} \]
                3. *-lowering-*.f6426.4

                  \[\leadsto 0.5 \cdot \color{blue}{\left(z \cdot z\right)} \]
              11. Simplified26.4%

                \[\leadsto \color{blue}{0.5 \cdot \left(z \cdot z\right)} \]

              if -1e14 < (-.f64 (+.f64 x (*.f64 y (log.f64 y))) z) < 3.9999999999999997e125

              1. Initial program 100.0%

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

                \[\leadsto e^{\color{blue}{x}} \]
              4. Step-by-step derivation
                1. Simplified65.3%

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

                  \[\leadsto \color{blue}{1 + x} \]
                3. Step-by-step derivation
                  1. +-lowering-+.f6437.4

                    \[\leadsto \color{blue}{1 + x} \]
                4. Simplified37.4%

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

                \[\leadsto \begin{array}{l} \mathbf{if}\;\left(x + y \cdot \log y\right) - z \leq -1 \cdot 10^{+14}:\\ \;\;\;\;\left(z \cdot z\right) \cdot 0.5\\ \mathbf{elif}\;\left(x + y \cdot \log y\right) - z \leq 4 \cdot 10^{+125}:\\ \;\;\;\;x + 1\\ \mathbf{else}:\\ \;\;\;\;\left(z \cdot z\right) \cdot 0.5\\ \end{array} \]
              7. Add Preprocessing

              Alternative 6: 33.1% accurate, 1.7× speedup?

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

                1. Initial program 100.0%

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

                  \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                4. Step-by-step derivation
                  1. mul-1-negN/A

                    \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                  2. neg-lowering-neg.f6437.9

                    \[\leadsto e^{\color{blue}{-z}} \]
                5. Simplified37.9%

                  \[\leadsto e^{\color{blue}{-z}} \]
                6. Taylor expanded in z around 0

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                  3. sub-negN/A

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

                    \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                  5. accelerator-lowering-fma.f648.8

                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                8. Simplified8.8%

                  \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                9. Taylor expanded in z around inf

                  \[\leadsto \color{blue}{\frac{1}{2} \cdot {z}^{2}} \]
                10. Step-by-step derivation
                  1. *-lowering-*.f64N/A

                    \[\leadsto \color{blue}{\frac{1}{2} \cdot {z}^{2}} \]
                  2. unpow2N/A

                    \[\leadsto \frac{1}{2} \cdot \color{blue}{\left(z \cdot z\right)} \]
                  3. *-lowering-*.f6434.4

                    \[\leadsto 0.5 \cdot \color{blue}{\left(z \cdot z\right)} \]
                11. Simplified34.4%

                  \[\leadsto \color{blue}{0.5 \cdot \left(z \cdot z\right)} \]

                if -1e14 < (+.f64 x (*.f64 y (log.f64 y)))

                1. Initial program 100.0%

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

                  \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                4. Step-by-step derivation
                  1. mul-1-negN/A

                    \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                  2. neg-lowering-neg.f6448.2

                    \[\leadsto e^{\color{blue}{-z}} \]
                5. Simplified48.2%

                  \[\leadsto e^{\color{blue}{-z}} \]
                6. Taylor expanded in z around 0

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                  3. sub-negN/A

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

                    \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                  5. accelerator-lowering-fma.f6428.6

                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                8. Simplified28.6%

                  \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                9. Taylor expanded in z around inf

                  \[\leadsto \mathsf{fma}\left(z, \color{blue}{\frac{1}{2} \cdot z}, 1\right) \]
                10. Step-by-step derivation
                  1. *-lowering-*.f6428.3

                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{0.5 \cdot z}, 1\right) \]
                11. Simplified28.3%

                  \[\leadsto \mathsf{fma}\left(z, \color{blue}{0.5 \cdot z}, 1\right) \]
              3. Recombined 2 regimes into one program.
              4. Final simplification29.4%

                \[\leadsto \begin{array}{l} \mathbf{if}\;x + y \cdot \log y \leq -1 \cdot 10^{+14}:\\ \;\;\;\;\left(z \cdot z\right) \cdot 0.5\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(z, z \cdot 0.5, 1\right)\\ \end{array} \]
              5. Add Preprocessing

              Alternative 7: 67.9% accurate, 1.9× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.02 \cdot 10^{+121}:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;z \leq 1.95 \cdot 10^{+183}:\\ \;\;\;\;e^{x}\\ \mathbf{else}:\\ \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\ \end{array} \end{array} \]
              (FPCore (x y z)
               :precision binary64
               (if (<= z -1.02e+121)
                 (* -0.16666666666666666 (* z (* z z)))
                 (if (<= z 1.95e+183) (exp x) (/ -1.0 (fma z (fma z 0.5 -1.0) -1.0)))))
              double code(double x, double y, double z) {
              	double tmp;
              	if (z <= -1.02e+121) {
              		tmp = -0.16666666666666666 * (z * (z * z));
              	} else if (z <= 1.95e+183) {
              		tmp = exp(x);
              	} else {
              		tmp = -1.0 / fma(z, fma(z, 0.5, -1.0), -1.0);
              	}
              	return tmp;
              }
              
              function code(x, y, z)
              	tmp = 0.0
              	if (z <= -1.02e+121)
              		tmp = Float64(-0.16666666666666666 * Float64(z * Float64(z * z)));
              	elseif (z <= 1.95e+183)
              		tmp = exp(x);
              	else
              		tmp = Float64(-1.0 / fma(z, fma(z, 0.5, -1.0), -1.0));
              	end
              	return tmp
              end
              
              code[x_, y_, z_] := If[LessEqual[z, -1.02e+121], N[(-0.16666666666666666 * N[(z * N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.95e+183], N[Exp[x], $MachinePrecision], N[(-1.0 / N[(z * N[(z * 0.5 + -1.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              \mathbf{if}\;z \leq -1.02 \cdot 10^{+121}:\\
              \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\
              
              \mathbf{elif}\;z \leq 1.95 \cdot 10^{+183}:\\
              \;\;\;\;e^{x}\\
              
              \mathbf{else}:\\
              \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 3 regimes
              2. if z < -1.02000000000000005e121

                1. Initial program 100.0%

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

                  \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                4. Step-by-step derivation
                  1. mul-1-negN/A

                    \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                  2. neg-lowering-neg.f6497.3

                    \[\leadsto e^{\color{blue}{-z}} \]
                5. Simplified97.3%

                  \[\leadsto e^{\color{blue}{-z}} \]
                6. Taylor expanded in z around 0

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
                  3. sub-negN/A

                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
                  4. metadata-evalN/A

                    \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
                  5. accelerator-lowering-fma.f64N/A

                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
                  6. +-commutativeN/A

                    \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
                  7. *-commutativeN/A

                    \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
                  8. accelerator-lowering-fma.f6497.3

                    \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
                8. Simplified97.3%

                  \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
                9. Taylor expanded in z around inf

                  \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                10. Step-by-step derivation
                  1. *-lowering-*.f64N/A

                    \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                  2. cube-multN/A

                    \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot \left(z \cdot z\right)\right)} \]
                  3. unpow2N/A

                    \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{{z}^{2}}\right) \]
                  4. *-lowering-*.f64N/A

                    \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot {z}^{2}\right)} \]
                  5. unpow2N/A

                    \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                  6. *-lowering-*.f6497.3

                    \[\leadsto -0.16666666666666666 \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                11. Simplified97.3%

                  \[\leadsto \color{blue}{-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)} \]

                if -1.02000000000000005e121 < z < 1.9499999999999999e183

                1. Initial program 100.0%

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

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

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

                  if 1.9499999999999999e183 < z

                  1. Initial program 100.0%

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

                    \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                  4. Step-by-step derivation
                    1. mul-1-negN/A

                      \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                    2. neg-lowering-neg.f6487.7

                      \[\leadsto e^{\color{blue}{-z}} \]
                  5. Simplified87.7%

                    \[\leadsto e^{\color{blue}{-z}} \]
                  6. Taylor expanded in z around 0

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

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

                      \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                    3. sub-negN/A

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

                      \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                    5. accelerator-lowering-fma.f6413.9

                      \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                  8. Simplified13.9%

                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                  9. Step-by-step derivation
                    1. flip-+N/A

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

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

                      \[\leadsto \frac{\left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) \cdot \left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) - \color{blue}{1}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                    4. sub-negN/A

                      \[\leadsto \frac{\color{blue}{\left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) \cdot \left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) + \left(\mathsf{neg}\left(1\right)\right)}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                    5. swap-sqrN/A

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

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

                      \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(z \cdot z, \left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                    8. *-lowering-*.f64N/A

                      \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{z \cdot z}, \left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                    9. *-lowering-*.f64N/A

                      \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \color{blue}{\left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right)}, -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                    10. *-commutativeN/A

                      \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \left(\color{blue}{z \cdot \frac{1}{2}} + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                    11. accelerator-lowering-fma.f64N/A

                      \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2}, -1\right)} \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                    12. *-commutativeN/A

                      \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \left(\color{blue}{z \cdot \frac{1}{2}} + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                    13. accelerator-lowering-fma.f64N/A

                      \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \color{blue}{\mathsf{fma}\left(z, \frac{1}{2}, -1\right)}, -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                    14. sub-negN/A

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

                      \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) + \color{blue}{-1}} \]
                    16. accelerator-lowering-fma.f64N/A

                      \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)}{\color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z + -1, -1\right)}} \]
                  10. Applied egg-rr0.0%

                    \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, 0.5, -1\right) \cdot \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}} \]
                  11. Taylor expanded in z around 0

                    \[\leadsto \frac{\color{blue}{-1}}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)} \]
                  12. Step-by-step derivation
                    1. Simplified87.7%

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

                  Alternative 8: 74.0% accurate, 2.0× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 82000000:\\ \;\;\;\;e^{x}\\ \mathbf{else}:\\ \;\;\;\;{y}^{y}\\ \end{array} \end{array} \]
                  (FPCore (x y z) :precision binary64 (if (<= y 82000000.0) (exp x) (pow y y)))
                  double code(double x, double y, double z) {
                  	double tmp;
                  	if (y <= 82000000.0) {
                  		tmp = exp(x);
                  	} else {
                  		tmp = pow(y, y);
                  	}
                  	return tmp;
                  }
                  
                  real(8) function code(x, y, z)
                      real(8), intent (in) :: x
                      real(8), intent (in) :: y
                      real(8), intent (in) :: z
                      real(8) :: tmp
                      if (y <= 82000000.0d0) then
                          tmp = exp(x)
                      else
                          tmp = y ** y
                      end if
                      code = tmp
                  end function
                  
                  public static double code(double x, double y, double z) {
                  	double tmp;
                  	if (y <= 82000000.0) {
                  		tmp = Math.exp(x);
                  	} else {
                  		tmp = Math.pow(y, y);
                  	}
                  	return tmp;
                  }
                  
                  def code(x, y, z):
                  	tmp = 0
                  	if y <= 82000000.0:
                  		tmp = math.exp(x)
                  	else:
                  		tmp = math.pow(y, y)
                  	return tmp
                  
                  function code(x, y, z)
                  	tmp = 0.0
                  	if (y <= 82000000.0)
                  		tmp = exp(x);
                  	else
                  		tmp = y ^ y;
                  	end
                  	return tmp
                  end
                  
                  function tmp_2 = code(x, y, z)
                  	tmp = 0.0;
                  	if (y <= 82000000.0)
                  		tmp = exp(x);
                  	else
                  		tmp = y ^ y;
                  	end
                  	tmp_2 = tmp;
                  end
                  
                  code[x_, y_, z_] := If[LessEqual[y, 82000000.0], N[Exp[x], $MachinePrecision], N[Power[y, y], $MachinePrecision]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  \mathbf{if}\;y \leq 82000000:\\
                  \;\;\;\;e^{x}\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;{y}^{y}\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if y < 8.2e7

                    1. Initial program 100.0%

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

                      \[\leadsto e^{\color{blue}{x}} \]
                    4. Step-by-step derivation
                      1. Simplified72.3%

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

                      if 8.2e7 < y

                      1. Initial program 100.0%

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

                        \[\leadsto e^{\color{blue}{-1 \cdot \left(y \cdot \log \left(\frac{1}{y}\right)\right)}} \]
                      4. Step-by-step derivation
                        1. mul-1-negN/A

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

                          \[\leadsto e^{\color{blue}{y \cdot \left(\mathsf{neg}\left(\log \left(\frac{1}{y}\right)\right)\right)}} \]
                        3. log-recN/A

                          \[\leadsto e^{y \cdot \left(\mathsf{neg}\left(\color{blue}{\left(\mathsf{neg}\left(\log y\right)\right)}\right)\right)} \]
                        4. remove-double-negN/A

                          \[\leadsto e^{y \cdot \color{blue}{\log y}} \]
                        5. *-lowering-*.f64N/A

                          \[\leadsto e^{\color{blue}{y \cdot \log y}} \]
                        6. log-lowering-log.f6481.4

                          \[\leadsto e^{y \cdot \color{blue}{\log y}} \]
                      5. Simplified81.4%

                        \[\leadsto e^{\color{blue}{y \cdot \log y}} \]
                      6. Step-by-step derivation
                        1. *-commutativeN/A

                          \[\leadsto e^{\color{blue}{\log y \cdot y}} \]
                        2. exp-to-powN/A

                          \[\leadsto \color{blue}{{y}^{y}} \]
                        3. pow-lowering-pow.f6481.4

                          \[\leadsto \color{blue}{{y}^{y}} \]
                      7. Applied egg-rr81.4%

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

                    Alternative 9: 51.7% accurate, 4.0× speedup?

                    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.5 \cdot 10^{+73}:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;z \leq 8.2 \cdot 10^{+45}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\ \mathbf{elif}\;z \leq 2 \cdot 10^{+183}:\\ \;\;\;\;\mathsf{fma}\left(z \cdot \mathsf{fma}\left(0.25, z \cdot z, -1\right), \mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.25, -0.5\right), 1\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\ \end{array} \end{array} \]
                    (FPCore (x y z)
                     :precision binary64
                     (if (<= z -1.5e+73)
                       (* -0.16666666666666666 (* z (* z z)))
                       (if (<= z 8.2e+45)
                         (fma x (fma x (fma x 0.16666666666666666 0.5) 1.0) 1.0)
                         (if (<= z 2e+183)
                           (fma (* z (fma 0.25 (* z z) -1.0)) (fma z (fma z 0.25 -0.5) 1.0) 1.0)
                           (/ -1.0 (fma z (fma z 0.5 -1.0) -1.0))))))
                    double code(double x, double y, double z) {
                    	double tmp;
                    	if (z <= -1.5e+73) {
                    		tmp = -0.16666666666666666 * (z * (z * z));
                    	} else if (z <= 8.2e+45) {
                    		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
                    	} else if (z <= 2e+183) {
                    		tmp = fma((z * fma(0.25, (z * z), -1.0)), fma(z, fma(z, 0.25, -0.5), 1.0), 1.0);
                    	} else {
                    		tmp = -1.0 / fma(z, fma(z, 0.5, -1.0), -1.0);
                    	}
                    	return tmp;
                    }
                    
                    function code(x, y, z)
                    	tmp = 0.0
                    	if (z <= -1.5e+73)
                    		tmp = Float64(-0.16666666666666666 * Float64(z * Float64(z * z)));
                    	elseif (z <= 8.2e+45)
                    		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
                    	elseif (z <= 2e+183)
                    		tmp = fma(Float64(z * fma(0.25, Float64(z * z), -1.0)), fma(z, fma(z, 0.25, -0.5), 1.0), 1.0);
                    	else
                    		tmp = Float64(-1.0 / fma(z, fma(z, 0.5, -1.0), -1.0));
                    	end
                    	return tmp
                    end
                    
                    code[x_, y_, z_] := If[LessEqual[z, -1.5e+73], N[(-0.16666666666666666 * N[(z * N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8.2e+45], N[(x * N[(x * N[(x * 0.16666666666666666 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] + 1.0), $MachinePrecision], If[LessEqual[z, 2e+183], N[(N[(z * N[(0.25 * N[(z * z), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision] * N[(z * N[(z * 0.25 + -0.5), $MachinePrecision] + 1.0), $MachinePrecision] + 1.0), $MachinePrecision], N[(-1.0 / N[(z * N[(z * 0.5 + -1.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]]]]
                    
                    \begin{array}{l}
                    
                    \\
                    \begin{array}{l}
                    \mathbf{if}\;z \leq -1.5 \cdot 10^{+73}:\\
                    \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\
                    
                    \mathbf{elif}\;z \leq 8.2 \cdot 10^{+45}:\\
                    \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\
                    
                    \mathbf{elif}\;z \leq 2 \cdot 10^{+183}:\\
                    \;\;\;\;\mathsf{fma}\left(z \cdot \mathsf{fma}\left(0.25, z \cdot z, -1\right), \mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.25, -0.5\right), 1\right), 1\right)\\
                    
                    \mathbf{else}:\\
                    \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\
                    
                    
                    \end{array}
                    \end{array}
                    
                    Derivation
                    1. Split input into 4 regimes
                    2. if z < -1.50000000000000005e73

                      1. Initial program 100.0%

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

                        \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                      4. Step-by-step derivation
                        1. mul-1-negN/A

                          \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                        2. neg-lowering-neg.f6489.1

                          \[\leadsto e^{\color{blue}{-z}} \]
                      5. Simplified89.1%

                        \[\leadsto e^{\color{blue}{-z}} \]
                      6. Taylor expanded in z around 0

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

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

                          \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
                        3. sub-negN/A

                          \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
                        4. metadata-evalN/A

                          \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
                        5. accelerator-lowering-fma.f64N/A

                          \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
                        6. +-commutativeN/A

                          \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
                        7. *-commutativeN/A

                          \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
                        8. accelerator-lowering-fma.f6480.9

                          \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
                      8. Simplified80.9%

                        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
                      9. Taylor expanded in z around inf

                        \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                      10. Step-by-step derivation
                        1. *-lowering-*.f64N/A

                          \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                        2. cube-multN/A

                          \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot \left(z \cdot z\right)\right)} \]
                        3. unpow2N/A

                          \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{{z}^{2}}\right) \]
                        4. *-lowering-*.f64N/A

                          \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot {z}^{2}\right)} \]
                        5. unpow2N/A

                          \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                        6. *-lowering-*.f6480.9

                          \[\leadsto -0.16666666666666666 \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                      11. Simplified80.9%

                        \[\leadsto \color{blue}{-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)} \]

                      if -1.50000000000000005e73 < z < 8.20000000000000025e45

                      1. Initial program 100.0%

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

                        \[\leadsto e^{\color{blue}{x}} \]
                      4. Step-by-step derivation
                        1. Simplified61.5%

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

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

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

                            \[\leadsto \color{blue}{\mathsf{fma}\left(x, 1 + x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right), 1\right)} \]
                          3. +-commutativeN/A

                            \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right) + 1}, 1\right) \]
                          4. accelerator-lowering-fma.f64N/A

                            \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, \frac{1}{2} + \frac{1}{6} \cdot x, 1\right)}, 1\right) \]
                          5. +-commutativeN/A

                            \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\frac{1}{6} \cdot x + \frac{1}{2}}, 1\right), 1\right) \]
                          6. *-commutativeN/A

                            \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{6}} + \frac{1}{2}, 1\right), 1\right) \]
                          7. accelerator-lowering-fma.f6435.4

                            \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.16666666666666666, 0.5\right)}, 1\right), 1\right) \]
                        4. Simplified35.4%

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

                        if 8.20000000000000025e45 < z < 1.99999999999999989e183

                        1. Initial program 100.0%

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

                          \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                        4. Step-by-step derivation
                          1. mul-1-negN/A

                            \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                          2. neg-lowering-neg.f6444.2

                            \[\leadsto e^{\color{blue}{-z}} \]
                        5. Simplified44.2%

                          \[\leadsto e^{\color{blue}{-z}} \]
                        6. Taylor expanded in z around 0

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

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

                            \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                          3. sub-negN/A

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

                            \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                          5. accelerator-lowering-fma.f6420.0

                            \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                        8. Simplified20.0%

                          \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                        9. Step-by-step derivation
                          1. *-commutativeN/A

                            \[\leadsto \color{blue}{\left(\frac{1}{2} \cdot z + -1\right) \cdot z} + 1 \]
                          2. flip-+N/A

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

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

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

                            \[\leadsto \color{blue}{\mathsf{fma}\left(\left(\left(\frac{1}{2} \cdot z\right) \cdot \left(\frac{1}{2} \cdot z\right) - -1 \cdot -1\right) \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right)} \]
                          6. *-lowering-*.f64N/A

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

                            \[\leadsto \mathsf{fma}\left(\left(\left(\frac{1}{2} \cdot z\right) \cdot \left(\frac{1}{2} \cdot z\right) - \color{blue}{1}\right) \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right) \]
                          8. sub-negN/A

                            \[\leadsto \mathsf{fma}\left(\color{blue}{\left(\left(\frac{1}{2} \cdot z\right) \cdot \left(\frac{1}{2} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right) \]
                          9. swap-sqrN/A

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

                            \[\leadsto \mathsf{fma}\left(\left(\left(\frac{1}{2} \cdot \frac{1}{2}\right) \cdot \left(z \cdot z\right) + \color{blue}{-1}\right) \cdot z, \frac{1}{\frac{1}{2} \cdot z - -1}, 1\right) \]
                          11. accelerator-lowering-fma.f64N/A

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

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

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

                            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \color{blue}{\frac{1}{\frac{1}{2} \cdot z - -1}}, 1\right) \]
                          15. sub-negN/A

                            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{1}{\color{blue}{\frac{1}{2} \cdot z + \left(\mathsf{neg}\left(-1\right)\right)}}, 1\right) \]
                          16. *-commutativeN/A

                            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{1}{\color{blue}{z \cdot \frac{1}{2}} + \left(\mathsf{neg}\left(-1\right)\right)}, 1\right) \]
                          17. metadata-evalN/A

                            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \frac{1}{z \cdot \frac{1}{2} + \color{blue}{1}}, 1\right) \]
                          18. accelerator-lowering-fma.f6428.9

                            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \frac{1}{\color{blue}{\mathsf{fma}\left(z, 0.5, 1\right)}}, 1\right) \]
                        10. Applied egg-rr28.9%

                          \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \frac{1}{\mathsf{fma}\left(z, 0.5, 1\right)}, 1\right)} \]
                        11. Taylor expanded in z around 0

                          \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \color{blue}{1 + z \cdot \left(\frac{1}{4} \cdot z - \frac{1}{2}\right)}, 1\right) \]
                        12. Step-by-step derivation
                          1. +-commutativeN/A

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

                            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{4} \cdot z - \frac{1}{2}, 1\right)}, 1\right) \]
                          3. sub-negN/A

                            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \mathsf{fma}\left(z, \color{blue}{\frac{1}{4} \cdot z + \left(\mathsf{neg}\left(\frac{1}{2}\right)\right)}, 1\right), 1\right) \]
                          4. *-commutativeN/A

                            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{1}{4}} + \left(\mathsf{neg}\left(\frac{1}{2}\right)\right), 1\right), 1\right) \]
                          5. metadata-evalN/A

                            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(\frac{1}{4}, z \cdot z, -1\right) \cdot z, \mathsf{fma}\left(z, z \cdot \frac{1}{4} + \color{blue}{\frac{-1}{2}}, 1\right), 1\right) \]
                          6. accelerator-lowering-fma.f6448.0

                            \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.25, -0.5\right)}, 1\right), 1\right) \]
                        13. Simplified48.0%

                          \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(0.25, z \cdot z, -1\right) \cdot z, \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.25, -0.5\right), 1\right)}, 1\right) \]

                        if 1.99999999999999989e183 < z

                        1. Initial program 100.0%

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

                          \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                        4. Step-by-step derivation
                          1. mul-1-negN/A

                            \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                          2. neg-lowering-neg.f6487.7

                            \[\leadsto e^{\color{blue}{-z}} \]
                        5. Simplified87.7%

                          \[\leadsto e^{\color{blue}{-z}} \]
                        6. Taylor expanded in z around 0

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

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

                            \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                          3. sub-negN/A

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

                            \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                          5. accelerator-lowering-fma.f6413.9

                            \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                        8. Simplified13.9%

                          \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                        9. Step-by-step derivation
                          1. flip-+N/A

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

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

                            \[\leadsto \frac{\left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) \cdot \left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) - \color{blue}{1}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                          4. sub-negN/A

                            \[\leadsto \frac{\color{blue}{\left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) \cdot \left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) + \left(\mathsf{neg}\left(1\right)\right)}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                          5. swap-sqrN/A

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

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

                            \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(z \cdot z, \left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                          8. *-lowering-*.f64N/A

                            \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{z \cdot z}, \left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                          9. *-lowering-*.f64N/A

                            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \color{blue}{\left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right)}, -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                          10. *-commutativeN/A

                            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \left(\color{blue}{z \cdot \frac{1}{2}} + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                          11. accelerator-lowering-fma.f64N/A

                            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2}, -1\right)} \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                          12. *-commutativeN/A

                            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \left(\color{blue}{z \cdot \frac{1}{2}} + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                          13. accelerator-lowering-fma.f64N/A

                            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \color{blue}{\mathsf{fma}\left(z, \frac{1}{2}, -1\right)}, -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                          14. sub-negN/A

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

                            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) + \color{blue}{-1}} \]
                          16. accelerator-lowering-fma.f64N/A

                            \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)}{\color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z + -1, -1\right)}} \]
                        10. Applied egg-rr0.0%

                          \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, 0.5, -1\right) \cdot \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}} \]
                        11. Taylor expanded in z around 0

                          \[\leadsto \frac{\color{blue}{-1}}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)} \]
                        12. Step-by-step derivation
                          1. Simplified87.7%

                            \[\leadsto \frac{\color{blue}{-1}}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)} \]
                        13. Recombined 4 regimes into one program.
                        14. Final simplification49.8%

                          \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.5 \cdot 10^{+73}:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;z \leq 8.2 \cdot 10^{+45}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\ \mathbf{elif}\;z \leq 2 \cdot 10^{+183}:\\ \;\;\;\;\mathsf{fma}\left(z \cdot \mathsf{fma}\left(0.25, z \cdot z, -1\right), \mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.25, -0.5\right), 1\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\ \end{array} \]
                        15. Add Preprocessing

                        Alternative 10: 49.7% accurate, 5.9× speedup?

                        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.5 \cdot 10^{+73}:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;z \leq 1.15 \cdot 10^{+183}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\ \end{array} \end{array} \]
                        (FPCore (x y z)
                         :precision binary64
                         (if (<= z -1.5e+73)
                           (* -0.16666666666666666 (* z (* z z)))
                           (if (<= z 1.15e+183)
                             (fma x (fma x (fma x 0.16666666666666666 0.5) 1.0) 1.0)
                             (/ -1.0 (fma z (fma z 0.5 -1.0) -1.0)))))
                        double code(double x, double y, double z) {
                        	double tmp;
                        	if (z <= -1.5e+73) {
                        		tmp = -0.16666666666666666 * (z * (z * z));
                        	} else if (z <= 1.15e+183) {
                        		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
                        	} else {
                        		tmp = -1.0 / fma(z, fma(z, 0.5, -1.0), -1.0);
                        	}
                        	return tmp;
                        }
                        
                        function code(x, y, z)
                        	tmp = 0.0
                        	if (z <= -1.5e+73)
                        		tmp = Float64(-0.16666666666666666 * Float64(z * Float64(z * z)));
                        	elseif (z <= 1.15e+183)
                        		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
                        	else
                        		tmp = Float64(-1.0 / fma(z, fma(z, 0.5, -1.0), -1.0));
                        	end
                        	return tmp
                        end
                        
                        code[x_, y_, z_] := If[LessEqual[z, -1.5e+73], N[(-0.16666666666666666 * N[(z * N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.15e+183], N[(x * N[(x * N[(x * 0.16666666666666666 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] + 1.0), $MachinePrecision], N[(-1.0 / N[(z * N[(z * 0.5 + -1.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]]]
                        
                        \begin{array}{l}
                        
                        \\
                        \begin{array}{l}
                        \mathbf{if}\;z \leq -1.5 \cdot 10^{+73}:\\
                        \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\
                        
                        \mathbf{elif}\;z \leq 1.15 \cdot 10^{+183}:\\
                        \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\
                        
                        \mathbf{else}:\\
                        \;\;\;\;\frac{-1}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}\\
                        
                        
                        \end{array}
                        \end{array}
                        
                        Derivation
                        1. Split input into 3 regimes
                        2. if z < -1.50000000000000005e73

                          1. Initial program 100.0%

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

                            \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                          4. Step-by-step derivation
                            1. mul-1-negN/A

                              \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                            2. neg-lowering-neg.f6489.1

                              \[\leadsto e^{\color{blue}{-z}} \]
                          5. Simplified89.1%

                            \[\leadsto e^{\color{blue}{-z}} \]
                          6. Taylor expanded in z around 0

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

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

                              \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
                            3. sub-negN/A

                              \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
                            4. metadata-evalN/A

                              \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
                            5. accelerator-lowering-fma.f64N/A

                              \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
                            6. +-commutativeN/A

                              \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
                            7. *-commutativeN/A

                              \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
                            8. accelerator-lowering-fma.f6480.9

                              \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
                          8. Simplified80.9%

                            \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
                          9. Taylor expanded in z around inf

                            \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                          10. Step-by-step derivation
                            1. *-lowering-*.f64N/A

                              \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                            2. cube-multN/A

                              \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot \left(z \cdot z\right)\right)} \]
                            3. unpow2N/A

                              \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{{z}^{2}}\right) \]
                            4. *-lowering-*.f64N/A

                              \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot {z}^{2}\right)} \]
                            5. unpow2N/A

                              \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                            6. *-lowering-*.f6480.9

                              \[\leadsto -0.16666666666666666 \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                          11. Simplified80.9%

                            \[\leadsto \color{blue}{-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)} \]

                          if -1.50000000000000005e73 < z < 1.1499999999999999e183

                          1. Initial program 100.0%

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

                            \[\leadsto e^{\color{blue}{x}} \]
                          4. Step-by-step derivation
                            1. Simplified59.3%

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

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

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

                                \[\leadsto \color{blue}{\mathsf{fma}\left(x, 1 + x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right), 1\right)} \]
                              3. +-commutativeN/A

                                \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right) + 1}, 1\right) \]
                              4. accelerator-lowering-fma.f64N/A

                                \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, \frac{1}{2} + \frac{1}{6} \cdot x, 1\right)}, 1\right) \]
                              5. +-commutativeN/A

                                \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\frac{1}{6} \cdot x + \frac{1}{2}}, 1\right), 1\right) \]
                              6. *-commutativeN/A

                                \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{6}} + \frac{1}{2}, 1\right), 1\right) \]
                              7. accelerator-lowering-fma.f6434.3

                                \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.16666666666666666, 0.5\right)}, 1\right), 1\right) \]
                            4. Simplified34.3%

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

                            if 1.1499999999999999e183 < z

                            1. Initial program 100.0%

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

                              \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                            4. Step-by-step derivation
                              1. mul-1-negN/A

                                \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                              2. neg-lowering-neg.f6487.7

                                \[\leadsto e^{\color{blue}{-z}} \]
                            5. Simplified87.7%

                              \[\leadsto e^{\color{blue}{-z}} \]
                            6. Taylor expanded in z around 0

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

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

                                \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                              3. sub-negN/A

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

                                \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                              5. accelerator-lowering-fma.f6413.9

                                \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                            8. Simplified13.9%

                              \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                            9. Step-by-step derivation
                              1. flip-+N/A

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

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

                                \[\leadsto \frac{\left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) \cdot \left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) - \color{blue}{1}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                              4. sub-negN/A

                                \[\leadsto \frac{\color{blue}{\left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) \cdot \left(z \cdot \left(\frac{1}{2} \cdot z + -1\right)\right) + \left(\mathsf{neg}\left(1\right)\right)}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                              5. swap-sqrN/A

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

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

                                \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(z \cdot z, \left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                              8. *-lowering-*.f64N/A

                                \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{z \cdot z}, \left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                              9. *-lowering-*.f64N/A

                                \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \color{blue}{\left(\frac{1}{2} \cdot z + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right)}, -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                              10. *-commutativeN/A

                                \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \left(\color{blue}{z \cdot \frac{1}{2}} + -1\right) \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                              11. accelerator-lowering-fma.f64N/A

                                \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2}, -1\right)} \cdot \left(\frac{1}{2} \cdot z + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                              12. *-commutativeN/A

                                \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \left(\color{blue}{z \cdot \frac{1}{2}} + -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                              13. accelerator-lowering-fma.f64N/A

                                \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \color{blue}{\mathsf{fma}\left(z, \frac{1}{2}, -1\right)}, -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) - 1} \]
                              14. sub-negN/A

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

                                \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)}{z \cdot \left(\frac{1}{2} \cdot z + -1\right) + \color{blue}{-1}} \]
                              16. accelerator-lowering-fma.f64N/A

                                \[\leadsto \frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right) \cdot \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)}{\color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z + -1, -1\right)}} \]
                            10. Applied egg-rr0.0%

                              \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(z \cdot z, \mathsf{fma}\left(z, 0.5, -1\right) \cdot \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.5, -1\right), -1\right)}} \]
                            11. Taylor expanded in z around 0

                              \[\leadsto \frac{\color{blue}{-1}}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \frac{1}{2}, -1\right), -1\right)} \]
                            12. Step-by-step derivation
                              1. Simplified87.7%

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

                            Alternative 11: 48.2% accurate, 6.8× speedup?

                            \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq -35000000000:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;x \leq 4.6 \cdot 10^{+87}:\\ \;\;\;\;\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\ \end{array} \end{array} \]
                            (FPCore (x y z)
                             :precision binary64
                             (if (<= x -35000000000.0)
                               (* -0.16666666666666666 (* z (* z z)))
                               (if (<= x 4.6e+87)
                                 (fma z (fma z (fma z -0.16666666666666666 0.5) -1.0) 1.0)
                                 (fma x (fma x (fma x 0.16666666666666666 0.5) 1.0) 1.0))))
                            double code(double x, double y, double z) {
                            	double tmp;
                            	if (x <= -35000000000.0) {
                            		tmp = -0.16666666666666666 * (z * (z * z));
                            	} else if (x <= 4.6e+87) {
                            		tmp = fma(z, fma(z, fma(z, -0.16666666666666666, 0.5), -1.0), 1.0);
                            	} else {
                            		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
                            	}
                            	return tmp;
                            }
                            
                            function code(x, y, z)
                            	tmp = 0.0
                            	if (x <= -35000000000.0)
                            		tmp = Float64(-0.16666666666666666 * Float64(z * Float64(z * z)));
                            	elseif (x <= 4.6e+87)
                            		tmp = fma(z, fma(z, fma(z, -0.16666666666666666, 0.5), -1.0), 1.0);
                            	else
                            		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
                            	end
                            	return tmp
                            end
                            
                            code[x_, y_, z_] := If[LessEqual[x, -35000000000.0], N[(-0.16666666666666666 * N[(z * N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 4.6e+87], N[(z * N[(z * N[(z * -0.16666666666666666 + 0.5), $MachinePrecision] + -1.0), $MachinePrecision] + 1.0), $MachinePrecision], N[(x * N[(x * N[(x * 0.16666666666666666 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] + 1.0), $MachinePrecision]]]
                            
                            \begin{array}{l}
                            
                            \\
                            \begin{array}{l}
                            \mathbf{if}\;x \leq -35000000000:\\
                            \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\
                            
                            \mathbf{elif}\;x \leq 4.6 \cdot 10^{+87}:\\
                            \;\;\;\;\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)\\
                            
                            \mathbf{else}:\\
                            \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\
                            
                            
                            \end{array}
                            \end{array}
                            
                            Derivation
                            1. Split input into 3 regimes
                            2. if x < -3.5e10

                              1. Initial program 100.0%

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

                                \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                              4. Step-by-step derivation
                                1. mul-1-negN/A

                                  \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                2. neg-lowering-neg.f6433.6

                                  \[\leadsto e^{\color{blue}{-z}} \]
                              5. Simplified33.6%

                                \[\leadsto e^{\color{blue}{-z}} \]
                              6. Taylor expanded in z around 0

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

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

                                  \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
                                3. sub-negN/A

                                  \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
                                4. metadata-evalN/A

                                  \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
                                5. accelerator-lowering-fma.f64N/A

                                  \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
                                6. +-commutativeN/A

                                  \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
                                7. *-commutativeN/A

                                  \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
                                8. accelerator-lowering-fma.f6410.3

                                  \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
                              8. Simplified10.3%

                                \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
                              9. Taylor expanded in z around inf

                                \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                              10. Step-by-step derivation
                                1. *-lowering-*.f64N/A

                                  \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                                2. cube-multN/A

                                  \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot \left(z \cdot z\right)\right)} \]
                                3. unpow2N/A

                                  \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{{z}^{2}}\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot {z}^{2}\right)} \]
                                5. unpow2N/A

                                  \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                                6. *-lowering-*.f6436.6

                                  \[\leadsto -0.16666666666666666 \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                              11. Simplified36.6%

                                \[\leadsto \color{blue}{-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)} \]

                              if -3.5e10 < x < 4.6000000000000003e87

                              1. Initial program 100.0%

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

                                \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                              4. Step-by-step derivation
                                1. mul-1-negN/A

                                  \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                2. neg-lowering-neg.f6455.1

                                  \[\leadsto e^{\color{blue}{-z}} \]
                              5. Simplified55.1%

                                \[\leadsto e^{\color{blue}{-z}} \]
                              6. Taylor expanded in z around 0

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

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

                                  \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
                                3. sub-negN/A

                                  \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
                                4. metadata-evalN/A

                                  \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
                                5. accelerator-lowering-fma.f64N/A

                                  \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
                                6. +-commutativeN/A

                                  \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
                                7. *-commutativeN/A

                                  \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
                                8. accelerator-lowering-fma.f6433.5

                                  \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
                              8. Simplified33.5%

                                \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]

                              if 4.6000000000000003e87 < x

                              1. Initial program 100.0%

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

                                \[\leadsto e^{\color{blue}{x}} \]
                              4. Step-by-step derivation
                                1. Simplified97.9%

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

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

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

                                    \[\leadsto \color{blue}{\mathsf{fma}\left(x, 1 + x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right), 1\right)} \]
                                  3. +-commutativeN/A

                                    \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right) + 1}, 1\right) \]
                                  4. accelerator-lowering-fma.f64N/A

                                    \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, \frac{1}{2} + \frac{1}{6} \cdot x, 1\right)}, 1\right) \]
                                  5. +-commutativeN/A

                                    \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\frac{1}{6} \cdot x + \frac{1}{2}}, 1\right), 1\right) \]
                                  6. *-commutativeN/A

                                    \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{6}} + \frac{1}{2}, 1\right), 1\right) \]
                                  7. accelerator-lowering-fma.f6495.9

                                    \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.16666666666666666, 0.5\right)}, 1\right), 1\right) \]
                                4. Simplified95.9%

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

                              Alternative 12: 48.0% accurate, 6.8× speedup?

                              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq -35000000000:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;x \leq 3.05 \cdot 10^{+87}:\\ \;\;\;\;\mathsf{fma}\left(z, -0.16666666666666666 \cdot \left(z \cdot z\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\ \end{array} \end{array} \]
                              (FPCore (x y z)
                               :precision binary64
                               (if (<= x -35000000000.0)
                                 (* -0.16666666666666666 (* z (* z z)))
                                 (if (<= x 3.05e+87)
                                   (fma z (* -0.16666666666666666 (* z z)) 1.0)
                                   (fma x (fma x (fma x 0.16666666666666666 0.5) 1.0) 1.0))))
                              double code(double x, double y, double z) {
                              	double tmp;
                              	if (x <= -35000000000.0) {
                              		tmp = -0.16666666666666666 * (z * (z * z));
                              	} else if (x <= 3.05e+87) {
                              		tmp = fma(z, (-0.16666666666666666 * (z * z)), 1.0);
                              	} else {
                              		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
                              	}
                              	return tmp;
                              }
                              
                              function code(x, y, z)
                              	tmp = 0.0
                              	if (x <= -35000000000.0)
                              		tmp = Float64(-0.16666666666666666 * Float64(z * Float64(z * z)));
                              	elseif (x <= 3.05e+87)
                              		tmp = fma(z, Float64(-0.16666666666666666 * Float64(z * z)), 1.0);
                              	else
                              		tmp = fma(x, fma(x, fma(x, 0.16666666666666666, 0.5), 1.0), 1.0);
                              	end
                              	return tmp
                              end
                              
                              code[x_, y_, z_] := If[LessEqual[x, -35000000000.0], N[(-0.16666666666666666 * N[(z * N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.05e+87], N[(z * N[(-0.16666666666666666 * N[(z * z), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision], N[(x * N[(x * N[(x * 0.16666666666666666 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] + 1.0), $MachinePrecision]]]
                              
                              \begin{array}{l}
                              
                              \\
                              \begin{array}{l}
                              \mathbf{if}\;x \leq -35000000000:\\
                              \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\
                              
                              \mathbf{elif}\;x \leq 3.05 \cdot 10^{+87}:\\
                              \;\;\;\;\mathsf{fma}\left(z, -0.16666666666666666 \cdot \left(z \cdot z\right), 1\right)\\
                              
                              \mathbf{else}:\\
                              \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\
                              
                              
                              \end{array}
                              \end{array}
                              
                              Derivation
                              1. Split input into 3 regimes
                              2. if x < -3.5e10

                                1. Initial program 100.0%

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

                                  \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                4. Step-by-step derivation
                                  1. mul-1-negN/A

                                    \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                  2. neg-lowering-neg.f6433.6

                                    \[\leadsto e^{\color{blue}{-z}} \]
                                5. Simplified33.6%

                                  \[\leadsto e^{\color{blue}{-z}} \]
                                6. Taylor expanded in z around 0

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

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

                                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
                                  3. sub-negN/A

                                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
                                  4. metadata-evalN/A

                                    \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
                                  5. accelerator-lowering-fma.f64N/A

                                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
                                  6. +-commutativeN/A

                                    \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
                                  7. *-commutativeN/A

                                    \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
                                  8. accelerator-lowering-fma.f6410.3

                                    \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
                                8. Simplified10.3%

                                  \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
                                9. Taylor expanded in z around inf

                                  \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                                10. Step-by-step derivation
                                  1. *-lowering-*.f64N/A

                                    \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                                  2. cube-multN/A

                                    \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot \left(z \cdot z\right)\right)} \]
                                  3. unpow2N/A

                                    \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{{z}^{2}}\right) \]
                                  4. *-lowering-*.f64N/A

                                    \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot {z}^{2}\right)} \]
                                  5. unpow2N/A

                                    \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                                  6. *-lowering-*.f6436.6

                                    \[\leadsto -0.16666666666666666 \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                                11. Simplified36.6%

                                  \[\leadsto \color{blue}{-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)} \]

                                if -3.5e10 < x < 3.0499999999999999e87

                                1. Initial program 100.0%

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

                                  \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                4. Step-by-step derivation
                                  1. mul-1-negN/A

                                    \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                  2. neg-lowering-neg.f6455.1

                                    \[\leadsto e^{\color{blue}{-z}} \]
                                5. Simplified55.1%

                                  \[\leadsto e^{\color{blue}{-z}} \]
                                6. Taylor expanded in z around 0

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

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

                                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
                                  3. sub-negN/A

                                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
                                  4. metadata-evalN/A

                                    \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
                                  5. accelerator-lowering-fma.f64N/A

                                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
                                  6. +-commutativeN/A

                                    \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
                                  7. *-commutativeN/A

                                    \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
                                  8. accelerator-lowering-fma.f6433.5

                                    \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
                                8. Simplified33.5%

                                  \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
                                9. Taylor expanded in z around inf

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

                                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{{z}^{2} \cdot \frac{-1}{6}}, 1\right) \]
                                  2. *-lowering-*.f64N/A

                                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{{z}^{2} \cdot \frac{-1}{6}}, 1\right) \]
                                  3. unpow2N/A

                                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{\left(z \cdot z\right)} \cdot \frac{-1}{6}, 1\right) \]
                                  4. *-lowering-*.f6433.1

                                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{\left(z \cdot z\right)} \cdot -0.16666666666666666, 1\right) \]
                                11. Simplified33.1%

                                  \[\leadsto \mathsf{fma}\left(z, \color{blue}{\left(z \cdot z\right) \cdot -0.16666666666666666}, 1\right) \]

                                if 3.0499999999999999e87 < x

                                1. Initial program 100.0%

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

                                  \[\leadsto e^{\color{blue}{x}} \]
                                4. Step-by-step derivation
                                  1. Simplified97.9%

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

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

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

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(x, 1 + x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right), 1\right)} \]
                                    3. +-commutativeN/A

                                      \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \left(\frac{1}{2} + \frac{1}{6} \cdot x\right) + 1}, 1\right) \]
                                    4. accelerator-lowering-fma.f64N/A

                                      \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, \frac{1}{2} + \frac{1}{6} \cdot x, 1\right)}, 1\right) \]
                                    5. +-commutativeN/A

                                      \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\frac{1}{6} \cdot x + \frac{1}{2}}, 1\right), 1\right) \]
                                    6. *-commutativeN/A

                                      \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{6}} + \frac{1}{2}, 1\right), 1\right) \]
                                    7. accelerator-lowering-fma.f6495.9

                                      \[\leadsto \mathsf{fma}\left(x, \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.16666666666666666, 0.5\right)}, 1\right), 1\right) \]
                                  4. Simplified95.9%

                                    \[\leadsto \color{blue}{\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)} \]
                                5. Recombined 3 regimes into one program.
                                6. Final simplification45.5%

                                  \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -35000000000:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;x \leq 3.05 \cdot 10^{+87}:\\ \;\;\;\;\mathsf{fma}\left(z, -0.16666666666666666 \cdot \left(z \cdot z\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.16666666666666666, 0.5\right), 1\right), 1\right)\\ \end{array} \]
                                7. Add Preprocessing

                                Alternative 13: 45.1% accurate, 7.3× speedup?

                                \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq -2500000000000:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;x \leq 3.2 \cdot 10^{+122}:\\ \;\;\;\;\mathsf{fma}\left(z, -0.16666666666666666 \cdot \left(z \cdot z\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\ \end{array} \end{array} \]
                                (FPCore (x y z)
                                 :precision binary64
                                 (if (<= x -2500000000000.0)
                                   (* -0.16666666666666666 (* z (* z z)))
                                   (if (<= x 3.2e+122)
                                     (fma z (* -0.16666666666666666 (* z z)) 1.0)
                                     (fma x (fma x 0.5 1.0) 1.0))))
                                double code(double x, double y, double z) {
                                	double tmp;
                                	if (x <= -2500000000000.0) {
                                		tmp = -0.16666666666666666 * (z * (z * z));
                                	} else if (x <= 3.2e+122) {
                                		tmp = fma(z, (-0.16666666666666666 * (z * z)), 1.0);
                                	} else {
                                		tmp = fma(x, fma(x, 0.5, 1.0), 1.0);
                                	}
                                	return tmp;
                                }
                                
                                function code(x, y, z)
                                	tmp = 0.0
                                	if (x <= -2500000000000.0)
                                		tmp = Float64(-0.16666666666666666 * Float64(z * Float64(z * z)));
                                	elseif (x <= 3.2e+122)
                                		tmp = fma(z, Float64(-0.16666666666666666 * Float64(z * z)), 1.0);
                                	else
                                		tmp = fma(x, fma(x, 0.5, 1.0), 1.0);
                                	end
                                	return tmp
                                end
                                
                                code[x_, y_, z_] := If[LessEqual[x, -2500000000000.0], N[(-0.16666666666666666 * N[(z * N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.2e+122], N[(z * N[(-0.16666666666666666 * N[(z * z), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision], N[(x * N[(x * 0.5 + 1.0), $MachinePrecision] + 1.0), $MachinePrecision]]]
                                
                                \begin{array}{l}
                                
                                \\
                                \begin{array}{l}
                                \mathbf{if}\;x \leq -2500000000000:\\
                                \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\
                                
                                \mathbf{elif}\;x \leq 3.2 \cdot 10^{+122}:\\
                                \;\;\;\;\mathsf{fma}\left(z, -0.16666666666666666 \cdot \left(z \cdot z\right), 1\right)\\
                                
                                \mathbf{else}:\\
                                \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\
                                
                                
                                \end{array}
                                \end{array}
                                
                                Derivation
                                1. Split input into 3 regimes
                                2. if x < -2.5e12

                                  1. Initial program 100.0%

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

                                    \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                  4. Step-by-step derivation
                                    1. mul-1-negN/A

                                      \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                    2. neg-lowering-neg.f6433.6

                                      \[\leadsto e^{\color{blue}{-z}} \]
                                  5. Simplified33.6%

                                    \[\leadsto e^{\color{blue}{-z}} \]
                                  6. Taylor expanded in z around 0

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

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

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
                                    3. sub-negN/A

                                      \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
                                    4. metadata-evalN/A

                                      \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
                                    5. accelerator-lowering-fma.f64N/A

                                      \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
                                    6. +-commutativeN/A

                                      \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
                                    7. *-commutativeN/A

                                      \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
                                    8. accelerator-lowering-fma.f6410.3

                                      \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
                                  8. Simplified10.3%

                                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
                                  9. Taylor expanded in z around inf

                                    \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                                  10. Step-by-step derivation
                                    1. *-lowering-*.f64N/A

                                      \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                                    2. cube-multN/A

                                      \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot \left(z \cdot z\right)\right)} \]
                                    3. unpow2N/A

                                      \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{{z}^{2}}\right) \]
                                    4. *-lowering-*.f64N/A

                                      \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot {z}^{2}\right)} \]
                                    5. unpow2N/A

                                      \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                                    6. *-lowering-*.f6436.6

                                      \[\leadsto -0.16666666666666666 \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                                  11. Simplified36.6%

                                    \[\leadsto \color{blue}{-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)} \]

                                  if -2.5e12 < x < 3.20000000000000012e122

                                  1. Initial program 100.0%

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

                                    \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                  4. Step-by-step derivation
                                    1. mul-1-negN/A

                                      \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                    2. neg-lowering-neg.f6454.0

                                      \[\leadsto e^{\color{blue}{-z}} \]
                                  5. Simplified54.0%

                                    \[\leadsto e^{\color{blue}{-z}} \]
                                  6. Taylor expanded in z around 0

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

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

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
                                    3. sub-negN/A

                                      \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
                                    4. metadata-evalN/A

                                      \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
                                    5. accelerator-lowering-fma.f64N/A

                                      \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
                                    6. +-commutativeN/A

                                      \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
                                    7. *-commutativeN/A

                                      \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
                                    8. accelerator-lowering-fma.f6433.2

                                      \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
                                  8. Simplified33.2%

                                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
                                  9. Taylor expanded in z around inf

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

                                      \[\leadsto \mathsf{fma}\left(z, \color{blue}{{z}^{2} \cdot \frac{-1}{6}}, 1\right) \]
                                    2. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{fma}\left(z, \color{blue}{{z}^{2} \cdot \frac{-1}{6}}, 1\right) \]
                                    3. unpow2N/A

                                      \[\leadsto \mathsf{fma}\left(z, \color{blue}{\left(z \cdot z\right)} \cdot \frac{-1}{6}, 1\right) \]
                                    4. *-lowering-*.f6432.7

                                      \[\leadsto \mathsf{fma}\left(z, \color{blue}{\left(z \cdot z\right)} \cdot -0.16666666666666666, 1\right) \]
                                  11. Simplified32.7%

                                    \[\leadsto \mathsf{fma}\left(z, \color{blue}{\left(z \cdot z\right) \cdot -0.16666666666666666}, 1\right) \]

                                  if 3.20000000000000012e122 < x

                                  1. Initial program 100.0%

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

                                    \[\leadsto e^{\color{blue}{x}} \]
                                  4. Step-by-step derivation
                                    1. Simplified97.7%

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

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

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

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

                                        \[\leadsto \mathsf{fma}\left(x, \color{blue}{\frac{1}{2} \cdot x + 1}, 1\right) \]
                                      4. *-commutativeN/A

                                        \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{2}} + 1, 1\right) \]
                                      5. accelerator-lowering-fma.f6491.0

                                        \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.5, 1\right)}, 1\right) \]
                                    4. Simplified91.0%

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)} \]
                                  5. Recombined 3 regimes into one program.
                                  6. Final simplification43.2%

                                    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -2500000000000:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;x \leq 3.2 \cdot 10^{+122}:\\ \;\;\;\;\mathsf{fma}\left(z, -0.16666666666666666 \cdot \left(z \cdot z\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\ \end{array} \]
                                  7. Add Preprocessing

                                  Alternative 14: 43.6% accurate, 7.8× speedup?

                                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq -35000000000:\\ \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\ \mathbf{elif}\;x \leq 4.6 \cdot 10^{+87}:\\ \;\;\;\;\mathsf{fma}\left(z \cdot z, 0.5, 1 - z\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\ \end{array} \end{array} \]
                                  (FPCore (x y z)
                                   :precision binary64
                                   (if (<= x -35000000000.0)
                                     (* -0.16666666666666666 (* z (* z z)))
                                     (if (<= x 4.6e+87)
                                       (fma (* z z) 0.5 (- 1.0 z))
                                       (fma x (fma x 0.5 1.0) 1.0))))
                                  double code(double x, double y, double z) {
                                  	double tmp;
                                  	if (x <= -35000000000.0) {
                                  		tmp = -0.16666666666666666 * (z * (z * z));
                                  	} else if (x <= 4.6e+87) {
                                  		tmp = fma((z * z), 0.5, (1.0 - z));
                                  	} else {
                                  		tmp = fma(x, fma(x, 0.5, 1.0), 1.0);
                                  	}
                                  	return tmp;
                                  }
                                  
                                  function code(x, y, z)
                                  	tmp = 0.0
                                  	if (x <= -35000000000.0)
                                  		tmp = Float64(-0.16666666666666666 * Float64(z * Float64(z * z)));
                                  	elseif (x <= 4.6e+87)
                                  		tmp = fma(Float64(z * z), 0.5, Float64(1.0 - z));
                                  	else
                                  		tmp = fma(x, fma(x, 0.5, 1.0), 1.0);
                                  	end
                                  	return tmp
                                  end
                                  
                                  code[x_, y_, z_] := If[LessEqual[x, -35000000000.0], N[(-0.16666666666666666 * N[(z * N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 4.6e+87], N[(N[(z * z), $MachinePrecision] * 0.5 + N[(1.0 - z), $MachinePrecision]), $MachinePrecision], N[(x * N[(x * 0.5 + 1.0), $MachinePrecision] + 1.0), $MachinePrecision]]]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  \begin{array}{l}
                                  \mathbf{if}\;x \leq -35000000000:\\
                                  \;\;\;\;-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)\\
                                  
                                  \mathbf{elif}\;x \leq 4.6 \cdot 10^{+87}:\\
                                  \;\;\;\;\mathsf{fma}\left(z \cdot z, 0.5, 1 - z\right)\\
                                  
                                  \mathbf{else}:\\
                                  \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\
                                  
                                  
                                  \end{array}
                                  \end{array}
                                  
                                  Derivation
                                  1. Split input into 3 regimes
                                  2. if x < -3.5e10

                                    1. Initial program 100.0%

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

                                      \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                    4. Step-by-step derivation
                                      1. mul-1-negN/A

                                        \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                      2. neg-lowering-neg.f6433.6

                                        \[\leadsto e^{\color{blue}{-z}} \]
                                    5. Simplified33.6%

                                      \[\leadsto e^{\color{blue}{-z}} \]
                                    6. Taylor expanded in z around 0

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

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

                                        \[\leadsto \color{blue}{\mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) - 1, 1\right)} \]
                                      3. sub-negN/A

                                        \[\leadsto \mathsf{fma}\left(z, \color{blue}{z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \left(\mathsf{neg}\left(1\right)\right)}, 1\right) \]
                                      4. metadata-evalN/A

                                        \[\leadsto \mathsf{fma}\left(z, z \cdot \left(\frac{1}{2} + \frac{-1}{6} \cdot z\right) + \color{blue}{-1}, 1\right) \]
                                      5. accelerator-lowering-fma.f64N/A

                                        \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} + \frac{-1}{6} \cdot z, -1\right)}, 1\right) \]
                                      6. +-commutativeN/A

                                        \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\frac{-1}{6} \cdot z + \frac{1}{2}}, -1\right), 1\right) \]
                                      7. *-commutativeN/A

                                        \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{z \cdot \frac{-1}{6}} + \frac{1}{2}, -1\right), 1\right) \]
                                      8. accelerator-lowering-fma.f6410.3

                                        \[\leadsto \mathsf{fma}\left(z, \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, -0.16666666666666666, 0.5\right)}, -1\right), 1\right) \]
                                    8. Simplified10.3%

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, -0.16666666666666666, 0.5\right), -1\right), 1\right)} \]
                                    9. Taylor expanded in z around inf

                                      \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                                    10. Step-by-step derivation
                                      1. *-lowering-*.f64N/A

                                        \[\leadsto \color{blue}{\frac{-1}{6} \cdot {z}^{3}} \]
                                      2. cube-multN/A

                                        \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot \left(z \cdot z\right)\right)} \]
                                      3. unpow2N/A

                                        \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{{z}^{2}}\right) \]
                                      4. *-lowering-*.f64N/A

                                        \[\leadsto \frac{-1}{6} \cdot \color{blue}{\left(z \cdot {z}^{2}\right)} \]
                                      5. unpow2N/A

                                        \[\leadsto \frac{-1}{6} \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                                      6. *-lowering-*.f6436.6

                                        \[\leadsto -0.16666666666666666 \cdot \left(z \cdot \color{blue}{\left(z \cdot z\right)}\right) \]
                                    11. Simplified36.6%

                                      \[\leadsto \color{blue}{-0.16666666666666666 \cdot \left(z \cdot \left(z \cdot z\right)\right)} \]

                                    if -3.5e10 < x < 4.6000000000000003e87

                                    1. Initial program 100.0%

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

                                      \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                    4. Step-by-step derivation
                                      1. mul-1-negN/A

                                        \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                      2. neg-lowering-neg.f6455.1

                                        \[\leadsto e^{\color{blue}{-z}} \]
                                    5. Simplified55.1%

                                      \[\leadsto e^{\color{blue}{-z}} \]
                                    6. Taylor expanded in z around 0

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

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

                                        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                                      3. sub-negN/A

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

                                        \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                                      5. accelerator-lowering-fma.f6431.3

                                        \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                                    8. Simplified31.3%

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                                    9. Step-by-step derivation
                                      1. distribute-lft-inN/A

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

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

                                        \[\leadsto z \cdot \color{blue}{\left(z \cdot \frac{1}{2}\right)} + \left(z \cdot -1 + 1\right) \]
                                      4. associate-*r*N/A

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

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

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

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

                                        \[\leadsto \mathsf{fma}\left(z \cdot z, \frac{1}{2}, \color{blue}{1 + -1 \cdot z}\right) \]
                                      9. neg-mul-1N/A

                                        \[\leadsto \mathsf{fma}\left(z \cdot z, \frac{1}{2}, 1 + \color{blue}{\left(\mathsf{neg}\left(z\right)\right)}\right) \]
                                      10. sub-negN/A

                                        \[\leadsto \mathsf{fma}\left(z \cdot z, \frac{1}{2}, \color{blue}{1 - z}\right) \]
                                      11. --lowering--.f6431.3

                                        \[\leadsto \mathsf{fma}\left(z \cdot z, 0.5, \color{blue}{1 - z}\right) \]
                                    10. Applied egg-rr31.3%

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(z \cdot z, 0.5, 1 - z\right)} \]

                                    if 4.6000000000000003e87 < x

                                    1. Initial program 100.0%

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

                                      \[\leadsto e^{\color{blue}{x}} \]
                                    4. Step-by-step derivation
                                      1. Simplified97.9%

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

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

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

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

                                          \[\leadsto \mathsf{fma}\left(x, \color{blue}{\frac{1}{2} \cdot x + 1}, 1\right) \]
                                        4. *-commutativeN/A

                                          \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{2}} + 1, 1\right) \]
                                        5. accelerator-lowering-fma.f6482.0

                                          \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.5, 1\right)}, 1\right) \]
                                      4. Simplified82.0%

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

                                    Alternative 15: 41.9% accurate, 7.8× speedup?

                                    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq -860000000000:\\ \;\;\;\;\left(z \cdot z\right) \cdot 0.5\\ \mathbf{elif}\;x \leq 4.6 \cdot 10^{+87}:\\ \;\;\;\;\mathsf{fma}\left(z \cdot z, 0.5, 1 - z\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\ \end{array} \end{array} \]
                                    (FPCore (x y z)
                                     :precision binary64
                                     (if (<= x -860000000000.0)
                                       (* (* z z) 0.5)
                                       (if (<= x 4.6e+87)
                                         (fma (* z z) 0.5 (- 1.0 z))
                                         (fma x (fma x 0.5 1.0) 1.0))))
                                    double code(double x, double y, double z) {
                                    	double tmp;
                                    	if (x <= -860000000000.0) {
                                    		tmp = (z * z) * 0.5;
                                    	} else if (x <= 4.6e+87) {
                                    		tmp = fma((z * z), 0.5, (1.0 - z));
                                    	} else {
                                    		tmp = fma(x, fma(x, 0.5, 1.0), 1.0);
                                    	}
                                    	return tmp;
                                    }
                                    
                                    function code(x, y, z)
                                    	tmp = 0.0
                                    	if (x <= -860000000000.0)
                                    		tmp = Float64(Float64(z * z) * 0.5);
                                    	elseif (x <= 4.6e+87)
                                    		tmp = fma(Float64(z * z), 0.5, Float64(1.0 - z));
                                    	else
                                    		tmp = fma(x, fma(x, 0.5, 1.0), 1.0);
                                    	end
                                    	return tmp
                                    end
                                    
                                    code[x_, y_, z_] := If[LessEqual[x, -860000000000.0], N[(N[(z * z), $MachinePrecision] * 0.5), $MachinePrecision], If[LessEqual[x, 4.6e+87], N[(N[(z * z), $MachinePrecision] * 0.5 + N[(1.0 - z), $MachinePrecision]), $MachinePrecision], N[(x * N[(x * 0.5 + 1.0), $MachinePrecision] + 1.0), $MachinePrecision]]]
                                    
                                    \begin{array}{l}
                                    
                                    \\
                                    \begin{array}{l}
                                    \mathbf{if}\;x \leq -860000000000:\\
                                    \;\;\;\;\left(z \cdot z\right) \cdot 0.5\\
                                    
                                    \mathbf{elif}\;x \leq 4.6 \cdot 10^{+87}:\\
                                    \;\;\;\;\mathsf{fma}\left(z \cdot z, 0.5, 1 - z\right)\\
                                    
                                    \mathbf{else}:\\
                                    \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\
                                    
                                    
                                    \end{array}
                                    \end{array}
                                    
                                    Derivation
                                    1. Split input into 3 regimes
                                    2. if x < -8.6e11

                                      1. Initial program 100.0%

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

                                        \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                      4. Step-by-step derivation
                                        1. mul-1-negN/A

                                          \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                        2. neg-lowering-neg.f6433.6

                                          \[\leadsto e^{\color{blue}{-z}} \]
                                      5. Simplified33.6%

                                        \[\leadsto e^{\color{blue}{-z}} \]
                                      6. Taylor expanded in z around 0

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

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

                                          \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                                        3. sub-negN/A

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

                                          \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                                        5. accelerator-lowering-fma.f6415.1

                                          \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                                      8. Simplified15.1%

                                        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                                      9. Taylor expanded in z around inf

                                        \[\leadsto \color{blue}{\frac{1}{2} \cdot {z}^{2}} \]
                                      10. Step-by-step derivation
                                        1. *-lowering-*.f64N/A

                                          \[\leadsto \color{blue}{\frac{1}{2} \cdot {z}^{2}} \]
                                        2. unpow2N/A

                                          \[\leadsto \frac{1}{2} \cdot \color{blue}{\left(z \cdot z\right)} \]
                                        3. *-lowering-*.f6434.1

                                          \[\leadsto 0.5 \cdot \color{blue}{\left(z \cdot z\right)} \]
                                      11. Simplified34.1%

                                        \[\leadsto \color{blue}{0.5 \cdot \left(z \cdot z\right)} \]

                                      if -8.6e11 < x < 4.6000000000000003e87

                                      1. Initial program 100.0%

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

                                        \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                      4. Step-by-step derivation
                                        1. mul-1-negN/A

                                          \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                        2. neg-lowering-neg.f6455.1

                                          \[\leadsto e^{\color{blue}{-z}} \]
                                      5. Simplified55.1%

                                        \[\leadsto e^{\color{blue}{-z}} \]
                                      6. Taylor expanded in z around 0

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

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

                                          \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                                        3. sub-negN/A

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

                                          \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                                        5. accelerator-lowering-fma.f6431.3

                                          \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                                      8. Simplified31.3%

                                        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                                      9. Step-by-step derivation
                                        1. distribute-lft-inN/A

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

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

                                          \[\leadsto z \cdot \color{blue}{\left(z \cdot \frac{1}{2}\right)} + \left(z \cdot -1 + 1\right) \]
                                        4. associate-*r*N/A

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

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

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

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

                                          \[\leadsto \mathsf{fma}\left(z \cdot z, \frac{1}{2}, \color{blue}{1 + -1 \cdot z}\right) \]
                                        9. neg-mul-1N/A

                                          \[\leadsto \mathsf{fma}\left(z \cdot z, \frac{1}{2}, 1 + \color{blue}{\left(\mathsf{neg}\left(z\right)\right)}\right) \]
                                        10. sub-negN/A

                                          \[\leadsto \mathsf{fma}\left(z \cdot z, \frac{1}{2}, \color{blue}{1 - z}\right) \]
                                        11. --lowering--.f6431.3

                                          \[\leadsto \mathsf{fma}\left(z \cdot z, 0.5, \color{blue}{1 - z}\right) \]
                                      10. Applied egg-rr31.3%

                                        \[\leadsto \color{blue}{\mathsf{fma}\left(z \cdot z, 0.5, 1 - z\right)} \]

                                      if 4.6000000000000003e87 < x

                                      1. Initial program 100.0%

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

                                        \[\leadsto e^{\color{blue}{x}} \]
                                      4. Step-by-step derivation
                                        1. Simplified97.9%

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

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

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

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

                                            \[\leadsto \mathsf{fma}\left(x, \color{blue}{\frac{1}{2} \cdot x + 1}, 1\right) \]
                                          4. *-commutativeN/A

                                            \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{2}} + 1, 1\right) \]
                                          5. accelerator-lowering-fma.f6482.0

                                            \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.5, 1\right)}, 1\right) \]
                                        4. Simplified82.0%

                                          \[\leadsto \color{blue}{\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)} \]
                                      5. Recombined 3 regimes into one program.
                                      6. Final simplification41.3%

                                        \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -860000000000:\\ \;\;\;\;\left(z \cdot z\right) \cdot 0.5\\ \mathbf{elif}\;x \leq 4.6 \cdot 10^{+87}:\\ \;\;\;\;\mathsf{fma}\left(z \cdot z, 0.5, 1 - z\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\ \end{array} \]
                                      7. Add Preprocessing

                                      Alternative 16: 41.9% accurate, 8.5× speedup?

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

                                        1. Initial program 100.0%

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

                                          \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                        4. Step-by-step derivation
                                          1. mul-1-negN/A

                                            \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                          2. neg-lowering-neg.f6433.6

                                            \[\leadsto e^{\color{blue}{-z}} \]
                                        5. Simplified33.6%

                                          \[\leadsto e^{\color{blue}{-z}} \]
                                        6. Taylor expanded in z around 0

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

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

                                            \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                                          3. sub-negN/A

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

                                            \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                                          5. accelerator-lowering-fma.f6415.1

                                            \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                                        8. Simplified15.1%

                                          \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                                        9. Taylor expanded in z around inf

                                          \[\leadsto \color{blue}{\frac{1}{2} \cdot {z}^{2}} \]
                                        10. Step-by-step derivation
                                          1. *-lowering-*.f64N/A

                                            \[\leadsto \color{blue}{\frac{1}{2} \cdot {z}^{2}} \]
                                          2. unpow2N/A

                                            \[\leadsto \frac{1}{2} \cdot \color{blue}{\left(z \cdot z\right)} \]
                                          3. *-lowering-*.f6434.1

                                            \[\leadsto 0.5 \cdot \color{blue}{\left(z \cdot z\right)} \]
                                        11. Simplified34.1%

                                          \[\leadsto \color{blue}{0.5 \cdot \left(z \cdot z\right)} \]

                                        if -4.8e10 < x < 3.9999999999999998e87

                                        1. Initial program 100.0%

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

                                          \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                        4. Step-by-step derivation
                                          1. mul-1-negN/A

                                            \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                          2. neg-lowering-neg.f6455.1

                                            \[\leadsto e^{\color{blue}{-z}} \]
                                        5. Simplified55.1%

                                          \[\leadsto e^{\color{blue}{-z}} \]
                                        6. Taylor expanded in z around 0

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

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

                                            \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                                          3. sub-negN/A

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

                                            \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                                          5. accelerator-lowering-fma.f6431.3

                                            \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                                        8. Simplified31.3%

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

                                        if 3.9999999999999998e87 < x

                                        1. Initial program 100.0%

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

                                          \[\leadsto e^{\color{blue}{x}} \]
                                        4. Step-by-step derivation
                                          1. Simplified97.9%

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

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

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

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

                                              \[\leadsto \mathsf{fma}\left(x, \color{blue}{\frac{1}{2} \cdot x + 1}, 1\right) \]
                                            4. *-commutativeN/A

                                              \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{2}} + 1, 1\right) \]
                                            5. accelerator-lowering-fma.f6482.0

                                              \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.5, 1\right)}, 1\right) \]
                                          4. Simplified82.0%

                                            \[\leadsto \color{blue}{\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)} \]
                                        5. Recombined 3 regimes into one program.
                                        6. Final simplification41.3%

                                          \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -48000000000:\\ \;\;\;\;\left(z \cdot z\right) \cdot 0.5\\ \mathbf{elif}\;x \leq 4 \cdot 10^{+87}:\\ \;\;\;\;\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\ \end{array} \]
                                        7. Add Preprocessing

                                        Alternative 17: 41.7% accurate, 8.5× speedup?

                                        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq -62000000000:\\ \;\;\;\;\left(z \cdot z\right) \cdot 0.5\\ \mathbf{elif}\;x \leq 2.7 \cdot 10^{+87}:\\ \;\;\;\;\mathsf{fma}\left(z, z \cdot 0.5, 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\ \end{array} \end{array} \]
                                        (FPCore (x y z)
                                         :precision binary64
                                         (if (<= x -62000000000.0)
                                           (* (* z z) 0.5)
                                           (if (<= x 2.7e+87) (fma z (* z 0.5) 1.0) (fma x (fma x 0.5 1.0) 1.0))))
                                        double code(double x, double y, double z) {
                                        	double tmp;
                                        	if (x <= -62000000000.0) {
                                        		tmp = (z * z) * 0.5;
                                        	} else if (x <= 2.7e+87) {
                                        		tmp = fma(z, (z * 0.5), 1.0);
                                        	} else {
                                        		tmp = fma(x, fma(x, 0.5, 1.0), 1.0);
                                        	}
                                        	return tmp;
                                        }
                                        
                                        function code(x, y, z)
                                        	tmp = 0.0
                                        	if (x <= -62000000000.0)
                                        		tmp = Float64(Float64(z * z) * 0.5);
                                        	elseif (x <= 2.7e+87)
                                        		tmp = fma(z, Float64(z * 0.5), 1.0);
                                        	else
                                        		tmp = fma(x, fma(x, 0.5, 1.0), 1.0);
                                        	end
                                        	return tmp
                                        end
                                        
                                        code[x_, y_, z_] := If[LessEqual[x, -62000000000.0], N[(N[(z * z), $MachinePrecision] * 0.5), $MachinePrecision], If[LessEqual[x, 2.7e+87], N[(z * N[(z * 0.5), $MachinePrecision] + 1.0), $MachinePrecision], N[(x * N[(x * 0.5 + 1.0), $MachinePrecision] + 1.0), $MachinePrecision]]]
                                        
                                        \begin{array}{l}
                                        
                                        \\
                                        \begin{array}{l}
                                        \mathbf{if}\;x \leq -62000000000:\\
                                        \;\;\;\;\left(z \cdot z\right) \cdot 0.5\\
                                        
                                        \mathbf{elif}\;x \leq 2.7 \cdot 10^{+87}:\\
                                        \;\;\;\;\mathsf{fma}\left(z, z \cdot 0.5, 1\right)\\
                                        
                                        \mathbf{else}:\\
                                        \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\
                                        
                                        
                                        \end{array}
                                        \end{array}
                                        
                                        Derivation
                                        1. Split input into 3 regimes
                                        2. if x < -6.2e10

                                          1. Initial program 100.0%

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

                                            \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                          4. Step-by-step derivation
                                            1. mul-1-negN/A

                                              \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                            2. neg-lowering-neg.f6433.6

                                              \[\leadsto e^{\color{blue}{-z}} \]
                                          5. Simplified33.6%

                                            \[\leadsto e^{\color{blue}{-z}} \]
                                          6. Taylor expanded in z around 0

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

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

                                              \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                                            3. sub-negN/A

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

                                              \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                                            5. accelerator-lowering-fma.f6415.1

                                              \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                                          8. Simplified15.1%

                                            \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                                          9. Taylor expanded in z around inf

                                            \[\leadsto \color{blue}{\frac{1}{2} \cdot {z}^{2}} \]
                                          10. Step-by-step derivation
                                            1. *-lowering-*.f64N/A

                                              \[\leadsto \color{blue}{\frac{1}{2} \cdot {z}^{2}} \]
                                            2. unpow2N/A

                                              \[\leadsto \frac{1}{2} \cdot \color{blue}{\left(z \cdot z\right)} \]
                                            3. *-lowering-*.f6434.1

                                              \[\leadsto 0.5 \cdot \color{blue}{\left(z \cdot z\right)} \]
                                          11. Simplified34.1%

                                            \[\leadsto \color{blue}{0.5 \cdot \left(z \cdot z\right)} \]

                                          if -6.2e10 < x < 2.70000000000000007e87

                                          1. Initial program 100.0%

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

                                            \[\leadsto e^{\color{blue}{-1 \cdot z}} \]
                                          4. Step-by-step derivation
                                            1. mul-1-negN/A

                                              \[\leadsto e^{\color{blue}{\mathsf{neg}\left(z\right)}} \]
                                            2. neg-lowering-neg.f6455.1

                                              \[\leadsto e^{\color{blue}{-z}} \]
                                          5. Simplified55.1%

                                            \[\leadsto e^{\color{blue}{-z}} \]
                                          6. Taylor expanded in z around 0

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

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

                                              \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{1}{2} \cdot z - 1, 1\right)} \]
                                            3. sub-negN/A

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

                                              \[\leadsto \mathsf{fma}\left(z, \frac{1}{2} \cdot z + \color{blue}{-1}, 1\right) \]
                                            5. accelerator-lowering-fma.f6431.3

                                              \[\leadsto \mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(0.5, z, -1\right)}, 1\right) \]
                                          8. Simplified31.3%

                                            \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(0.5, z, -1\right), 1\right)} \]
                                          9. Taylor expanded in z around inf

                                            \[\leadsto \mathsf{fma}\left(z, \color{blue}{\frac{1}{2} \cdot z}, 1\right) \]
                                          10. Step-by-step derivation
                                            1. *-lowering-*.f6430.9

                                              \[\leadsto \mathsf{fma}\left(z, \color{blue}{0.5 \cdot z}, 1\right) \]
                                          11. Simplified30.9%

                                            \[\leadsto \mathsf{fma}\left(z, \color{blue}{0.5 \cdot z}, 1\right) \]

                                          if 2.70000000000000007e87 < x

                                          1. Initial program 100.0%

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

                                            \[\leadsto e^{\color{blue}{x}} \]
                                          4. Step-by-step derivation
                                            1. Simplified97.9%

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

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

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

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

                                                \[\leadsto \mathsf{fma}\left(x, \color{blue}{\frac{1}{2} \cdot x + 1}, 1\right) \]
                                              4. *-commutativeN/A

                                                \[\leadsto \mathsf{fma}\left(x, \color{blue}{x \cdot \frac{1}{2}} + 1, 1\right) \]
                                              5. accelerator-lowering-fma.f6482.0

                                                \[\leadsto \mathsf{fma}\left(x, \color{blue}{\mathsf{fma}\left(x, 0.5, 1\right)}, 1\right) \]
                                            4. Simplified82.0%

                                              \[\leadsto \color{blue}{\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)} \]
                                          5. Recombined 3 regimes into one program.
                                          6. Final simplification41.1%

                                            \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -62000000000:\\ \;\;\;\;\left(z \cdot z\right) \cdot 0.5\\ \mathbf{elif}\;x \leq 2.7 \cdot 10^{+87}:\\ \;\;\;\;\mathsf{fma}\left(z, z \cdot 0.5, 1\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, \mathsf{fma}\left(x, 0.5, 1\right), 1\right)\\ \end{array} \]
                                          7. Add Preprocessing

                                          Alternative 18: 14.7% accurate, 53.0× speedup?

                                          \[\begin{array}{l} \\ x + 1 \end{array} \]
                                          (FPCore (x y z) :precision binary64 (+ x 1.0))
                                          double code(double x, double y, double z) {
                                          	return x + 1.0;
                                          }
                                          
                                          real(8) function code(x, y, z)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              real(8), intent (in) :: z
                                              code = x + 1.0d0
                                          end function
                                          
                                          public static double code(double x, double y, double z) {
                                          	return x + 1.0;
                                          }
                                          
                                          def code(x, y, z):
                                          	return x + 1.0
                                          
                                          function code(x, y, z)
                                          	return Float64(x + 1.0)
                                          end
                                          
                                          function tmp = code(x, y, z)
                                          	tmp = x + 1.0;
                                          end
                                          
                                          code[x_, y_, z_] := N[(x + 1.0), $MachinePrecision]
                                          
                                          \begin{array}{l}
                                          
                                          \\
                                          x + 1
                                          \end{array}
                                          
                                          Derivation
                                          1. Initial program 100.0%

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

                                            \[\leadsto e^{\color{blue}{x}} \]
                                          4. Step-by-step derivation
                                            1. Simplified53.6%

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

                                              \[\leadsto \color{blue}{1 + x} \]
                                            3. Step-by-step derivation
                                              1. +-lowering-+.f6412.4

                                                \[\leadsto \color{blue}{1 + x} \]
                                            4. Simplified12.4%

                                              \[\leadsto \color{blue}{1 + x} \]
                                            5. Final simplification12.4%

                                              \[\leadsto x + 1 \]
                                            6. Add Preprocessing

                                            Alternative 19: 14.5% accurate, 212.0× speedup?

                                            \[\begin{array}{l} \\ 1 \end{array} \]
                                            (FPCore (x y z) :precision binary64 1.0)
                                            double code(double x, double y, double z) {
                                            	return 1.0;
                                            }
                                            
                                            real(8) function code(x, y, z)
                                                real(8), intent (in) :: x
                                                real(8), intent (in) :: y
                                                real(8), intent (in) :: z
                                                code = 1.0d0
                                            end function
                                            
                                            public static double code(double x, double y, double z) {
                                            	return 1.0;
                                            }
                                            
                                            def code(x, y, z):
                                            	return 1.0
                                            
                                            function code(x, y, z)
                                            	return 1.0
                                            end
                                            
                                            function tmp = code(x, y, z)
                                            	tmp = 1.0;
                                            end
                                            
                                            code[x_, y_, z_] := 1.0
                                            
                                            \begin{array}{l}
                                            
                                            \\
                                            1
                                            \end{array}
                                            
                                            Derivation
                                            1. Initial program 100.0%

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

                                              \[\leadsto e^{\color{blue}{x}} \]
                                            4. Step-by-step derivation
                                              1. Simplified53.6%

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

                                                \[\leadsto \color{blue}{1} \]
                                              3. Step-by-step derivation
                                                1. Simplified12.0%

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

                                                Developer Target 1: 100.0% accurate, 1.0× speedup?

                                                \[\begin{array}{l} \\ e^{\left(x - z\right) + \log y \cdot y} \end{array} \]
                                                (FPCore (x y z) :precision binary64 (exp (+ (- x z) (* (log y) y))))
                                                double code(double x, double y, double z) {
                                                	return exp(((x - z) + (log(y) * y)));
                                                }
                                                
                                                real(8) function code(x, y, z)
                                                    real(8), intent (in) :: x
                                                    real(8), intent (in) :: y
                                                    real(8), intent (in) :: z
                                                    code = exp(((x - z) + (log(y) * y)))
                                                end function
                                                
                                                public static double code(double x, double y, double z) {
                                                	return Math.exp(((x - z) + (Math.log(y) * y)));
                                                }
                                                
                                                def code(x, y, z):
                                                	return math.exp(((x - z) + (math.log(y) * y)))
                                                
                                                function code(x, y, z)
                                                	return exp(Float64(Float64(x - z) + Float64(log(y) * y)))
                                                end
                                                
                                                function tmp = code(x, y, z)
                                                	tmp = exp(((x - z) + (log(y) * y)));
                                                end
                                                
                                                code[x_, y_, z_] := N[Exp[N[(N[(x - z), $MachinePrecision] + N[(N[Log[y], $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
                                                
                                                \begin{array}{l}
                                                
                                                \\
                                                e^{\left(x - z\right) + \log y \cdot y}
                                                \end{array}
                                                

                                                Reproduce

                                                ?
                                                herbie shell --seed 2024204 
                                                (FPCore (x y z)
                                                  :name "Statistics.Distribution.Poisson.Internal:probability from math-functions-0.1.5.2"
                                                  :precision binary64
                                                
                                                  :alt
                                                  (! :herbie-platform default (exp (+ (- x z) (* (log y) y))))
                                                
                                                  (exp (- (+ x (* y (log y))) z)))