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

Percentage Accurate: 95.6% → 99.5%
Time: 9.1s
Alternatives: 14
Speedup: 2.8×

Specification

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

\\
x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y}
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

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

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

\\
x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y}
\end{array}

Alternative 1: 99.5% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;e^{z} \leq 0:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{elif}\;e^{z} \leq 1.000005:\\ \;\;\;\;x - \frac{y}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\frac{0.8862269254527579}{e^{z}}, y, x\right)\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= (exp z) 0.0)
   (+ (/ -1.0 x) x)
   (if (<= (exp z) 1.000005)
     (-
      x
      (/
       y
       (fma
        x
        y
        (fma
         (fma
          (fma -0.18806319451591877 z -0.5641895835477563)
          z
          -1.1283791670955126)
         z
         -1.1283791670955126))))
     (fma (/ 0.8862269254527579 (exp z)) y x))))
double code(double x, double y, double z) {
	double tmp;
	if (exp(z) <= 0.0) {
		tmp = (-1.0 / x) + x;
	} else if (exp(z) <= 1.000005) {
		tmp = x - (y / fma(x, y, fma(fma(fma(-0.18806319451591877, z, -0.5641895835477563), z, -1.1283791670955126), z, -1.1283791670955126)));
	} else {
		tmp = fma((0.8862269254527579 / exp(z)), y, x);
	}
	return tmp;
}
function code(x, y, z)
	tmp = 0.0
	if (exp(z) <= 0.0)
		tmp = Float64(Float64(-1.0 / x) + x);
	elseif (exp(z) <= 1.000005)
		tmp = Float64(x - Float64(y / fma(x, y, fma(fma(fma(-0.18806319451591877, z, -0.5641895835477563), z, -1.1283791670955126), z, -1.1283791670955126))));
	else
		tmp = fma(Float64(0.8862269254527579 / exp(z)), y, x);
	end
	return tmp
end
code[x_, y_, z_] := If[LessEqual[N[Exp[z], $MachinePrecision], 0.0], N[(N[(-1.0 / x), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[N[Exp[z], $MachinePrecision], 1.000005], N[(x - N[(y / N[(x * y + N[(N[(N[(-0.18806319451591877 * z + -0.5641895835477563), $MachinePrecision] * z + -1.1283791670955126), $MachinePrecision] * z + -1.1283791670955126), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(0.8862269254527579 / N[Exp[z], $MachinePrecision]), $MachinePrecision] * y + x), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;e^{z} \leq 0:\\
\;\;\;\;\frac{-1}{x} + x\\

\mathbf{elif}\;e^{z} \leq 1.000005:\\
\;\;\;\;x - \frac{y}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(\frac{0.8862269254527579}{e^{z}}, y, x\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (exp.f64 z) < 0.0

    1. Initial program 89.2%

      \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf

      \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
    4. Step-by-step derivation
      1. lower-/.f64100.0

        \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
    5. Applied rewrites100.0%

      \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

    if 0.0 < (exp.f64 z) < 1.00000500000000003

    1. Initial program 99.9%

      \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

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

        \[\leadsto x + \color{blue}{\frac{1}{\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}}} \]
      3. frac-2negN/A

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

        \[\leadsto x + \frac{\color{blue}{-1}}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)} \]
      5. lower-/.f64N/A

        \[\leadsto x + \color{blue}{\frac{-1}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)}} \]
      6. distribute-neg-fracN/A

        \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
      7. lower-/.f64N/A

        \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
      8. lift--.f64N/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{neg}\left(\color{blue}{\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)}\right)}{y}} \]
      9. sub-negN/A

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

        \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z}\right)\right) + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}}{y}} \]
      11. lift-*.f64N/A

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

        \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z}} + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}{y}} \]
      13. remove-double-negN/A

        \[\leadsto x + \frac{-1}{\frac{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z} + \color{blue}{x \cdot y}}{y}} \]
      14. lower-fma.f64N/A

        \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right), e^{z}, x \cdot y\right)}}{y}} \]
      15. metadata-eval99.8

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\color{blue}{-1.1283791670955126}, e^{z}, x \cdot y\right)}{y}} \]
      16. lift-*.f64N/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{x \cdot y}\right)}{y}} \]
      17. *-commutativeN/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
      18. lower-*.f6499.8

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(-1.1283791670955126, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
    4. Applied rewrites99.8%

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

      \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(x \cdot y + z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)\right) - \frac{5641895835477563}{5000000000000000}}}{y}} \]
    6. Step-by-step derivation
      1. associate--l+N/A

        \[\leadsto x + \frac{-1}{\frac{\color{blue}{x \cdot y + \left(z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)}}{y}} \]
      2. lower-fma.f64N/A

        \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(x, y, z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)}}{y}} \]
      3. sub-negN/A

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

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \color{blue}{\left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) \cdot z} + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right)\right)}{y}} \]
      5. metadata-evalN/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) \cdot z + \color{blue}{\frac{-5641895835477563}{5000000000000000}}\right)}{y}} \]
      6. lower-fma.f64N/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \color{blue}{\mathsf{fma}\left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}, z, \frac{-5641895835477563}{5000000000000000}\right)}\right)}{y}} \]
      7. sub-negN/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right)}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
      8. *-commutativeN/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) \cdot z} + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
      9. metadata-evalN/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) \cdot z + \color{blue}{\frac{-5641895835477563}{5000000000000000}}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
      10. lower-fma.f64N/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}, z, \frac{-5641895835477563}{5000000000000000}\right)}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
      11. sub-negN/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\frac{-5641895835477563}{30000000000000000} \cdot z + \left(\mathsf{neg}\left(\frac{5641895835477563}{10000000000000000}\right)\right)}, z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
      12. metadata-evalN/A

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000} \cdot z + \color{blue}{\frac{-5641895835477563}{10000000000000000}}, z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
      13. lower-fma.f6499.8

        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right)}, z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}{y}} \]
    7. Applied rewrites99.8%

      \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}}{y}} \]
    8. Step-by-step derivation
      1. lift-+.f64N/A

        \[\leadsto \color{blue}{x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
      2. lift-/.f64N/A

        \[\leadsto x + \color{blue}{\frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
      3. div-invN/A

        \[\leadsto x + \color{blue}{-1 \cdot \frac{1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
      4. lift-/.f64N/A

        \[\leadsto x + -1 \cdot \frac{1}{\color{blue}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
      5. clear-num-revN/A

        \[\leadsto x + -1 \cdot \color{blue}{\frac{y}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}} \]
      6. cancel-sign-sub-invN/A

        \[\leadsto \color{blue}{x - \left(\mathsf{neg}\left(-1\right)\right) \cdot \frac{y}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}} \]
      7. clear-num-revN/A

        \[\leadsto x - \left(\mathsf{neg}\left(-1\right)\right) \cdot \color{blue}{\frac{1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
      8. lift-/.f64N/A

        \[\leadsto x - \left(\mathsf{neg}\left(-1\right)\right) \cdot \frac{1}{\color{blue}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
    9. Applied rewrites99.9%

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

    if 1.00000500000000003 < (exp.f64 z)

    1. Initial program 95.5%

      \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0

      \[\leadsto \color{blue}{x + \frac{5000000000000000}{5641895835477563} \cdot \frac{y}{e^{z}}} \]
    4. Step-by-step derivation
      1. +-commutativeN/A

        \[\leadsto \color{blue}{\frac{5000000000000000}{5641895835477563} \cdot \frac{y}{e^{z}} + x} \]
      2. associate-*r/N/A

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

        \[\leadsto \color{blue}{\frac{\frac{5000000000000000}{5641895835477563}}{e^{z}} \cdot y} + x \]
      4. metadata-evalN/A

        \[\leadsto \frac{\color{blue}{\frac{5000000000000000}{5641895835477563} \cdot 1}}{e^{z}} \cdot y + x \]
      5. associate-*r/N/A

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

        \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{5000000000000000}{5641895835477563} \cdot \frac{1}{e^{z}}, y, x\right)} \]
      7. associate-*r/N/A

        \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{\frac{5000000000000000}{5641895835477563} \cdot 1}{e^{z}}}, y, x\right) \]
      8. metadata-evalN/A

        \[\leadsto \mathsf{fma}\left(\frac{\color{blue}{\frac{5000000000000000}{5641895835477563}}}{e^{z}}, y, x\right) \]
      9. lower-/.f64N/A

        \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{\frac{5000000000000000}{5641895835477563}}{e^{z}}}, y, x\right) \]
      10. lower-exp.f64100.0

        \[\leadsto \mathsf{fma}\left(\frac{0.8862269254527579}{\color{blue}{e^{z}}}, y, x\right) \]
    5. Applied rewrites100.0%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{0.8862269254527579}{e^{z}}, y, x\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{z} \leq 0:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{elif}\;e^{z} \leq 1.000005:\\ \;\;\;\;x - \frac{y}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\frac{0.8862269254527579}{e^{z}}, y, x\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 83.6% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \frac{-1}{x} + x\\ t_1 := x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}}\\ \mathbf{if}\;t\_1 \leq -100:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;t\_1 \leq 5 \cdot 10^{-19}:\\ \;\;\;\;\frac{y}{1.1283791670955126} + x\\ \mathbf{else}:\\ \;\;\;\;t\_0\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (+ (/ -1.0 x) x))
        (t_1 (- x (/ y (- (* y x) (* 1.1283791670955126 (exp z)))))))
   (if (<= t_1 -100.0)
     t_0
     (if (<= t_1 5e-19) (+ (/ y 1.1283791670955126) x) t_0))))
double code(double x, double y, double z) {
	double t_0 = (-1.0 / x) + x;
	double t_1 = x - (y / ((y * x) - (1.1283791670955126 * exp(z))));
	double tmp;
	if (t_1 <= -100.0) {
		tmp = t_0;
	} else if (t_1 <= 5e-19) {
		tmp = (y / 1.1283791670955126) + x;
	} else {
		tmp = t_0;
	}
	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 = ((-1.0d0) / x) + x
    t_1 = x - (y / ((y * x) - (1.1283791670955126d0 * exp(z))))
    if (t_1 <= (-100.0d0)) then
        tmp = t_0
    else if (t_1 <= 5d-19) then
        tmp = (y / 1.1283791670955126d0) + x
    else
        tmp = t_0
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = (-1.0 / x) + x;
	double t_1 = x - (y / ((y * x) - (1.1283791670955126 * Math.exp(z))));
	double tmp;
	if (t_1 <= -100.0) {
		tmp = t_0;
	} else if (t_1 <= 5e-19) {
		tmp = (y / 1.1283791670955126) + x;
	} else {
		tmp = t_0;
	}
	return tmp;
}
def code(x, y, z):
	t_0 = (-1.0 / x) + x
	t_1 = x - (y / ((y * x) - (1.1283791670955126 * math.exp(z))))
	tmp = 0
	if t_1 <= -100.0:
		tmp = t_0
	elif t_1 <= 5e-19:
		tmp = (y / 1.1283791670955126) + x
	else:
		tmp = t_0
	return tmp
function code(x, y, z)
	t_0 = Float64(Float64(-1.0 / x) + x)
	t_1 = Float64(x - Float64(y / Float64(Float64(y * x) - Float64(1.1283791670955126 * exp(z)))))
	tmp = 0.0
	if (t_1 <= -100.0)
		tmp = t_0;
	elseif (t_1 <= 5e-19)
		tmp = Float64(Float64(y / 1.1283791670955126) + x);
	else
		tmp = t_0;
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = (-1.0 / x) + x;
	t_1 = x - (y / ((y * x) - (1.1283791670955126 * exp(z))));
	tmp = 0.0;
	if (t_1 <= -100.0)
		tmp = t_0;
	elseif (t_1 <= 5e-19)
		tmp = (y / 1.1283791670955126) + x;
	else
		tmp = t_0;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(-1.0 / x), $MachinePrecision] + x), $MachinePrecision]}, Block[{t$95$1 = N[(x - N[(y / N[(N[(y * x), $MachinePrecision] - N[(1.1283791670955126 * N[Exp[z], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -100.0], t$95$0, If[LessEqual[t$95$1, 5e-19], N[(N[(y / 1.1283791670955126), $MachinePrecision] + x), $MachinePrecision], t$95$0]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \frac{-1}{x} + x\\
t_1 := x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}}\\
\mathbf{if}\;t\_1 \leq -100:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;t\_1 \leq 5 \cdot 10^{-19}:\\
\;\;\;\;\frac{y}{1.1283791670955126} + x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (+.f64 x (/.f64 y (-.f64 (*.f64 #s(literal 5641895835477563/5000000000000000 binary64) (exp.f64 z)) (*.f64 x y)))) < -100 or 5.0000000000000004e-19 < (+.f64 x (/.f64 y (-.f64 (*.f64 #s(literal 5641895835477563/5000000000000000 binary64) (exp.f64 z)) (*.f64 x y))))

    1. Initial program 94.4%

      \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf

      \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
    4. Step-by-step derivation
      1. lower-/.f6492.1

        \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
    5. Applied rewrites92.1%

      \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

    if -100 < (+.f64 x (/.f64 y (-.f64 (*.f64 #s(literal 5641895835477563/5000000000000000 binary64) (exp.f64 z)) (*.f64 x y)))) < 5.0000000000000004e-19

    1. Initial program 99.9%

      \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0

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

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

        \[\leadsto x + \frac{y}{\color{blue}{\left(\mathsf{neg}\left(x \cdot y\right)\right) + \frac{5641895835477563}{5000000000000000}}} \]
      3. mul-1-negN/A

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

        \[\leadsto x + \frac{y}{\color{blue}{\left(-1 \cdot x\right) \cdot y} + \frac{5641895835477563}{5000000000000000}} \]
      5. lower-fma.f64N/A

        \[\leadsto x + \frac{y}{\color{blue}{\mathsf{fma}\left(-1 \cdot x, y, \frac{5641895835477563}{5000000000000000}\right)}} \]
      6. mul-1-negN/A

        \[\leadsto x + \frac{y}{\mathsf{fma}\left(\color{blue}{\mathsf{neg}\left(x\right)}, y, \frac{5641895835477563}{5000000000000000}\right)} \]
      7. lower-neg.f6459.6

        \[\leadsto x + \frac{y}{\mathsf{fma}\left(\color{blue}{-x}, y, 1.1283791670955126\right)} \]
    5. Applied rewrites59.6%

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

      \[\leadsto x + \frac{y}{\frac{5641895835477563}{5000000000000000}} \]
    7. Step-by-step derivation
      1. Applied rewrites58.1%

        \[\leadsto x + \frac{y}{1.1283791670955126} \]
    8. Recombined 2 regimes into one program.
    9. Final simplification83.3%

      \[\leadsto \begin{array}{l} \mathbf{if}\;x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}} \leq -100:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{elif}\;x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}} \leq 5 \cdot 10^{-19}:\\ \;\;\;\;\frac{y}{1.1283791670955126} + x\\ \mathbf{else}:\\ \;\;\;\;\frac{-1}{x} + x\\ \end{array} \]
    10. Add Preprocessing

    Alternative 3: 83.5% accurate, 0.5× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_0 := \frac{-1}{x} + x\\ t_1 := x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}}\\ \mathbf{if}\;t\_1 \leq -100:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;t\_1 \leq 5 \cdot 10^{-19}:\\ \;\;\;\;0.8862269254527579 \cdot y + x\\ \mathbf{else}:\\ \;\;\;\;t\_0\\ \end{array} \end{array} \]
    (FPCore (x y z)
     :precision binary64
     (let* ((t_0 (+ (/ -1.0 x) x))
            (t_1 (- x (/ y (- (* y x) (* 1.1283791670955126 (exp z)))))))
       (if (<= t_1 -100.0)
         t_0
         (if (<= t_1 5e-19) (+ (* 0.8862269254527579 y) x) t_0))))
    double code(double x, double y, double z) {
    	double t_0 = (-1.0 / x) + x;
    	double t_1 = x - (y / ((y * x) - (1.1283791670955126 * exp(z))));
    	double tmp;
    	if (t_1 <= -100.0) {
    		tmp = t_0;
    	} else if (t_1 <= 5e-19) {
    		tmp = (0.8862269254527579 * y) + x;
    	} else {
    		tmp = t_0;
    	}
    	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 = ((-1.0d0) / x) + x
        t_1 = x - (y / ((y * x) - (1.1283791670955126d0 * exp(z))))
        if (t_1 <= (-100.0d0)) then
            tmp = t_0
        else if (t_1 <= 5d-19) then
            tmp = (0.8862269254527579d0 * y) + x
        else
            tmp = t_0
        end if
        code = tmp
    end function
    
    public static double code(double x, double y, double z) {
    	double t_0 = (-1.0 / x) + x;
    	double t_1 = x - (y / ((y * x) - (1.1283791670955126 * Math.exp(z))));
    	double tmp;
    	if (t_1 <= -100.0) {
    		tmp = t_0;
    	} else if (t_1 <= 5e-19) {
    		tmp = (0.8862269254527579 * y) + x;
    	} else {
    		tmp = t_0;
    	}
    	return tmp;
    }
    
    def code(x, y, z):
    	t_0 = (-1.0 / x) + x
    	t_1 = x - (y / ((y * x) - (1.1283791670955126 * math.exp(z))))
    	tmp = 0
    	if t_1 <= -100.0:
    		tmp = t_0
    	elif t_1 <= 5e-19:
    		tmp = (0.8862269254527579 * y) + x
    	else:
    		tmp = t_0
    	return tmp
    
    function code(x, y, z)
    	t_0 = Float64(Float64(-1.0 / x) + x)
    	t_1 = Float64(x - Float64(y / Float64(Float64(y * x) - Float64(1.1283791670955126 * exp(z)))))
    	tmp = 0.0
    	if (t_1 <= -100.0)
    		tmp = t_0;
    	elseif (t_1 <= 5e-19)
    		tmp = Float64(Float64(0.8862269254527579 * y) + x);
    	else
    		tmp = t_0;
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y, z)
    	t_0 = (-1.0 / x) + x;
    	t_1 = x - (y / ((y * x) - (1.1283791670955126 * exp(z))));
    	tmp = 0.0;
    	if (t_1 <= -100.0)
    		tmp = t_0;
    	elseif (t_1 <= 5e-19)
    		tmp = (0.8862269254527579 * y) + x;
    	else
    		tmp = t_0;
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_, z_] := Block[{t$95$0 = N[(N[(-1.0 / x), $MachinePrecision] + x), $MachinePrecision]}, Block[{t$95$1 = N[(x - N[(y / N[(N[(y * x), $MachinePrecision] - N[(1.1283791670955126 * N[Exp[z], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -100.0], t$95$0, If[LessEqual[t$95$1, 5e-19], N[(N[(0.8862269254527579 * y), $MachinePrecision] + x), $MachinePrecision], t$95$0]]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_0 := \frac{-1}{x} + x\\
    t_1 := x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}}\\
    \mathbf{if}\;t\_1 \leq -100:\\
    \;\;\;\;t\_0\\
    
    \mathbf{elif}\;t\_1 \leq 5 \cdot 10^{-19}:\\
    \;\;\;\;0.8862269254527579 \cdot y + x\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_0\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if (+.f64 x (/.f64 y (-.f64 (*.f64 #s(literal 5641895835477563/5000000000000000 binary64) (exp.f64 z)) (*.f64 x y)))) < -100 or 5.0000000000000004e-19 < (+.f64 x (/.f64 y (-.f64 (*.f64 #s(literal 5641895835477563/5000000000000000 binary64) (exp.f64 z)) (*.f64 x y))))

      1. Initial program 94.4%

        \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
      2. Add Preprocessing
      3. Taylor expanded in x around inf

        \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
      4. Step-by-step derivation
        1. lower-/.f6492.1

          \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
      5. Applied rewrites92.1%

        \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

      if -100 < (+.f64 x (/.f64 y (-.f64 (*.f64 #s(literal 5641895835477563/5000000000000000 binary64) (exp.f64 z)) (*.f64 x y)))) < 5.0000000000000004e-19

      1. Initial program 99.9%

        \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
      2. Add Preprocessing
      3. Taylor expanded in z around 0

        \[\leadsto x + \color{blue}{\left(\frac{-5641895835477563}{5000000000000000} \cdot \frac{y \cdot z}{{\left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right)}^{2}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right)} \]
      4. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto x + \left(\color{blue}{\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{{\left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right)}^{2}}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right) \]
        2. unpow2N/A

          \[\leadsto x + \left(\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{\color{blue}{\left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right) \cdot \left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right)}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right) \]
        3. associate-/r*N/A

          \[\leadsto x + \left(\color{blue}{\frac{\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{\frac{5641895835477563}{5000000000000000} - x \cdot y}}{\frac{5641895835477563}{5000000000000000} - x \cdot y}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right) \]
        4. div-add-revN/A

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

          \[\leadsto x + \color{blue}{\frac{\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{\frac{5641895835477563}{5000000000000000} - x \cdot y} + y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}} \]
      5. Applied rewrites52.8%

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

        \[\leadsto x + \frac{5000000000000000}{5641895835477563} \cdot \color{blue}{\left(y + -1 \cdot \left(y \cdot z\right)\right)} \]
      7. Step-by-step derivation
        1. Applied rewrites51.3%

          \[\leadsto x + \left(y - y \cdot z\right) \cdot \color{blue}{0.8862269254527579} \]
        2. Taylor expanded in z around 0

          \[\leadsto x + \frac{5000000000000000}{5641895835477563} \cdot y \]
        3. Step-by-step derivation
          1. Applied rewrites58.0%

            \[\leadsto x + 0.8862269254527579 \cdot y \]
        4. Recombined 2 regimes into one program.
        5. Final simplification83.3%

          \[\leadsto \begin{array}{l} \mathbf{if}\;x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}} \leq -100:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{elif}\;x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}} \leq 5 \cdot 10^{-19}:\\ \;\;\;\;0.8862269254527579 \cdot y + x\\ \mathbf{else}:\\ \;\;\;\;\frac{-1}{x} + x\\ \end{array} \]
        6. Add Preprocessing

        Alternative 4: 93.7% accurate, 0.5× speedup?

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

          1. Initial program 89.2%

            \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
          2. Add Preprocessing
          3. Taylor expanded in x around inf

            \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
          4. Step-by-step derivation
            1. lower-/.f64100.0

              \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
          5. Applied rewrites100.0%

            \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

          if 0.0 < (exp.f64 z) < 1.19999999999999996

          1. Initial program 99.9%

            \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
          2. Add Preprocessing
          3. Step-by-step derivation
            1. lift-/.f64N/A

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

              \[\leadsto x + \color{blue}{\frac{1}{\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}}} \]
            3. frac-2negN/A

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

              \[\leadsto x + \frac{\color{blue}{-1}}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)} \]
            5. lower-/.f64N/A

              \[\leadsto x + \color{blue}{\frac{-1}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)}} \]
            6. distribute-neg-fracN/A

              \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
            7. lower-/.f64N/A

              \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
            8. lift--.f64N/A

              \[\leadsto x + \frac{-1}{\frac{\mathsf{neg}\left(\color{blue}{\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)}\right)}{y}} \]
            9. sub-negN/A

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

              \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z}\right)\right) + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}}{y}} \]
            11. lift-*.f64N/A

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

              \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z}} + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}{y}} \]
            13. remove-double-negN/A

              \[\leadsto x + \frac{-1}{\frac{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z} + \color{blue}{x \cdot y}}{y}} \]
            14. lower-fma.f64N/A

              \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right), e^{z}, x \cdot y\right)}}{y}} \]
            15. metadata-eval99.8

              \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\color{blue}{-1.1283791670955126}, e^{z}, x \cdot y\right)}{y}} \]
            16. lift-*.f64N/A

              \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{x \cdot y}\right)}{y}} \]
            17. *-commutativeN/A

              \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
            18. lower-*.f6499.8

              \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(-1.1283791670955126, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
          4. Applied rewrites99.8%

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

            \[\leadsto \color{blue}{x + -1 \cdot \frac{y}{x \cdot y - \frac{5641895835477563}{5000000000000000}}} \]
          6. Step-by-step derivation
            1. mul-1-negN/A

              \[\leadsto x + \color{blue}{\left(\mathsf{neg}\left(\frac{y}{x \cdot y - \frac{5641895835477563}{5000000000000000}}\right)\right)} \]
            2. unsub-negN/A

              \[\leadsto \color{blue}{x - \frac{y}{x \cdot y - \frac{5641895835477563}{5000000000000000}}} \]
            3. lower--.f64N/A

              \[\leadsto \color{blue}{x - \frac{y}{x \cdot y - \frac{5641895835477563}{5000000000000000}}} \]
            4. lower-/.f64N/A

              \[\leadsto x - \color{blue}{\frac{y}{x \cdot y - \frac{5641895835477563}{5000000000000000}}} \]
            5. sub-negN/A

              \[\leadsto x - \frac{y}{\color{blue}{x \cdot y + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right)}} \]
            6. metadata-evalN/A

              \[\leadsto x - \frac{y}{x \cdot y + \color{blue}{\frac{-5641895835477563}{5000000000000000}}} \]
            7. lower-fma.f6499.3

              \[\leadsto x - \frac{y}{\color{blue}{\mathsf{fma}\left(x, y, -1.1283791670955126\right)}} \]
          7. Applied rewrites99.3%

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

          if 1.19999999999999996 < (exp.f64 z)

          1. Initial program 95.5%

            \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
          2. Add Preprocessing
          3. Taylor expanded in z around 0

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

              \[\leadsto x + \frac{y}{\color{blue}{\left(\frac{5641895835477563}{5000000000000000} \cdot z + \frac{5641895835477563}{5000000000000000}\right)} - x \cdot y} \]
            2. lower-fma.f6472.1

              \[\leadsto x + \frac{y}{\color{blue}{\mathsf{fma}\left(1.1283791670955126, z, 1.1283791670955126\right)} - x \cdot y} \]
          5. Applied rewrites72.1%

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

            \[\leadsto x + \frac{y}{\frac{5641895835477563}{5000000000000000} \cdot \color{blue}{z} - x \cdot y} \]
          7. Step-by-step derivation
            1. Applied rewrites72.1%

              \[\leadsto x + \frac{y}{1.1283791670955126 \cdot \color{blue}{z} - x \cdot y} \]
          8. Recombined 3 regimes into one program.
          9. Final simplification92.5%

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

          Alternative 5: 98.5% accurate, 0.5× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;e^{z} \leq 0:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}}\\ \end{array} \end{array} \]
          (FPCore (x y z)
           :precision binary64
           (if (<= (exp z) 0.0)
             (+ (/ -1.0 x) x)
             (- x (/ y (- (* y x) (* 1.1283791670955126 (exp z)))))))
          double code(double x, double y, double z) {
          	double tmp;
          	if (exp(z) <= 0.0) {
          		tmp = (-1.0 / x) + x;
          	} else {
          		tmp = x - (y / ((y * x) - (1.1283791670955126 * exp(z))));
          	}
          	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 (exp(z) <= 0.0d0) then
                  tmp = ((-1.0d0) / x) + x
              else
                  tmp = x - (y / ((y * x) - (1.1283791670955126d0 * exp(z))))
              end if
              code = tmp
          end function
          
          public static double code(double x, double y, double z) {
          	double tmp;
          	if (Math.exp(z) <= 0.0) {
          		tmp = (-1.0 / x) + x;
          	} else {
          		tmp = x - (y / ((y * x) - (1.1283791670955126 * Math.exp(z))));
          	}
          	return tmp;
          }
          
          def code(x, y, z):
          	tmp = 0
          	if math.exp(z) <= 0.0:
          		tmp = (-1.0 / x) + x
          	else:
          		tmp = x - (y / ((y * x) - (1.1283791670955126 * math.exp(z))))
          	return tmp
          
          function code(x, y, z)
          	tmp = 0.0
          	if (exp(z) <= 0.0)
          		tmp = Float64(Float64(-1.0 / x) + x);
          	else
          		tmp = Float64(x - Float64(y / Float64(Float64(y * x) - Float64(1.1283791670955126 * exp(z)))));
          	end
          	return tmp
          end
          
          function tmp_2 = code(x, y, z)
          	tmp = 0.0;
          	if (exp(z) <= 0.0)
          		tmp = (-1.0 / x) + x;
          	else
          		tmp = x - (y / ((y * x) - (1.1283791670955126 * exp(z))));
          	end
          	tmp_2 = tmp;
          end
          
          code[x_, y_, z_] := If[LessEqual[N[Exp[z], $MachinePrecision], 0.0], N[(N[(-1.0 / x), $MachinePrecision] + x), $MachinePrecision], N[(x - N[(y / N[(N[(y * x), $MachinePrecision] - N[(1.1283791670955126 * N[Exp[z], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          \mathbf{if}\;e^{z} \leq 0:\\
          \;\;\;\;\frac{-1}{x} + x\\
          
          \mathbf{else}:\\
          \;\;\;\;x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}}\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 2 regimes
          2. if (exp.f64 z) < 0.0

            1. Initial program 89.2%

              \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
            2. Add Preprocessing
            3. Taylor expanded in x around inf

              \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
            4. Step-by-step derivation
              1. lower-/.f64100.0

                \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
            5. Applied rewrites100.0%

              \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

            if 0.0 < (exp.f64 z)

            1. Initial program 98.3%

              \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
            2. Add Preprocessing
          3. Recombined 2 regimes into one program.
          4. Final simplification98.8%

            \[\leadsto \begin{array}{l} \mathbf{if}\;e^{z} \leq 0:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot e^{z}}\\ \end{array} \]
          5. Add Preprocessing

          Alternative 6: 98.8% accurate, 0.8× speedup?

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

            1. Initial program 89.2%

              \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
            2. Add Preprocessing
            3. Taylor expanded in x around inf

              \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
            4. Step-by-step derivation
              1. lower-/.f64100.0

                \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
            5. Applied rewrites100.0%

              \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

            if 0.0 < (exp.f64 z)

            1. Initial program 98.3%

              \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
            2. Add Preprocessing
            3. Step-by-step derivation
              1. lift-/.f64N/A

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

                \[\leadsto x + \color{blue}{\frac{1}{\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}}} \]
              3. frac-2negN/A

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

                \[\leadsto x + \frac{\color{blue}{-1}}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)} \]
              5. lower-/.f64N/A

                \[\leadsto x + \color{blue}{\frac{-1}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)}} \]
              6. distribute-neg-fracN/A

                \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
              7. lower-/.f64N/A

                \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
              8. lift--.f64N/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{neg}\left(\color{blue}{\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)}\right)}{y}} \]
              9. sub-negN/A

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

                \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z}\right)\right) + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}}{y}} \]
              11. lift-*.f64N/A

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

                \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z}} + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}{y}} \]
              13. remove-double-negN/A

                \[\leadsto x + \frac{-1}{\frac{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z} + \color{blue}{x \cdot y}}{y}} \]
              14. lower-fma.f64N/A

                \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right), e^{z}, x \cdot y\right)}}{y}} \]
              15. metadata-eval98.3

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\color{blue}{-1.1283791670955126}, e^{z}, x \cdot y\right)}{y}} \]
              16. lift-*.f64N/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{x \cdot y}\right)}{y}} \]
              17. *-commutativeN/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
              18. lower-*.f6498.3

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(-1.1283791670955126, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
            4. Applied rewrites98.3%

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

              \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(x \cdot y + z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)\right) - \frac{5641895835477563}{5000000000000000}}}{y}} \]
            6. Step-by-step derivation
              1. associate--l+N/A

                \[\leadsto x + \frac{-1}{\frac{\color{blue}{x \cdot y + \left(z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)}}{y}} \]
              2. lower-fma.f64N/A

                \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(x, y, z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)}}{y}} \]
              3. sub-negN/A

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

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \color{blue}{\left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) \cdot z} + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right)\right)}{y}} \]
              5. metadata-evalN/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) \cdot z + \color{blue}{\frac{-5641895835477563}{5000000000000000}}\right)}{y}} \]
              6. lower-fma.f64N/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \color{blue}{\mathsf{fma}\left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}, z, \frac{-5641895835477563}{5000000000000000}\right)}\right)}{y}} \]
              7. sub-negN/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right)}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
              8. *-commutativeN/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) \cdot z} + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
              9. metadata-evalN/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) \cdot z + \color{blue}{\frac{-5641895835477563}{5000000000000000}}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
              10. lower-fma.f64N/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}, z, \frac{-5641895835477563}{5000000000000000}\right)}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
              11. sub-negN/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\frac{-5641895835477563}{30000000000000000} \cdot z + \left(\mathsf{neg}\left(\frac{5641895835477563}{10000000000000000}\right)\right)}, z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
              12. metadata-evalN/A

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000} \cdot z + \color{blue}{\frac{-5641895835477563}{10000000000000000}}, z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
              13. lower-fma.f6493.4

                \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right)}, z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}{y}} \]
            7. Applied rewrites93.4%

              \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}}{y}} \]
            8. Taylor expanded in x around inf

              \[\leadsto x + \frac{-1}{\frac{x \cdot \color{blue}{\left(\left(y + \frac{z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)}{x}\right) - \frac{5641895835477563}{5000000000000000} \cdot \frac{1}{x}\right)}}{y}} \]
            9. Step-by-step derivation
              1. Applied rewrites96.7%

                \[\leadsto x + \frac{-1}{\frac{\left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)}{x} + y\right) \cdot \color{blue}{x}}{y}} \]
              2. Applied rewrites96.7%

                \[\leadsto \color{blue}{x - \frac{y}{\left(y + \frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(z, -0.18806319451591877, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)}{x}\right) \cdot x}} \]
            10. Recombined 2 regimes into one program.
            11. Final simplification97.6%

              \[\leadsto \begin{array}{l} \mathbf{if}\;e^{z} \leq 0:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{\left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(z, -0.18806319451591877, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)}{x} + y\right) \cdot x}\\ \end{array} \]
            12. Add Preprocessing

            Alternative 7: 97.8% accurate, 0.9× speedup?

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

              1. Initial program 89.2%

                \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
              2. Add Preprocessing
              3. Taylor expanded in x around inf

                \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
              4. Step-by-step derivation
                1. lower-/.f64100.0

                  \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
              5. Applied rewrites100.0%

                \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

              if 0.0 < (exp.f64 z)

              1. Initial program 98.3%

                \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
              2. Add Preprocessing
              3. Step-by-step derivation
                1. lift-/.f64N/A

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

                  \[\leadsto x + \color{blue}{\frac{1}{\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}}} \]
                3. frac-2negN/A

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

                  \[\leadsto x + \frac{\color{blue}{-1}}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)} \]
                5. lower-/.f64N/A

                  \[\leadsto x + \color{blue}{\frac{-1}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)}} \]
                6. distribute-neg-fracN/A

                  \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
                7. lower-/.f64N/A

                  \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
                8. lift--.f64N/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{neg}\left(\color{blue}{\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)}\right)}{y}} \]
                9. sub-negN/A

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

                  \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z}\right)\right) + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}}{y}} \]
                11. lift-*.f64N/A

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

                  \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z}} + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}{y}} \]
                13. remove-double-negN/A

                  \[\leadsto x + \frac{-1}{\frac{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z} + \color{blue}{x \cdot y}}{y}} \]
                14. lower-fma.f64N/A

                  \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right), e^{z}, x \cdot y\right)}}{y}} \]
                15. metadata-eval98.3

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\color{blue}{-1.1283791670955126}, e^{z}, x \cdot y\right)}{y}} \]
                16. lift-*.f64N/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{x \cdot y}\right)}{y}} \]
                17. *-commutativeN/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
                18. lower-*.f6498.3

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(-1.1283791670955126, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
              4. Applied rewrites98.3%

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

                \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(x \cdot y + z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)\right) - \frac{5641895835477563}{5000000000000000}}}{y}} \]
              6. Step-by-step derivation
                1. associate--l+N/A

                  \[\leadsto x + \frac{-1}{\frac{\color{blue}{x \cdot y + \left(z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)}}{y}} \]
                2. lower-fma.f64N/A

                  \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(x, y, z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)}}{y}} \]
                3. sub-negN/A

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

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \color{blue}{\left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) \cdot z} + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right)\right)}{y}} \]
                5. metadata-evalN/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) \cdot z + \color{blue}{\frac{-5641895835477563}{5000000000000000}}\right)}{y}} \]
                6. lower-fma.f64N/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \color{blue}{\mathsf{fma}\left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}, z, \frac{-5641895835477563}{5000000000000000}\right)}\right)}{y}} \]
                7. sub-negN/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right)}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                8. *-commutativeN/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) \cdot z} + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                9. metadata-evalN/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) \cdot z + \color{blue}{\frac{-5641895835477563}{5000000000000000}}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                10. lower-fma.f64N/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}, z, \frac{-5641895835477563}{5000000000000000}\right)}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                11. sub-negN/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\frac{-5641895835477563}{30000000000000000} \cdot z + \left(\mathsf{neg}\left(\frac{5641895835477563}{10000000000000000}\right)\right)}, z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                12. metadata-evalN/A

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000} \cdot z + \color{blue}{\frac{-5641895835477563}{10000000000000000}}, z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                13. lower-fma.f6493.4

                  \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right)}, z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}{y}} \]
              7. Applied rewrites93.4%

                \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}}{y}} \]
              8. Step-by-step derivation
                1. lift-+.f64N/A

                  \[\leadsto \color{blue}{x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
                2. lift-/.f64N/A

                  \[\leadsto x + \color{blue}{\frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
                3. div-invN/A

                  \[\leadsto x + \color{blue}{-1 \cdot \frac{1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
                4. lift-/.f64N/A

                  \[\leadsto x + -1 \cdot \frac{1}{\color{blue}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
                5. clear-num-revN/A

                  \[\leadsto x + -1 \cdot \color{blue}{\frac{y}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}} \]
                6. cancel-sign-sub-invN/A

                  \[\leadsto \color{blue}{x - \left(\mathsf{neg}\left(-1\right)\right) \cdot \frac{y}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}} \]
                7. clear-num-revN/A

                  \[\leadsto x - \left(\mathsf{neg}\left(-1\right)\right) \cdot \color{blue}{\frac{1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
                8. lift-/.f64N/A

                  \[\leadsto x - \left(\mathsf{neg}\left(-1\right)\right) \cdot \frac{1}{\color{blue}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}}} \]
              9. Applied rewrites93.4%

                \[\leadsto \color{blue}{x - \frac{y}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}} \]
            3. Recombined 2 regimes into one program.
            4. Final simplification95.2%

              \[\leadsto \begin{array}{l} \mathbf{if}\;e^{z} \leq 0:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}\\ \end{array} \]
            5. Add Preprocessing

            Alternative 8: 96.2% accurate, 0.9× speedup?

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

              1. Initial program 89.2%

                \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
              2. Add Preprocessing
              3. Taylor expanded in x around inf

                \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
              4. Step-by-step derivation
                1. lower-/.f64100.0

                  \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
              5. Applied rewrites100.0%

                \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

              if 0.0 < (exp.f64 z)

              1. Initial program 98.3%

                \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
              2. Add Preprocessing
              3. Taylor expanded in z around 0

                \[\leadsto x + \frac{y}{\color{blue}{\left(\frac{5641895835477563}{5000000000000000} + z \cdot \left(\frac{5641895835477563}{5000000000000000} + \frac{5641895835477563}{10000000000000000} \cdot z\right)\right)} - x \cdot y} \]
              4. Step-by-step derivation
                1. +-commutativeN/A

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

                  \[\leadsto x + \frac{y}{\left(\color{blue}{\left(\frac{5641895835477563}{5000000000000000} + \frac{5641895835477563}{10000000000000000} \cdot z\right) \cdot z} + \frac{5641895835477563}{5000000000000000}\right) - x \cdot y} \]
                3. lower-fma.f64N/A

                  \[\leadsto x + \frac{y}{\color{blue}{\mathsf{fma}\left(\frac{5641895835477563}{5000000000000000} + \frac{5641895835477563}{10000000000000000} \cdot z, z, \frac{5641895835477563}{5000000000000000}\right)} - x \cdot y} \]
                4. +-commutativeN/A

                  \[\leadsto x + \frac{y}{\mathsf{fma}\left(\color{blue}{\frac{5641895835477563}{10000000000000000} \cdot z + \frac{5641895835477563}{5000000000000000}}, z, \frac{5641895835477563}{5000000000000000}\right) - x \cdot y} \]
                5. lower-fma.f6491.6

                  \[\leadsto x + \frac{y}{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(0.5641895835477563, z, 1.1283791670955126\right)}, z, 1.1283791670955126\right) - x \cdot y} \]
              5. Applied rewrites91.6%

                \[\leadsto x + \frac{y}{\color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(0.5641895835477563, z, 1.1283791670955126\right), z, 1.1283791670955126\right)} - x \cdot y} \]
            3. Recombined 2 regimes into one program.
            4. Final simplification93.9%

              \[\leadsto \begin{array}{l} \mathbf{if}\;e^{z} \leq 0:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{y \cdot x - \mathsf{fma}\left(\mathsf{fma}\left(0.5641895835477563, z, 1.1283791670955126\right), z, 1.1283791670955126\right)}\\ \end{array} \]
            5. Add Preprocessing

            Alternative 9: 96.0% accurate, 0.9× speedup?

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

              1. Initial program 89.2%

                \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
              2. Add Preprocessing
              3. Taylor expanded in x around inf

                \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
              4. Step-by-step derivation
                1. lower-/.f64100.0

                  \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
              5. Applied rewrites100.0%

                \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

              if 0.0 < (exp.f64 z)

              1. Initial program 98.3%

                \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
              2. Add Preprocessing
              3. Taylor expanded in z around 0

                \[\leadsto x + \frac{y}{\color{blue}{\left(\frac{5641895835477563}{5000000000000000} + z \cdot \left(\frac{5641895835477563}{5000000000000000} + \frac{5641895835477563}{10000000000000000} \cdot z\right)\right)} - x \cdot y} \]
              4. Step-by-step derivation
                1. +-commutativeN/A

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

                  \[\leadsto x + \frac{y}{\left(\color{blue}{\left(\frac{5641895835477563}{5000000000000000} + \frac{5641895835477563}{10000000000000000} \cdot z\right) \cdot z} + \frac{5641895835477563}{5000000000000000}\right) - x \cdot y} \]
                3. lower-fma.f64N/A

                  \[\leadsto x + \frac{y}{\color{blue}{\mathsf{fma}\left(\frac{5641895835477563}{5000000000000000} + \frac{5641895835477563}{10000000000000000} \cdot z, z, \frac{5641895835477563}{5000000000000000}\right)} - x \cdot y} \]
                4. +-commutativeN/A

                  \[\leadsto x + \frac{y}{\mathsf{fma}\left(\color{blue}{\frac{5641895835477563}{10000000000000000} \cdot z + \frac{5641895835477563}{5000000000000000}}, z, \frac{5641895835477563}{5000000000000000}\right) - x \cdot y} \]
                5. lower-fma.f6491.6

                  \[\leadsto x + \frac{y}{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(0.5641895835477563, z, 1.1283791670955126\right)}, z, 1.1283791670955126\right) - x \cdot y} \]
              5. Applied rewrites91.6%

                \[\leadsto x + \frac{y}{\color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(0.5641895835477563, z, 1.1283791670955126\right), z, 1.1283791670955126\right)} - x \cdot y} \]
              6. Taylor expanded in z around inf

                \[\leadsto x + \frac{y}{\mathsf{fma}\left(\frac{5641895835477563}{10000000000000000} \cdot z, z, \frac{5641895835477563}{5000000000000000}\right) - x \cdot y} \]
              7. Step-by-step derivation
                1. Applied rewrites91.3%

                  \[\leadsto x + \frac{y}{\mathsf{fma}\left(0.5641895835477563 \cdot z, z, 1.1283791670955126\right) - x \cdot y} \]
              8. Recombined 2 regimes into one program.
              9. Final simplification93.7%

                \[\leadsto \begin{array}{l} \mathbf{if}\;e^{z} \leq 0:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{y \cdot x - \mathsf{fma}\left(0.5641895835477563 \cdot z, z, 1.1283791670955126\right)}\\ \end{array} \]
              10. Add Preprocessing

              Alternative 10: 97.2% accurate, 2.8× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -17000000:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{elif}\;z \leq 1.25 \cdot 10^{+14}:\\ \;\;\;\;\frac{y - y \cdot z}{\mathsf{fma}\left(-x, y, 1.1283791670955126\right)} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(z, -0.18806319451591877, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)}\\ \end{array} \end{array} \]
              (FPCore (x y z)
               :precision binary64
               (if (<= z -17000000.0)
                 (+ (/ -1.0 x) x)
                 (if (<= z 1.25e+14)
                   (+ (/ (- y (* y z)) (fma (- x) y 1.1283791670955126)) x)
                   (-
                    x
                    (/
                     y
                     (fma
                      (fma
                       (fma z -0.18806319451591877 -0.5641895835477563)
                       z
                       -1.1283791670955126)
                      z
                      -1.1283791670955126))))))
              double code(double x, double y, double z) {
              	double tmp;
              	if (z <= -17000000.0) {
              		tmp = (-1.0 / x) + x;
              	} else if (z <= 1.25e+14) {
              		tmp = ((y - (y * z)) / fma(-x, y, 1.1283791670955126)) + x;
              	} else {
              		tmp = x - (y / fma(fma(fma(z, -0.18806319451591877, -0.5641895835477563), z, -1.1283791670955126), z, -1.1283791670955126));
              	}
              	return tmp;
              }
              
              function code(x, y, z)
              	tmp = 0.0
              	if (z <= -17000000.0)
              		tmp = Float64(Float64(-1.0 / x) + x);
              	elseif (z <= 1.25e+14)
              		tmp = Float64(Float64(Float64(y - Float64(y * z)) / fma(Float64(-x), y, 1.1283791670955126)) + x);
              	else
              		tmp = Float64(x - Float64(y / fma(fma(fma(z, -0.18806319451591877, -0.5641895835477563), z, -1.1283791670955126), z, -1.1283791670955126)));
              	end
              	return tmp
              end
              
              code[x_, y_, z_] := If[LessEqual[z, -17000000.0], N[(N[(-1.0 / x), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[z, 1.25e+14], N[(N[(N[(y - N[(y * z), $MachinePrecision]), $MachinePrecision] / N[((-x) * y + 1.1283791670955126), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], N[(x - N[(y / N[(N[(N[(z * -0.18806319451591877 + -0.5641895835477563), $MachinePrecision] * z + -1.1283791670955126), $MachinePrecision] * z + -1.1283791670955126), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              \mathbf{if}\;z \leq -17000000:\\
              \;\;\;\;\frac{-1}{x} + x\\
              
              \mathbf{elif}\;z \leq 1.25 \cdot 10^{+14}:\\
              \;\;\;\;\frac{y - y \cdot z}{\mathsf{fma}\left(-x, y, 1.1283791670955126\right)} + x\\
              
              \mathbf{else}:\\
              \;\;\;\;x - \frac{y}{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(z, -0.18806319451591877, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)}\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 3 regimes
              2. if z < -1.7e7

                1. Initial program 89.0%

                  \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                2. Add Preprocessing
                3. Taylor expanded in x around inf

                  \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
                4. Step-by-step derivation
                  1. lower-/.f64100.0

                    \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
                5. Applied rewrites100.0%

                  \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

                if -1.7e7 < z < 1.25e14

                1. Initial program 99.1%

                  \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                2. Add Preprocessing
                3. Taylor expanded in z around 0

                  \[\leadsto x + \color{blue}{\left(\frac{-5641895835477563}{5000000000000000} \cdot \frac{y \cdot z}{{\left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right)}^{2}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right)} \]
                4. Step-by-step derivation
                  1. associate-*r/N/A

                    \[\leadsto x + \left(\color{blue}{\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{{\left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right)}^{2}}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right) \]
                  2. unpow2N/A

                    \[\leadsto x + \left(\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{\color{blue}{\left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right) \cdot \left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right)}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right) \]
                  3. associate-/r*N/A

                    \[\leadsto x + \left(\color{blue}{\frac{\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{\frac{5641895835477563}{5000000000000000} - x \cdot y}}{\frac{5641895835477563}{5000000000000000} - x \cdot y}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right) \]
                  4. div-add-revN/A

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

                    \[\leadsto x + \color{blue}{\frac{\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{\frac{5641895835477563}{5000000000000000} - x \cdot y} + y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}} \]
                5. Applied rewrites99.1%

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

                  \[\leadsto x + \frac{y + -1 \cdot \left(y \cdot z\right)}{\mathsf{fma}\left(\color{blue}{-x}, y, \frac{5641895835477563}{5000000000000000}\right)} \]
                7. Step-by-step derivation
                  1. Applied rewrites99.1%

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

                  if 1.25e14 < z

                  1. Initial program 96.6%

                    \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                  2. Add Preprocessing
                  3. Step-by-step derivation
                    1. lift-/.f64N/A

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

                      \[\leadsto x + \color{blue}{\frac{1}{\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}}} \]
                    3. frac-2negN/A

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

                      \[\leadsto x + \frac{\color{blue}{-1}}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)} \]
                    5. lower-/.f64N/A

                      \[\leadsto x + \color{blue}{\frac{-1}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)}} \]
                    6. distribute-neg-fracN/A

                      \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
                    7. lower-/.f64N/A

                      \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
                    8. lift--.f64N/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{neg}\left(\color{blue}{\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)}\right)}{y}} \]
                    9. sub-negN/A

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

                      \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z}\right)\right) + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}}{y}} \]
                    11. lift-*.f64N/A

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

                      \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z}} + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}{y}} \]
                    13. remove-double-negN/A

                      \[\leadsto x + \frac{-1}{\frac{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z} + \color{blue}{x \cdot y}}{y}} \]
                    14. lower-fma.f64N/A

                      \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right), e^{z}, x \cdot y\right)}}{y}} \]
                    15. metadata-eval96.6

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\color{blue}{-1.1283791670955126}, e^{z}, x \cdot y\right)}{y}} \]
                    16. lift-*.f64N/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{x \cdot y}\right)}{y}} \]
                    17. *-commutativeN/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
                    18. lower-*.f6496.6

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(-1.1283791670955126, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
                  4. Applied rewrites96.6%

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

                    \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(x \cdot y + z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)\right) - \frac{5641895835477563}{5000000000000000}}}{y}} \]
                  6. Step-by-step derivation
                    1. associate--l+N/A

                      \[\leadsto x + \frac{-1}{\frac{\color{blue}{x \cdot y + \left(z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)}}{y}} \]
                    2. lower-fma.f64N/A

                      \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(x, y, z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right)}}{y}} \]
                    3. sub-negN/A

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

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \color{blue}{\left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) \cdot z} + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right)\right)}{y}} \]
                    5. metadata-evalN/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) \cdot z + \color{blue}{\frac{-5641895835477563}{5000000000000000}}\right)}{y}} \]
                    6. lower-fma.f64N/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \color{blue}{\mathsf{fma}\left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}, z, \frac{-5641895835477563}{5000000000000000}\right)}\right)}{y}} \]
                    7. sub-negN/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right)}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                    8. *-commutativeN/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) \cdot z} + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                    9. metadata-evalN/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) \cdot z + \color{blue}{\frac{-5641895835477563}{5000000000000000}}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                    10. lower-fma.f64N/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}, z, \frac{-5641895835477563}{5000000000000000}\right)}, z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                    11. sub-negN/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\frac{-5641895835477563}{30000000000000000} \cdot z + \left(\mathsf{neg}\left(\frac{5641895835477563}{10000000000000000}\right)\right)}, z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                    12. metadata-evalN/A

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000} \cdot z + \color{blue}{\frac{-5641895835477563}{10000000000000000}}, z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)\right)}{y}} \]
                    13. lower-fma.f6480.7

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right)}, z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}{y}} \]
                  7. Applied rewrites80.7%

                    \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(x, y, \mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)\right)}}{y}} \]
                  8. Taylor expanded in x around 0

                    \[\leadsto x + \frac{-1}{\frac{z \cdot \left(z \cdot \left(\frac{-5641895835477563}{30000000000000000} \cdot z - \frac{5641895835477563}{10000000000000000}\right) - \frac{5641895835477563}{5000000000000000}\right) - \color{blue}{\frac{5641895835477563}{5000000000000000}}}{y}} \]
                  9. Step-by-step derivation
                    1. Applied rewrites80.8%

                      \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(-0.18806319451591877, z, -0.5641895835477563\right), z, -1.1283791670955126\right), \color{blue}{z}, -1.1283791670955126\right)}{y}} \]
                    2. Step-by-step derivation
                      1. lift-+.f64N/A

                        \[\leadsto \color{blue}{x + \frac{-1}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)}{y}}} \]
                      2. lift-/.f64N/A

                        \[\leadsto x + \color{blue}{\frac{-1}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)}{y}}} \]
                      3. div-invN/A

                        \[\leadsto x + \color{blue}{-1 \cdot \frac{1}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)}{y}}} \]
                      4. lift-/.f64N/A

                        \[\leadsto x + -1 \cdot \frac{1}{\color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)}{y}}} \]
                      5. clear-num-revN/A

                        \[\leadsto x + -1 \cdot \color{blue}{\frac{y}{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\frac{-5641895835477563}{30000000000000000}, z, \frac{-5641895835477563}{10000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right), z, \frac{-5641895835477563}{5000000000000000}\right)}} \]
                    3. Applied rewrites80.8%

                      \[\leadsto \color{blue}{x - \frac{y}{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(z, -0.18806319451591877, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)}} \]
                  10. Recombined 3 regimes into one program.
                  11. Final simplification95.2%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -17000000:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{elif}\;z \leq 1.25 \cdot 10^{+14}:\\ \;\;\;\;\frac{y - y \cdot z}{\mathsf{fma}\left(-x, y, 1.1283791670955126\right)} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(z, -0.18806319451591877, -0.5641895835477563\right), z, -1.1283791670955126\right), z, -1.1283791670955126\right)}\\ \end{array} \]
                  12. Add Preprocessing

                  Alternative 11: 93.6% accurate, 3.1× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -17000000:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{elif}\;z \leq 0.37:\\ \;\;\;\;\frac{-1}{x - \frac{1.1283791670955126}{y}} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot z}\\ \end{array} \end{array} \]
                  (FPCore (x y z)
                   :precision binary64
                   (if (<= z -17000000.0)
                     (+ (/ -1.0 x) x)
                     (if (<= z 0.37)
                       (+ (/ -1.0 (- x (/ 1.1283791670955126 y))) x)
                       (- x (/ y (- (* y x) (* 1.1283791670955126 z)))))))
                  double code(double x, double y, double z) {
                  	double tmp;
                  	if (z <= -17000000.0) {
                  		tmp = (-1.0 / x) + x;
                  	} else if (z <= 0.37) {
                  		tmp = (-1.0 / (x - (1.1283791670955126 / y))) + x;
                  	} else {
                  		tmp = x - (y / ((y * x) - (1.1283791670955126 * z)));
                  	}
                  	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 (z <= (-17000000.0d0)) then
                          tmp = ((-1.0d0) / x) + x
                      else if (z <= 0.37d0) then
                          tmp = ((-1.0d0) / (x - (1.1283791670955126d0 / y))) + x
                      else
                          tmp = x - (y / ((y * x) - (1.1283791670955126d0 * z)))
                      end if
                      code = tmp
                  end function
                  
                  public static double code(double x, double y, double z) {
                  	double tmp;
                  	if (z <= -17000000.0) {
                  		tmp = (-1.0 / x) + x;
                  	} else if (z <= 0.37) {
                  		tmp = (-1.0 / (x - (1.1283791670955126 / y))) + x;
                  	} else {
                  		tmp = x - (y / ((y * x) - (1.1283791670955126 * z)));
                  	}
                  	return tmp;
                  }
                  
                  def code(x, y, z):
                  	tmp = 0
                  	if z <= -17000000.0:
                  		tmp = (-1.0 / x) + x
                  	elif z <= 0.37:
                  		tmp = (-1.0 / (x - (1.1283791670955126 / y))) + x
                  	else:
                  		tmp = x - (y / ((y * x) - (1.1283791670955126 * z)))
                  	return tmp
                  
                  function code(x, y, z)
                  	tmp = 0.0
                  	if (z <= -17000000.0)
                  		tmp = Float64(Float64(-1.0 / x) + x);
                  	elseif (z <= 0.37)
                  		tmp = Float64(Float64(-1.0 / Float64(x - Float64(1.1283791670955126 / y))) + x);
                  	else
                  		tmp = Float64(x - Float64(y / Float64(Float64(y * x) - Float64(1.1283791670955126 * z))));
                  	end
                  	return tmp
                  end
                  
                  function tmp_2 = code(x, y, z)
                  	tmp = 0.0;
                  	if (z <= -17000000.0)
                  		tmp = (-1.0 / x) + x;
                  	elseif (z <= 0.37)
                  		tmp = (-1.0 / (x - (1.1283791670955126 / y))) + x;
                  	else
                  		tmp = x - (y / ((y * x) - (1.1283791670955126 * z)));
                  	end
                  	tmp_2 = tmp;
                  end
                  
                  code[x_, y_, z_] := If[LessEqual[z, -17000000.0], N[(N[(-1.0 / x), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[z, 0.37], N[(N[(-1.0 / N[(x - N[(1.1283791670955126 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], N[(x - N[(y / N[(N[(y * x), $MachinePrecision] - N[(1.1283791670955126 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  \mathbf{if}\;z \leq -17000000:\\
                  \;\;\;\;\frac{-1}{x} + x\\
                  
                  \mathbf{elif}\;z \leq 0.37:\\
                  \;\;\;\;\frac{-1}{x - \frac{1.1283791670955126}{y}} + x\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot z}\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 3 regimes
                  2. if z < -1.7e7

                    1. Initial program 89.0%

                      \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                    2. Add Preprocessing
                    3. Taylor expanded in x around inf

                      \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
                    4. Step-by-step derivation
                      1. lower-/.f64100.0

                        \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
                    5. Applied rewrites100.0%

                      \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

                    if -1.7e7 < z < 0.37

                    1. Initial program 99.9%

                      \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. lift-/.f64N/A

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

                        \[\leadsto x + \color{blue}{\frac{1}{\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}}} \]
                      3. frac-2negN/A

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

                        \[\leadsto x + \frac{\color{blue}{-1}}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)} \]
                      5. lower-/.f64N/A

                        \[\leadsto x + \color{blue}{\frac{-1}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)}} \]
                      6. distribute-neg-fracN/A

                        \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
                      7. lower-/.f64N/A

                        \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
                      8. lift--.f64N/A

                        \[\leadsto x + \frac{-1}{\frac{\mathsf{neg}\left(\color{blue}{\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)}\right)}{y}} \]
                      9. sub-negN/A

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

                        \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z}\right)\right) + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}}{y}} \]
                      11. lift-*.f64N/A

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

                        \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z}} + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}{y}} \]
                      13. remove-double-negN/A

                        \[\leadsto x + \frac{-1}{\frac{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z} + \color{blue}{x \cdot y}}{y}} \]
                      14. lower-fma.f64N/A

                        \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right), e^{z}, x \cdot y\right)}}{y}} \]
                      15. metadata-eval99.8

                        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\color{blue}{-1.1283791670955126}, e^{z}, x \cdot y\right)}{y}} \]
                      16. lift-*.f64N/A

                        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{x \cdot y}\right)}{y}} \]
                      17. *-commutativeN/A

                        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
                      18. lower-*.f6499.8

                        \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(-1.1283791670955126, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
                    4. Applied rewrites99.8%

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

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

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

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

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

                        \[\leadsto x + \frac{-1}{\color{blue}{\mathsf{fma}\left(\frac{z}{y}, \frac{-5641895835477563}{5000000000000000}, x\right)} - \frac{5641895835477563}{5000000000000000} \cdot \frac{1}{y}} \]
                      5. lower-/.f64N/A

                        \[\leadsto x + \frac{-1}{\mathsf{fma}\left(\color{blue}{\frac{z}{y}}, \frac{-5641895835477563}{5000000000000000}, x\right) - \frac{5641895835477563}{5000000000000000} \cdot \frac{1}{y}} \]
                      6. associate-*r/N/A

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

                        \[\leadsto x + \frac{-1}{\mathsf{fma}\left(\frac{z}{y}, \frac{-5641895835477563}{5000000000000000}, x\right) - \frac{\color{blue}{\frac{5641895835477563}{5000000000000000}}}{y}} \]
                      8. lower-/.f6499.9

                        \[\leadsto x + \frac{-1}{\mathsf{fma}\left(\frac{z}{y}, -1.1283791670955126, x\right) - \color{blue}{\frac{1.1283791670955126}{y}}} \]
                    7. Applied rewrites99.9%

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

                      \[\leadsto x + \frac{-1}{x - \color{blue}{\frac{5641895835477563}{5000000000000000} \cdot \frac{1}{y}}} \]
                    9. Step-by-step derivation
                      1. Applied rewrites99.4%

                        \[\leadsto x + \frac{-1}{x - \color{blue}{\frac{1.1283791670955126}{y}}} \]

                      if 0.37 < z

                      1. Initial program 95.5%

                        \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                      2. Add Preprocessing
                      3. Taylor expanded in z around 0

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

                          \[\leadsto x + \frac{y}{\color{blue}{\left(\frac{5641895835477563}{5000000000000000} \cdot z + \frac{5641895835477563}{5000000000000000}\right)} - x \cdot y} \]
                        2. lower-fma.f6472.1

                          \[\leadsto x + \frac{y}{\color{blue}{\mathsf{fma}\left(1.1283791670955126, z, 1.1283791670955126\right)} - x \cdot y} \]
                      5. Applied rewrites72.1%

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

                        \[\leadsto x + \frac{y}{\frac{5641895835477563}{5000000000000000} \cdot \color{blue}{z} - x \cdot y} \]
                      7. Step-by-step derivation
                        1. Applied rewrites72.1%

                          \[\leadsto x + \frac{y}{1.1283791670955126 \cdot \color{blue}{z} - x \cdot y} \]
                      8. Recombined 3 regimes into one program.
                      9. Final simplification92.5%

                        \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -17000000:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{elif}\;z \leq 0.37:\\ \;\;\;\;\frac{-1}{x - \frac{1.1283791670955126}{y}} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{y \cdot x - 1.1283791670955126 \cdot z}\\ \end{array} \]
                      10. Add Preprocessing

                      Alternative 12: 93.7% accurate, 3.7× speedup?

                      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -17000000:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{y \cdot x - \mathsf{fma}\left(1.1283791670955126, z, 1.1283791670955126\right)}\\ \end{array} \end{array} \]
                      (FPCore (x y z)
                       :precision binary64
                       (if (<= z -17000000.0)
                         (+ (/ -1.0 x) x)
                         (- x (/ y (- (* y x) (fma 1.1283791670955126 z 1.1283791670955126))))))
                      double code(double x, double y, double z) {
                      	double tmp;
                      	if (z <= -17000000.0) {
                      		tmp = (-1.0 / x) + x;
                      	} else {
                      		tmp = x - (y / ((y * x) - fma(1.1283791670955126, z, 1.1283791670955126)));
                      	}
                      	return tmp;
                      }
                      
                      function code(x, y, z)
                      	tmp = 0.0
                      	if (z <= -17000000.0)
                      		tmp = Float64(Float64(-1.0 / x) + x);
                      	else
                      		tmp = Float64(x - Float64(y / Float64(Float64(y * x) - fma(1.1283791670955126, z, 1.1283791670955126))));
                      	end
                      	return tmp
                      end
                      
                      code[x_, y_, z_] := If[LessEqual[z, -17000000.0], N[(N[(-1.0 / x), $MachinePrecision] + x), $MachinePrecision], N[(x - N[(y / N[(N[(y * x), $MachinePrecision] - N[(1.1283791670955126 * z + 1.1283791670955126), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
                      
                      \begin{array}{l}
                      
                      \\
                      \begin{array}{l}
                      \mathbf{if}\;z \leq -17000000:\\
                      \;\;\;\;\frac{-1}{x} + x\\
                      
                      \mathbf{else}:\\
                      \;\;\;\;x - \frac{y}{y \cdot x - \mathsf{fma}\left(1.1283791670955126, z, 1.1283791670955126\right)}\\
                      
                      
                      \end{array}
                      \end{array}
                      
                      Derivation
                      1. Split input into 2 regimes
                      2. if z < -1.7e7

                        1. Initial program 89.0%

                          \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                        2. Add Preprocessing
                        3. Taylor expanded in x around inf

                          \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
                        4. Step-by-step derivation
                          1. lower-/.f64100.0

                            \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
                        5. Applied rewrites100.0%

                          \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

                        if -1.7e7 < z

                        1. Initial program 98.3%

                          \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                        2. Add Preprocessing
                        3. Taylor expanded in z around 0

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

                            \[\leadsto x + \frac{y}{\color{blue}{\left(\frac{5641895835477563}{5000000000000000} \cdot z + \frac{5641895835477563}{5000000000000000}\right)} - x \cdot y} \]
                          2. lower-fma.f6490.0

                            \[\leadsto x + \frac{y}{\color{blue}{\mathsf{fma}\left(1.1283791670955126, z, 1.1283791670955126\right)} - x \cdot y} \]
                        5. Applied rewrites90.0%

                          \[\leadsto x + \frac{y}{\color{blue}{\mathsf{fma}\left(1.1283791670955126, z, 1.1283791670955126\right)} - x \cdot y} \]
                      3. Recombined 2 regimes into one program.
                      4. Final simplification92.7%

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

                      Alternative 13: 90.5% accurate, 4.7× speedup?

                      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -17000000:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{\mathsf{fma}\left(x, y, -1.1283791670955126\right)}\\ \end{array} \end{array} \]
                      (FPCore (x y z)
                       :precision binary64
                       (if (<= z -17000000.0)
                         (+ (/ -1.0 x) x)
                         (- x (/ y (fma x y -1.1283791670955126)))))
                      double code(double x, double y, double z) {
                      	double tmp;
                      	if (z <= -17000000.0) {
                      		tmp = (-1.0 / x) + x;
                      	} else {
                      		tmp = x - (y / fma(x, y, -1.1283791670955126));
                      	}
                      	return tmp;
                      }
                      
                      function code(x, y, z)
                      	tmp = 0.0
                      	if (z <= -17000000.0)
                      		tmp = Float64(Float64(-1.0 / x) + x);
                      	else
                      		tmp = Float64(x - Float64(y / fma(x, y, -1.1283791670955126)));
                      	end
                      	return tmp
                      end
                      
                      code[x_, y_, z_] := If[LessEqual[z, -17000000.0], N[(N[(-1.0 / x), $MachinePrecision] + x), $MachinePrecision], N[(x - N[(y / N[(x * y + -1.1283791670955126), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
                      
                      \begin{array}{l}
                      
                      \\
                      \begin{array}{l}
                      \mathbf{if}\;z \leq -17000000:\\
                      \;\;\;\;\frac{-1}{x} + x\\
                      
                      \mathbf{else}:\\
                      \;\;\;\;x - \frac{y}{\mathsf{fma}\left(x, y, -1.1283791670955126\right)}\\
                      
                      
                      \end{array}
                      \end{array}
                      
                      Derivation
                      1. Split input into 2 regimes
                      2. if z < -1.7e7

                        1. Initial program 89.0%

                          \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                        2. Add Preprocessing
                        3. Taylor expanded in x around inf

                          \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
                        4. Step-by-step derivation
                          1. lower-/.f64100.0

                            \[\leadsto x + \color{blue}{\frac{-1}{x}} \]
                        5. Applied rewrites100.0%

                          \[\leadsto x + \color{blue}{\frac{-1}{x}} \]

                        if -1.7e7 < z

                        1. Initial program 98.3%

                          \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                        2. Add Preprocessing
                        3. Step-by-step derivation
                          1. lift-/.f64N/A

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

                            \[\leadsto x + \color{blue}{\frac{1}{\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}}} \]
                          3. frac-2negN/A

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

                            \[\leadsto x + \frac{\color{blue}{-1}}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)} \]
                          5. lower-/.f64N/A

                            \[\leadsto x + \color{blue}{\frac{-1}{\mathsf{neg}\left(\frac{\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y}{y}\right)}} \]
                          6. distribute-neg-fracN/A

                            \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
                          7. lower-/.f64N/A

                            \[\leadsto x + \frac{-1}{\color{blue}{\frac{\mathsf{neg}\left(\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)\right)}{y}}} \]
                          8. lift--.f64N/A

                            \[\leadsto x + \frac{-1}{\frac{\mathsf{neg}\left(\color{blue}{\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z} - x \cdot y\right)}\right)}{y}} \]
                          9. sub-negN/A

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

                            \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000} \cdot e^{z}\right)\right) + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}}{y}} \]
                          11. lift-*.f64N/A

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

                            \[\leadsto x + \frac{-1}{\frac{\color{blue}{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z}} + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(x \cdot y\right)\right)\right)\right)}{y}} \]
                          13. remove-double-negN/A

                            \[\leadsto x + \frac{-1}{\frac{\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right) \cdot e^{z} + \color{blue}{x \cdot y}}{y}} \]
                          14. lower-fma.f64N/A

                            \[\leadsto x + \frac{-1}{\frac{\color{blue}{\mathsf{fma}\left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right), e^{z}, x \cdot y\right)}}{y}} \]
                          15. metadata-eval98.3

                            \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\color{blue}{-1.1283791670955126}, e^{z}, x \cdot y\right)}{y}} \]
                          16. lift-*.f64N/A

                            \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{x \cdot y}\right)}{y}} \]
                          17. *-commutativeN/A

                            \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(\frac{-5641895835477563}{5000000000000000}, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
                          18. lower-*.f6498.3

                            \[\leadsto x + \frac{-1}{\frac{\mathsf{fma}\left(-1.1283791670955126, e^{z}, \color{blue}{y \cdot x}\right)}{y}} \]
                        4. Applied rewrites98.3%

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

                          \[\leadsto \color{blue}{x + -1 \cdot \frac{y}{x \cdot y - \frac{5641895835477563}{5000000000000000}}} \]
                        6. Step-by-step derivation
                          1. mul-1-negN/A

                            \[\leadsto x + \color{blue}{\left(\mathsf{neg}\left(\frac{y}{x \cdot y - \frac{5641895835477563}{5000000000000000}}\right)\right)} \]
                          2. unsub-negN/A

                            \[\leadsto \color{blue}{x - \frac{y}{x \cdot y - \frac{5641895835477563}{5000000000000000}}} \]
                          3. lower--.f64N/A

                            \[\leadsto \color{blue}{x - \frac{y}{x \cdot y - \frac{5641895835477563}{5000000000000000}}} \]
                          4. lower-/.f64N/A

                            \[\leadsto x - \color{blue}{\frac{y}{x \cdot y - \frac{5641895835477563}{5000000000000000}}} \]
                          5. sub-negN/A

                            \[\leadsto x - \frac{y}{\color{blue}{x \cdot y + \left(\mathsf{neg}\left(\frac{5641895835477563}{5000000000000000}\right)\right)}} \]
                          6. metadata-evalN/A

                            \[\leadsto x - \frac{y}{x \cdot y + \color{blue}{\frac{-5641895835477563}{5000000000000000}}} \]
                          7. lower-fma.f6485.6

                            \[\leadsto x - \frac{y}{\color{blue}{\mathsf{fma}\left(x, y, -1.1283791670955126\right)}} \]
                        7. Applied rewrites85.6%

                          \[\leadsto \color{blue}{x - \frac{y}{\mathsf{fma}\left(x, y, -1.1283791670955126\right)}} \]
                      3. Recombined 2 regimes into one program.
                      4. Final simplification89.5%

                        \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -17000000:\\ \;\;\;\;\frac{-1}{x} + x\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{\mathsf{fma}\left(x, y, -1.1283791670955126\right)}\\ \end{array} \]
                      5. Add Preprocessing

                      Alternative 14: 59.2% accurate, 14.2× speedup?

                      \[\begin{array}{l} \\ 0.8862269254527579 \cdot y + x \end{array} \]
                      (FPCore (x y z) :precision binary64 (+ (* 0.8862269254527579 y) x))
                      double code(double x, double y, double z) {
                      	return (0.8862269254527579 * y) + x;
                      }
                      
                      real(8) function code(x, y, z)
                          real(8), intent (in) :: x
                          real(8), intent (in) :: y
                          real(8), intent (in) :: z
                          code = (0.8862269254527579d0 * y) + x
                      end function
                      
                      public static double code(double x, double y, double z) {
                      	return (0.8862269254527579 * y) + x;
                      }
                      
                      def code(x, y, z):
                      	return (0.8862269254527579 * y) + x
                      
                      function code(x, y, z)
                      	return Float64(Float64(0.8862269254527579 * y) + x)
                      end
                      
                      function tmp = code(x, y, z)
                      	tmp = (0.8862269254527579 * y) + x;
                      end
                      
                      code[x_, y_, z_] := N[(N[(0.8862269254527579 * y), $MachinePrecision] + x), $MachinePrecision]
                      
                      \begin{array}{l}
                      
                      \\
                      0.8862269254527579 \cdot y + x
                      \end{array}
                      
                      Derivation
                      1. Initial program 95.8%

                        \[x + \frac{y}{1.1283791670955126 \cdot e^{z} - x \cdot y} \]
                      2. Add Preprocessing
                      3. Taylor expanded in z around 0

                        \[\leadsto x + \color{blue}{\left(\frac{-5641895835477563}{5000000000000000} \cdot \frac{y \cdot z}{{\left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right)}^{2}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right)} \]
                      4. Step-by-step derivation
                        1. associate-*r/N/A

                          \[\leadsto x + \left(\color{blue}{\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{{\left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right)}^{2}}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right) \]
                        2. unpow2N/A

                          \[\leadsto x + \left(\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{\color{blue}{\left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right) \cdot \left(\frac{5641895835477563}{5000000000000000} - x \cdot y\right)}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right) \]
                        3. associate-/r*N/A

                          \[\leadsto x + \left(\color{blue}{\frac{\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{\frac{5641895835477563}{5000000000000000} - x \cdot y}}{\frac{5641895835477563}{5000000000000000} - x \cdot y}} + \frac{y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}\right) \]
                        4. div-add-revN/A

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

                          \[\leadsto x + \color{blue}{\frac{\frac{\frac{-5641895835477563}{5000000000000000} \cdot \left(y \cdot z\right)}{\frac{5641895835477563}{5000000000000000} - x \cdot y} + y}{\frac{5641895835477563}{5000000000000000} - x \cdot y}} \]
                      5. Applied rewrites66.1%

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

                        \[\leadsto x + \frac{5000000000000000}{5641895835477563} \cdot \color{blue}{\left(y + -1 \cdot \left(y \cdot z\right)\right)} \]
                      7. Step-by-step derivation
                        1. Applied rewrites46.7%

                          \[\leadsto x + \left(y - y \cdot z\right) \cdot \color{blue}{0.8862269254527579} \]
                        2. Taylor expanded in z around 0

                          \[\leadsto x + \frac{5000000000000000}{5641895835477563} \cdot y \]
                        3. Step-by-step derivation
                          1. Applied rewrites53.1%

                            \[\leadsto x + 0.8862269254527579 \cdot y \]
                          2. Final simplification53.1%

                            \[\leadsto 0.8862269254527579 \cdot y + x \]
                          3. Add Preprocessing

                          Developer Target 1: 99.9% accurate, 1.0× speedup?

                          \[\begin{array}{l} \\ x + \frac{1}{\frac{1.1283791670955126}{y} \cdot e^{z} - x} \end{array} \]
                          (FPCore (x y z)
                           :precision binary64
                           (+ x (/ 1.0 (- (* (/ 1.1283791670955126 y) (exp z)) x))))
                          double code(double x, double y, double z) {
                          	return x + (1.0 / (((1.1283791670955126 / y) * exp(z)) - x));
                          }
                          
                          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 / (((1.1283791670955126d0 / y) * exp(z)) - x))
                          end function
                          
                          public static double code(double x, double y, double z) {
                          	return x + (1.0 / (((1.1283791670955126 / y) * Math.exp(z)) - x));
                          }
                          
                          def code(x, y, z):
                          	return x + (1.0 / (((1.1283791670955126 / y) * math.exp(z)) - x))
                          
                          function code(x, y, z)
                          	return Float64(x + Float64(1.0 / Float64(Float64(Float64(1.1283791670955126 / y) * exp(z)) - x)))
                          end
                          
                          function tmp = code(x, y, z)
                          	tmp = x + (1.0 / (((1.1283791670955126 / y) * exp(z)) - x));
                          end
                          
                          code[x_, y_, z_] := N[(x + N[(1.0 / N[(N[(N[(1.1283791670955126 / y), $MachinePrecision] * N[Exp[z], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                          
                          \begin{array}{l}
                          
                          \\
                          x + \frac{1}{\frac{1.1283791670955126}{y} \cdot e^{z} - x}
                          \end{array}
                          

                          Reproduce

                          ?
                          herbie shell --seed 2024298 
                          (FPCore (x y z)
                            :name "Numeric.SpecFunctions:invErfc from math-functions-0.1.5.2, A"
                            :precision binary64
                          
                            :alt
                            (! :herbie-platform default (+ x (/ 1 (- (* (/ 5641895835477563/5000000000000000 y) (exp z)) x))))
                          
                            (+ x (/ y (- (* 1.1283791670955126 (exp z)) (* x y)))))