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

Percentage Accurate: 69.3% → 99.8%
Time: 11.8s
Alternatives: 21
Speedup: 1.4×

Specification

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

\\
\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}
\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 21 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: 69.3% accurate, 1.0× speedup?

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

\\
\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}
\end{array}

Alternative 1: 99.8% accurate, 1.0× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \frac{x \cdot \frac{\frac{y}{y + x}}{y + \left(x + 1\right)}}{y + x} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
(FPCore (x y)
 :precision binary64
 (/ (* x (/ (/ y (+ y x)) (+ y (+ x 1.0)))) (+ y x)))
assert(x < y);
double code(double x, double y) {
	return (x * ((y / (y + x)) / (y + (x + 1.0)))) / (y + x);
}
NOTE: x and y should be sorted in increasing order before calling this function.
real(8) function code(x, y)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    code = (x * ((y / (y + x)) / (y + (x + 1.0d0)))) / (y + x)
end function
assert x < y;
public static double code(double x, double y) {
	return (x * ((y / (y + x)) / (y + (x + 1.0)))) / (y + x);
}
[x, y] = sort([x, y])
def code(x, y):
	return (x * ((y / (y + x)) / (y + (x + 1.0)))) / (y + x)
x, y = sort([x, y])
function code(x, y)
	return Float64(Float64(x * Float64(Float64(y / Float64(y + x)) / Float64(y + Float64(x + 1.0)))) / Float64(y + x))
end
x, y = num2cell(sort([x, y])){:}
function tmp = code(x, y)
	tmp = (x * ((y / (y + x)) / (y + (x + 1.0)))) / (y + x);
end
NOTE: x and y should be sorted in increasing order before calling this function.
code[x_, y_] := N[(N[(x * N[(N[(y / N[(y + x), $MachinePrecision]), $MachinePrecision] / N[(y + N[(x + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
\\
\frac{x \cdot \frac{\frac{y}{y + x}}{y + \left(x + 1\right)}}{y + x}
\end{array}
Derivation
  1. Initial program 71.5%

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

      \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
    2. *-lowering-*.f64N/A

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

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
    4. *-lowering-*.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
    5. +-lowering-+.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
    6. *-lowering-*.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
    7. +-lowering-+.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
    8. associate-+l+N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
    9. +-lowering-+.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
    10. +-lowering-+.f6471.5%

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
  3. Simplified71.5%

    \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
  4. Add Preprocessing
  5. Step-by-step derivation
    1. associate-/r*N/A

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

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

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

      \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
    5. /-lowering-/.f64N/A

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

      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
    7. *-lowering-*.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
    8. /-lowering-/.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
    9. +-lowering-+.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
    10. associate-+r+N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
    11. +-lowering-+.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
    12. +-lowering-+.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
    13. +-lowering-+.f6499.9%

      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
  6. Applied egg-rr99.9%

    \[\leadsto \color{blue}{\frac{\frac{x \cdot \frac{y}{x + y}}{\left(x + y\right) + 1}}{x + y}} \]
  7. Step-by-step derivation
    1. associate-/l*N/A

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

      \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{y}{x + y}}{\left(x + y\right) + 1} \cdot x\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
    3. *-lowering-*.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{y}{x + y}}{\left(x + y\right) + 1}\right), x\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
    4. /-lowering-/.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{y}{x + y}\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
    5. /-lowering-/.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(x + y\right)\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
    6. +-lowering-+.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
    7. +-commutativeN/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(\left(y + x\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
    8. associate-+l+N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(y + \left(x + 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
    9. +-lowering-+.f64N/A

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \left(x + 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
    10. +-lowering-+.f6499.9%

      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
  8. Applied egg-rr99.9%

    \[\leadsto \frac{\color{blue}{\frac{\frac{y}{x + y}}{y + \left(x + 1\right)} \cdot x}}{x + y} \]
  9. Final simplification99.9%

    \[\leadsto \frac{x \cdot \frac{\frac{y}{y + x}}{y + \left(x + 1\right)}}{y + x} \]
  10. Add Preprocessing

Alternative 2: 90.7% accurate, 0.7× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} t_0 := \frac{y}{y + x}\\ \mathbf{if}\;y \leq 3.5 \cdot 10^{-143}:\\ \;\;\;\;\frac{\frac{y}{\left(y + x\right) + 1}}{y + x}\\ \mathbf{elif}\;y \leq 5.5 \cdot 10^{-9}:\\ \;\;\;\;\frac{x \cdot t\_0}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot \frac{t\_0}{y + x}}{y + x}\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
(FPCore (x y)
 :precision binary64
 (let* ((t_0 (/ y (+ y x))))
   (if (<= y 3.5e-143)
     (/ (/ y (+ (+ y x) 1.0)) (+ y x))
     (if (<= y 5.5e-9)
       (/ (* x t_0) (+ y x))
       (/ (* x (/ t_0 (+ y x))) (+ y x))))))
assert(x < y);
double code(double x, double y) {
	double t_0 = y / (y + x);
	double tmp;
	if (y <= 3.5e-143) {
		tmp = (y / ((y + x) + 1.0)) / (y + x);
	} else if (y <= 5.5e-9) {
		tmp = (x * t_0) / (y + x);
	} else {
		tmp = (x * (t_0 / (y + x))) / (y + x);
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
real(8) function code(x, y)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8) :: t_0
    real(8) :: tmp
    t_0 = y / (y + x)
    if (y <= 3.5d-143) then
        tmp = (y / ((y + x) + 1.0d0)) / (y + x)
    else if (y <= 5.5d-9) then
        tmp = (x * t_0) / (y + x)
    else
        tmp = (x * (t_0 / (y + x))) / (y + x)
    end if
    code = tmp
end function
assert x < y;
public static double code(double x, double y) {
	double t_0 = y / (y + x);
	double tmp;
	if (y <= 3.5e-143) {
		tmp = (y / ((y + x) + 1.0)) / (y + x);
	} else if (y <= 5.5e-9) {
		tmp = (x * t_0) / (y + x);
	} else {
		tmp = (x * (t_0 / (y + x))) / (y + x);
	}
	return tmp;
}
[x, y] = sort([x, y])
def code(x, y):
	t_0 = y / (y + x)
	tmp = 0
	if y <= 3.5e-143:
		tmp = (y / ((y + x) + 1.0)) / (y + x)
	elif y <= 5.5e-9:
		tmp = (x * t_0) / (y + x)
	else:
		tmp = (x * (t_0 / (y + x))) / (y + x)
	return tmp
x, y = sort([x, y])
function code(x, y)
	t_0 = Float64(y / Float64(y + x))
	tmp = 0.0
	if (y <= 3.5e-143)
		tmp = Float64(Float64(y / Float64(Float64(y + x) + 1.0)) / Float64(y + x));
	elseif (y <= 5.5e-9)
		tmp = Float64(Float64(x * t_0) / Float64(y + x));
	else
		tmp = Float64(Float64(x * Float64(t_0 / Float64(y + x))) / Float64(y + x));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
function tmp_2 = code(x, y)
	t_0 = y / (y + x);
	tmp = 0.0;
	if (y <= 3.5e-143)
		tmp = (y / ((y + x) + 1.0)) / (y + x);
	elseif (y <= 5.5e-9)
		tmp = (x * t_0) / (y + x);
	else
		tmp = (x * (t_0 / (y + x))) / (y + x);
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
code[x_, y_] := Block[{t$95$0 = N[(y / N[(y + x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 3.5e-143], N[(N[(y / N[(N[(y + x), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 5.5e-9], N[(N[(x * t$95$0), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(t$95$0 / N[(y + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
\\
\begin{array}{l}
t_0 := \frac{y}{y + x}\\
\mathbf{if}\;y \leq 3.5 \cdot 10^{-143}:\\
\;\;\;\;\frac{\frac{y}{\left(y + x\right) + 1}}{y + x}\\

\mathbf{elif}\;y \leq 5.5 \cdot 10^{-9}:\\
\;\;\;\;\frac{x \cdot t\_0}{y + x}\\

\mathbf{else}:\\
\;\;\;\;\frac{x \cdot \frac{t\_0}{y + x}}{y + x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < 3.50000000000000005e-143

    1. Initial program 72.6%

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

        \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
      2. *-lowering-*.f64N/A

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

        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
      5. +-lowering-+.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
      6. *-lowering-*.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
      7. +-lowering-+.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
      8. associate-+l+N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
      9. +-lowering-+.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
      10. +-lowering-+.f6472.6%

        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
    3. Simplified72.6%

      \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-/r*N/A

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

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

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

        \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
      5. /-lowering-/.f64N/A

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

        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
      7. *-lowering-*.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
      8. /-lowering-/.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
      9. +-lowering-+.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
      10. associate-+r+N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
      11. +-lowering-+.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
      12. +-lowering-+.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
      13. +-lowering-+.f6499.9%

        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
    6. Applied egg-rr99.9%

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

      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\color{blue}{y}, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
    8. Step-by-step derivation
      1. Simplified61.4%

        \[\leadsto \frac{\frac{\color{blue}{y}}{\left(x + y\right) + 1}}{x + y} \]

      if 3.50000000000000005e-143 < y < 5.4999999999999996e-9

      1. Initial program 88.1%

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

          \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
        2. *-lowering-*.f64N/A

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

          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
        5. +-lowering-+.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
        6. *-lowering-*.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
        7. +-lowering-+.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
        8. associate-+l+N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
        9. +-lowering-+.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
        10. +-lowering-+.f6488.1%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
      3. Simplified88.1%

        \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
      4. Add Preprocessing
      5. Step-by-step derivation
        1. associate-/r*N/A

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

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

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

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
        5. /-lowering-/.f64N/A

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

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
        7. *-lowering-*.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
        8. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
        9. +-lowering-+.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
        10. associate-+r+N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
        11. +-lowering-+.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
        12. +-lowering-+.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
        13. +-lowering-+.f6499.9%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
      6. Applied egg-rr99.9%

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

        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\color{blue}{y}, 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
      8. Step-by-step derivation
        1. Simplified77.1%

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

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \color{blue}{1}\right), \mathsf{+.f64}\left(x, y\right)\right) \]
        3. Step-by-step derivation
          1. Simplified77.1%

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

          if 5.4999999999999996e-9 < y

          1. Initial program 61.8%

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

              \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
            2. *-lowering-*.f64N/A

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

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
            4. *-lowering-*.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
            5. +-lowering-+.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
            6. *-lowering-*.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
            7. +-lowering-+.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
            8. associate-+l+N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
            9. +-lowering-+.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
            10. +-lowering-+.f6461.8%

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
          3. Simplified61.8%

            \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
          4. Add Preprocessing
          5. Step-by-step derivation
            1. associate-/r*N/A

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

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

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

              \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
            5. /-lowering-/.f64N/A

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

              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
            7. *-lowering-*.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
            8. /-lowering-/.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
            9. +-lowering-+.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
            10. associate-+r+N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
            11. +-lowering-+.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
            12. +-lowering-+.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
            13. +-lowering-+.f6499.8%

              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
          6. Applied egg-rr99.8%

            \[\leadsto \color{blue}{\frac{\frac{x \cdot \frac{y}{x + y}}{\left(x + y\right) + 1}}{x + y}} \]
          7. Step-by-step derivation
            1. associate-/l*N/A

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

              \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{y}{x + y}}{\left(x + y\right) + 1} \cdot x\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
            3. *-lowering-*.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{y}{x + y}}{\left(x + y\right) + 1}\right), x\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
            4. /-lowering-/.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{y}{x + y}\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
            5. /-lowering-/.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(x + y\right)\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
            6. +-lowering-+.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
            7. +-commutativeN/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(\left(y + x\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
            8. associate-+l+N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(y + \left(x + 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
            9. +-lowering-+.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \left(x + 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
            10. +-lowering-+.f6499.9%

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
          8. Applied egg-rr99.9%

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

            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \color{blue}{x}\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
          10. Step-by-step derivation
            1. Simplified98.6%

              \[\leadsto \frac{\frac{\frac{y}{x + y}}{y + \color{blue}{x}} \cdot x}{x + y} \]
          11. Recombined 3 regimes into one program.
          12. Final simplification73.4%

            \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 3.5 \cdot 10^{-143}:\\ \;\;\;\;\frac{\frac{y}{\left(y + x\right) + 1}}{y + x}\\ \mathbf{elif}\;y \leq 5.5 \cdot 10^{-9}:\\ \;\;\;\;\frac{x \cdot \frac{y}{y + x}}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot \frac{\frac{y}{y + x}}{y + x}}{y + x}\\ \end{array} \]
          13. Add Preprocessing

          Alternative 3: 85.3% accurate, 0.7× speedup?

          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 5.2 \cdot 10^{-143}:\\ \;\;\;\;\frac{\frac{y}{\left(y + x\right) + 1}}{y + x}\\ \mathbf{elif}\;y \leq 3 \cdot 10^{-15}:\\ \;\;\;\;\frac{x \cdot \frac{y}{y + x}}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot \frac{1}{y + \left(x + 1\right)}}{y + x}\\ \end{array} \end{array} \]
          NOTE: x and y should be sorted in increasing order before calling this function.
          (FPCore (x y)
           :precision binary64
           (if (<= y 5.2e-143)
             (/ (/ y (+ (+ y x) 1.0)) (+ y x))
             (if (<= y 3e-15)
               (/ (* x (/ y (+ y x))) (+ y x))
               (/ (* x (/ 1.0 (+ y (+ x 1.0)))) (+ y x)))))
          assert(x < y);
          double code(double x, double y) {
          	double tmp;
          	if (y <= 5.2e-143) {
          		tmp = (y / ((y + x) + 1.0)) / (y + x);
          	} else if (y <= 3e-15) {
          		tmp = (x * (y / (y + x))) / (y + x);
          	} else {
          		tmp = (x * (1.0 / (y + (x + 1.0)))) / (y + x);
          	}
          	return tmp;
          }
          
          NOTE: x and y should be sorted in increasing order before calling this function.
          real(8) function code(x, y)
              real(8), intent (in) :: x
              real(8), intent (in) :: y
              real(8) :: tmp
              if (y <= 5.2d-143) then
                  tmp = (y / ((y + x) + 1.0d0)) / (y + x)
              else if (y <= 3d-15) then
                  tmp = (x * (y / (y + x))) / (y + x)
              else
                  tmp = (x * (1.0d0 / (y + (x + 1.0d0)))) / (y + x)
              end if
              code = tmp
          end function
          
          assert x < y;
          public static double code(double x, double y) {
          	double tmp;
          	if (y <= 5.2e-143) {
          		tmp = (y / ((y + x) + 1.0)) / (y + x);
          	} else if (y <= 3e-15) {
          		tmp = (x * (y / (y + x))) / (y + x);
          	} else {
          		tmp = (x * (1.0 / (y + (x + 1.0)))) / (y + x);
          	}
          	return tmp;
          }
          
          [x, y] = sort([x, y])
          def code(x, y):
          	tmp = 0
          	if y <= 5.2e-143:
          		tmp = (y / ((y + x) + 1.0)) / (y + x)
          	elif y <= 3e-15:
          		tmp = (x * (y / (y + x))) / (y + x)
          	else:
          		tmp = (x * (1.0 / (y + (x + 1.0)))) / (y + x)
          	return tmp
          
          x, y = sort([x, y])
          function code(x, y)
          	tmp = 0.0
          	if (y <= 5.2e-143)
          		tmp = Float64(Float64(y / Float64(Float64(y + x) + 1.0)) / Float64(y + x));
          	elseif (y <= 3e-15)
          		tmp = Float64(Float64(x * Float64(y / Float64(y + x))) / Float64(y + x));
          	else
          		tmp = Float64(Float64(x * Float64(1.0 / Float64(y + Float64(x + 1.0)))) / Float64(y + x));
          	end
          	return tmp
          end
          
          x, y = num2cell(sort([x, y])){:}
          function tmp_2 = code(x, y)
          	tmp = 0.0;
          	if (y <= 5.2e-143)
          		tmp = (y / ((y + x) + 1.0)) / (y + x);
          	elseif (y <= 3e-15)
          		tmp = (x * (y / (y + x))) / (y + x);
          	else
          		tmp = (x * (1.0 / (y + (x + 1.0)))) / (y + x);
          	end
          	tmp_2 = tmp;
          end
          
          NOTE: x and y should be sorted in increasing order before calling this function.
          code[x_, y_] := If[LessEqual[y, 5.2e-143], N[(N[(y / N[(N[(y + x), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3e-15], N[(N[(x * N[(y / N[(y + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 / N[(y + N[(x + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]]]
          
          \begin{array}{l}
          [x, y] = \mathsf{sort}([x, y])\\
          \\
          \begin{array}{l}
          \mathbf{if}\;y \leq 5.2 \cdot 10^{-143}:\\
          \;\;\;\;\frac{\frac{y}{\left(y + x\right) + 1}}{y + x}\\
          
          \mathbf{elif}\;y \leq 3 \cdot 10^{-15}:\\
          \;\;\;\;\frac{x \cdot \frac{y}{y + x}}{y + x}\\
          
          \mathbf{else}:\\
          \;\;\;\;\frac{x \cdot \frac{1}{y + \left(x + 1\right)}}{y + x}\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if y < 5.19999999999999974e-143

            1. Initial program 72.6%

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

                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
              2. *-lowering-*.f64N/A

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

                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
              4. *-lowering-*.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
              5. +-lowering-+.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
              6. *-lowering-*.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
              7. +-lowering-+.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
              8. associate-+l+N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
              9. +-lowering-+.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
              10. +-lowering-+.f6472.6%

                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
            3. Simplified72.6%

              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
            4. Add Preprocessing
            5. Step-by-step derivation
              1. associate-/r*N/A

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

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

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

                \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
              5. /-lowering-/.f64N/A

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

                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
              7. *-lowering-*.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
              8. /-lowering-/.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
              9. +-lowering-+.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
              10. associate-+r+N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
              11. +-lowering-+.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
              12. +-lowering-+.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
              13. +-lowering-+.f6499.9%

                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
            6. Applied egg-rr99.9%

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

              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\color{blue}{y}, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
            8. Step-by-step derivation
              1. Simplified61.4%

                \[\leadsto \frac{\frac{\color{blue}{y}}{\left(x + y\right) + 1}}{x + y} \]

              if 5.19999999999999974e-143 < y < 3e-15

              1. Initial program 88.1%

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

                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                2. *-lowering-*.f64N/A

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

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                4. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                5. +-lowering-+.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                6. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                7. +-lowering-+.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                8. associate-+l+N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                9. +-lowering-+.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                10. +-lowering-+.f6488.1%

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
              3. Simplified88.1%

                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
              4. Add Preprocessing
              5. Step-by-step derivation
                1. associate-/r*N/A

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

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

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

                  \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                5. /-lowering-/.f64N/A

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

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                7. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                8. /-lowering-/.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                9. +-lowering-+.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                10. associate-+r+N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                11. +-lowering-+.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                12. +-lowering-+.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                13. +-lowering-+.f6499.9%

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
              6. Applied egg-rr99.9%

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

                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\color{blue}{y}, 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
              8. Step-by-step derivation
                1. Simplified77.1%

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

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \color{blue}{1}\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                3. Step-by-step derivation
                  1. Simplified77.1%

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

                  if 3e-15 < y

                  1. Initial program 61.8%

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

                      \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                    2. *-lowering-*.f64N/A

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

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                    4. *-lowering-*.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                    5. +-lowering-+.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                    6. *-lowering-*.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                    7. +-lowering-+.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                    8. associate-+l+N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                    9. +-lowering-+.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                    10. +-lowering-+.f6461.8%

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                  3. Simplified61.8%

                    \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                  4. Add Preprocessing
                  5. Step-by-step derivation
                    1. associate-/r*N/A

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

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

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

                      \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                    5. /-lowering-/.f64N/A

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

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                    7. *-lowering-*.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                    8. /-lowering-/.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                    9. +-lowering-+.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                    10. associate-+r+N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                    11. +-lowering-+.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                    12. +-lowering-+.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                    13. +-lowering-+.f6499.8%

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                  6. Applied egg-rr99.8%

                    \[\leadsto \color{blue}{\frac{\frac{x \cdot \frac{y}{x + y}}{\left(x + y\right) + 1}}{x + y}} \]
                  7. Step-by-step derivation
                    1. associate-/l*N/A

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

                      \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{y}{x + y}}{\left(x + y\right) + 1} \cdot x\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                    3. *-lowering-*.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{y}{x + y}}{\left(x + y\right) + 1}\right), x\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                    4. /-lowering-/.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{y}{x + y}\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                    5. /-lowering-/.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(x + y\right)\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                    6. +-lowering-+.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                    7. +-commutativeN/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(\left(y + x\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                    8. associate-+l+N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(y + \left(x + 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                    9. +-lowering-+.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \left(x + 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                    10. +-lowering-+.f6499.9%

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                  8. Applied egg-rr99.9%

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

                    \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\color{blue}{1}, \mathsf{+.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                  10. Step-by-step derivation
                    1. Simplified74.7%

                      \[\leadsto \frac{\frac{\color{blue}{1}}{y + \left(x + 1\right)} \cdot x}{x + y} \]
                  11. Recombined 3 regimes into one program.
                  12. Final simplification66.9%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 5.2 \cdot 10^{-143}:\\ \;\;\;\;\frac{\frac{y}{\left(y + x\right) + 1}}{y + x}\\ \mathbf{elif}\;y \leq 3 \cdot 10^{-15}:\\ \;\;\;\;\frac{x \cdot \frac{y}{y + x}}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot \frac{1}{y + \left(x + 1\right)}}{y + x}\\ \end{array} \]
                  13. Add Preprocessing

                  Alternative 4: 81.4% accurate, 0.8× speedup?

                  \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;x \leq -280000:\\ \;\;\;\;\frac{\frac{y}{x}}{x}\\ \mathbf{elif}\;x \leq -5 \cdot 10^{-14}:\\ \;\;\;\;\frac{x}{y \cdot y}\\ \mathbf{elif}\;x \leq -1.8 \cdot 10^{-52}:\\ \;\;\;\;\frac{y}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{y}}{y + 1}\\ \end{array} \end{array} \]
                  NOTE: x and y should be sorted in increasing order before calling this function.
                  (FPCore (x y)
                   :precision binary64
                   (if (<= x -280000.0)
                     (/ (/ y x) x)
                     (if (<= x -5e-14)
                       (/ x (* y y))
                       (if (<= x -1.8e-52) (/ y (+ y x)) (/ (/ x y) (+ y 1.0))))))
                  assert(x < y);
                  double code(double x, double y) {
                  	double tmp;
                  	if (x <= -280000.0) {
                  		tmp = (y / x) / x;
                  	} else if (x <= -5e-14) {
                  		tmp = x / (y * y);
                  	} else if (x <= -1.8e-52) {
                  		tmp = y / (y + x);
                  	} else {
                  		tmp = (x / y) / (y + 1.0);
                  	}
                  	return tmp;
                  }
                  
                  NOTE: x and y should be sorted in increasing order before calling this function.
                  real(8) function code(x, y)
                      real(8), intent (in) :: x
                      real(8), intent (in) :: y
                      real(8) :: tmp
                      if (x <= (-280000.0d0)) then
                          tmp = (y / x) / x
                      else if (x <= (-5d-14)) then
                          tmp = x / (y * y)
                      else if (x <= (-1.8d-52)) then
                          tmp = y / (y + x)
                      else
                          tmp = (x / y) / (y + 1.0d0)
                      end if
                      code = tmp
                  end function
                  
                  assert x < y;
                  public static double code(double x, double y) {
                  	double tmp;
                  	if (x <= -280000.0) {
                  		tmp = (y / x) / x;
                  	} else if (x <= -5e-14) {
                  		tmp = x / (y * y);
                  	} else if (x <= -1.8e-52) {
                  		tmp = y / (y + x);
                  	} else {
                  		tmp = (x / y) / (y + 1.0);
                  	}
                  	return tmp;
                  }
                  
                  [x, y] = sort([x, y])
                  def code(x, y):
                  	tmp = 0
                  	if x <= -280000.0:
                  		tmp = (y / x) / x
                  	elif x <= -5e-14:
                  		tmp = x / (y * y)
                  	elif x <= -1.8e-52:
                  		tmp = y / (y + x)
                  	else:
                  		tmp = (x / y) / (y + 1.0)
                  	return tmp
                  
                  x, y = sort([x, y])
                  function code(x, y)
                  	tmp = 0.0
                  	if (x <= -280000.0)
                  		tmp = Float64(Float64(y / x) / x);
                  	elseif (x <= -5e-14)
                  		tmp = Float64(x / Float64(y * y));
                  	elseif (x <= -1.8e-52)
                  		tmp = Float64(y / Float64(y + x));
                  	else
                  		tmp = Float64(Float64(x / y) / Float64(y + 1.0));
                  	end
                  	return tmp
                  end
                  
                  x, y = num2cell(sort([x, y])){:}
                  function tmp_2 = code(x, y)
                  	tmp = 0.0;
                  	if (x <= -280000.0)
                  		tmp = (y / x) / x;
                  	elseif (x <= -5e-14)
                  		tmp = x / (y * y);
                  	elseif (x <= -1.8e-52)
                  		tmp = y / (y + x);
                  	else
                  		tmp = (x / y) / (y + 1.0);
                  	end
                  	tmp_2 = tmp;
                  end
                  
                  NOTE: x and y should be sorted in increasing order before calling this function.
                  code[x_, y_] := If[LessEqual[x, -280000.0], N[(N[(y / x), $MachinePrecision] / x), $MachinePrecision], If[LessEqual[x, -5e-14], N[(x / N[(y * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -1.8e-52], N[(y / N[(y + x), $MachinePrecision]), $MachinePrecision], N[(N[(x / y), $MachinePrecision] / N[(y + 1.0), $MachinePrecision]), $MachinePrecision]]]]
                  
                  \begin{array}{l}
                  [x, y] = \mathsf{sort}([x, y])\\
                  \\
                  \begin{array}{l}
                  \mathbf{if}\;x \leq -280000:\\
                  \;\;\;\;\frac{\frac{y}{x}}{x}\\
                  
                  \mathbf{elif}\;x \leq -5 \cdot 10^{-14}:\\
                  \;\;\;\;\frac{x}{y \cdot y}\\
                  
                  \mathbf{elif}\;x \leq -1.8 \cdot 10^{-52}:\\
                  \;\;\;\;\frac{y}{y + x}\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;\frac{\frac{x}{y}}{y + 1}\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 4 regimes
                  2. if x < -2.8e5

                    1. Initial program 54.3%

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

                        \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                      2. *-lowering-*.f64N/A

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

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                      4. *-lowering-*.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                      5. +-lowering-+.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                      6. *-lowering-*.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                      7. +-lowering-+.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                      8. associate-+l+N/A

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                      9. +-lowering-+.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                      10. +-lowering-+.f6454.3%

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                    3. Simplified54.3%

                      \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                    4. Add Preprocessing
                    5. Taylor expanded in y around 0

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

                        \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                      2. /-lowering-/.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                      3. /-lowering-/.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                      4. +-commutativeN/A

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                      5. +-lowering-+.f6475.1%

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                    7. Simplified75.1%

                      \[\leadsto \color{blue}{\frac{\frac{y}{x}}{x + 1}} \]
                    8. Taylor expanded in x around inf

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \color{blue}{x}\right) \]
                    9. Step-by-step derivation
                      1. Simplified75.1%

                        \[\leadsto \frac{\frac{y}{x}}{\color{blue}{x}} \]

                      if -2.8e5 < x < -5.0000000000000002e-14

                      1. Initial program 68.9%

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

                          \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                        2. *-lowering-*.f64N/A

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

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                        4. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                        5. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                        6. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                        7. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                        8. associate-+l+N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                        9. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                        10. +-lowering-+.f6468.9%

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                      3. Simplified68.9%

                        \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                      4. Add Preprocessing
                      5. Taylor expanded in y around inf

                        \[\leadsto \color{blue}{\frac{x}{{y}^{2}}} \]
                      6. Step-by-step derivation
                        1. /-lowering-/.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left({y}^{2}\right)}\right) \]
                        2. unpow2N/A

                          \[\leadsto \mathsf{/.f64}\left(x, \left(y \cdot \color{blue}{y}\right)\right) \]
                        3. *-lowering-*.f64100.0%

                          \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right) \]
                      7. Simplified100.0%

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

                      if -5.0000000000000002e-14 < x < -1.79999999999999994e-52

                      1. Initial program 88.3%

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

                          \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                        2. *-lowering-*.f64N/A

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

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                        4. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                        5. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                        6. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                        7. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                        8. associate-+l+N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                        9. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                        10. +-lowering-+.f6488.3%

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                      3. Simplified88.3%

                        \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                      4. Add Preprocessing
                      5. Step-by-step derivation
                        1. associate-/r*N/A

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

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

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

                          \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                        5. /-lowering-/.f64N/A

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

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                        7. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                        8. /-lowering-/.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                        9. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                        10. associate-+r+N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                        11. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                        12. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                        13. +-lowering-+.f64100.0%

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                      6. Applied egg-rr100.0%

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

                        \[\leadsto \mathsf{/.f64}\left(\color{blue}{\left(\frac{y}{1 + x}\right)}, \mathsf{+.f64}\left(x, y\right)\right) \]
                      8. Step-by-step derivation
                        1. /-lowering-/.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(1 + x\right)\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                        2. +-commutativeN/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(x + 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                        3. +-lowering-+.f6469.8%

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                      9. Simplified69.8%

                        \[\leadsto \frac{\color{blue}{\frac{y}{x + 1}}}{x + y} \]
                      10. Taylor expanded in x around 0

                        \[\leadsto \mathsf{/.f64}\left(\color{blue}{y}, \mathsf{+.f64}\left(x, y\right)\right) \]
                      11. Step-by-step derivation
                        1. Simplified69.8%

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

                        if -1.79999999999999994e-52 < x

                        1. Initial program 76.6%

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

                            \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                          2. *-lowering-*.f64N/A

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

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                          4. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                          5. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                          6. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                          7. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                          8. associate-+l+N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                          9. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                          10. +-lowering-+.f6476.6%

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                        3. Simplified76.6%

                          \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                        4. Add Preprocessing
                        5. Taylor expanded in x around 0

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

                            \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left(y \cdot \left(1 + y\right)\right)}\right) \]
                          2. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{\left(1 + y\right)}\right)\right) \]
                          3. +-commutativeN/A

                            \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \left(y + \color{blue}{1}\right)\right)\right) \]
                          4. +-lowering-+.f6458.8%

                            \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right) \]
                        7. Simplified58.8%

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

                            \[\leadsto \frac{\frac{x}{y}}{\color{blue}{y + 1}} \]
                          2. /-lowering-/.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\left(\frac{x}{y}\right), \color{blue}{\left(y + 1\right)}\right) \]
                          3. /-lowering-/.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, y\right), \left(\color{blue}{y} + 1\right)\right) \]
                          4. +-lowering-+.f6458.2%

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, y\right), \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right) \]
                        9. Applied egg-rr58.2%

                          \[\leadsto \color{blue}{\frac{\frac{x}{y}}{y + 1}} \]
                      12. Recombined 4 regimes into one program.
                      13. Final simplification63.1%

                        \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -280000:\\ \;\;\;\;\frac{\frac{y}{x}}{x}\\ \mathbf{elif}\;x \leq -5 \cdot 10^{-14}:\\ \;\;\;\;\frac{x}{y \cdot y}\\ \mathbf{elif}\;x \leq -1.8 \cdot 10^{-52}:\\ \;\;\;\;\frac{y}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{y}}{y + 1}\\ \end{array} \]
                      14. Add Preprocessing

                      Alternative 5: 80.0% accurate, 0.8× speedup?

                      \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;x \leq -320000:\\ \;\;\;\;\frac{\frac{y}{x}}{x}\\ \mathbf{elif}\;x \leq -4.8 \cdot 10^{-9}:\\ \;\;\;\;\frac{x}{y \cdot y}\\ \mathbf{elif}\;x \leq -8.2 \cdot 10^{-53}:\\ \;\;\;\;\frac{y}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{y \cdot \left(y + 1\right)}\\ \end{array} \end{array} \]
                      NOTE: x and y should be sorted in increasing order before calling this function.
                      (FPCore (x y)
                       :precision binary64
                       (if (<= x -320000.0)
                         (/ (/ y x) x)
                         (if (<= x -4.8e-9)
                           (/ x (* y y))
                           (if (<= x -8.2e-53) (/ y (+ y x)) (/ x (* y (+ y 1.0)))))))
                      assert(x < y);
                      double code(double x, double y) {
                      	double tmp;
                      	if (x <= -320000.0) {
                      		tmp = (y / x) / x;
                      	} else if (x <= -4.8e-9) {
                      		tmp = x / (y * y);
                      	} else if (x <= -8.2e-53) {
                      		tmp = y / (y + x);
                      	} else {
                      		tmp = x / (y * (y + 1.0));
                      	}
                      	return tmp;
                      }
                      
                      NOTE: x and y should be sorted in increasing order before calling this function.
                      real(8) function code(x, y)
                          real(8), intent (in) :: x
                          real(8), intent (in) :: y
                          real(8) :: tmp
                          if (x <= (-320000.0d0)) then
                              tmp = (y / x) / x
                          else if (x <= (-4.8d-9)) then
                              tmp = x / (y * y)
                          else if (x <= (-8.2d-53)) then
                              tmp = y / (y + x)
                          else
                              tmp = x / (y * (y + 1.0d0))
                          end if
                          code = tmp
                      end function
                      
                      assert x < y;
                      public static double code(double x, double y) {
                      	double tmp;
                      	if (x <= -320000.0) {
                      		tmp = (y / x) / x;
                      	} else if (x <= -4.8e-9) {
                      		tmp = x / (y * y);
                      	} else if (x <= -8.2e-53) {
                      		tmp = y / (y + x);
                      	} else {
                      		tmp = x / (y * (y + 1.0));
                      	}
                      	return tmp;
                      }
                      
                      [x, y] = sort([x, y])
                      def code(x, y):
                      	tmp = 0
                      	if x <= -320000.0:
                      		tmp = (y / x) / x
                      	elif x <= -4.8e-9:
                      		tmp = x / (y * y)
                      	elif x <= -8.2e-53:
                      		tmp = y / (y + x)
                      	else:
                      		tmp = x / (y * (y + 1.0))
                      	return tmp
                      
                      x, y = sort([x, y])
                      function code(x, y)
                      	tmp = 0.0
                      	if (x <= -320000.0)
                      		tmp = Float64(Float64(y / x) / x);
                      	elseif (x <= -4.8e-9)
                      		tmp = Float64(x / Float64(y * y));
                      	elseif (x <= -8.2e-53)
                      		tmp = Float64(y / Float64(y + x));
                      	else
                      		tmp = Float64(x / Float64(y * Float64(y + 1.0)));
                      	end
                      	return tmp
                      end
                      
                      x, y = num2cell(sort([x, y])){:}
                      function tmp_2 = code(x, y)
                      	tmp = 0.0;
                      	if (x <= -320000.0)
                      		tmp = (y / x) / x;
                      	elseif (x <= -4.8e-9)
                      		tmp = x / (y * y);
                      	elseif (x <= -8.2e-53)
                      		tmp = y / (y + x);
                      	else
                      		tmp = x / (y * (y + 1.0));
                      	end
                      	tmp_2 = tmp;
                      end
                      
                      NOTE: x and y should be sorted in increasing order before calling this function.
                      code[x_, y_] := If[LessEqual[x, -320000.0], N[(N[(y / x), $MachinePrecision] / x), $MachinePrecision], If[LessEqual[x, -4.8e-9], N[(x / N[(y * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -8.2e-53], N[(y / N[(y + x), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * N[(y + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
                      
                      \begin{array}{l}
                      [x, y] = \mathsf{sort}([x, y])\\
                      \\
                      \begin{array}{l}
                      \mathbf{if}\;x \leq -320000:\\
                      \;\;\;\;\frac{\frac{y}{x}}{x}\\
                      
                      \mathbf{elif}\;x \leq -4.8 \cdot 10^{-9}:\\
                      \;\;\;\;\frac{x}{y \cdot y}\\
                      
                      \mathbf{elif}\;x \leq -8.2 \cdot 10^{-53}:\\
                      \;\;\;\;\frac{y}{y + x}\\
                      
                      \mathbf{else}:\\
                      \;\;\;\;\frac{x}{y \cdot \left(y + 1\right)}\\
                      
                      
                      \end{array}
                      \end{array}
                      
                      Derivation
                      1. Split input into 4 regimes
                      2. if x < -3.2e5

                        1. Initial program 54.3%

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

                            \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                          2. *-lowering-*.f64N/A

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

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                          4. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                          5. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                          6. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                          7. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                          8. associate-+l+N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                          9. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                          10. +-lowering-+.f6454.3%

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                        3. Simplified54.3%

                          \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                        4. Add Preprocessing
                        5. Taylor expanded in y around 0

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

                            \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                          2. /-lowering-/.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                          3. /-lowering-/.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                          4. +-commutativeN/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                          5. +-lowering-+.f6475.1%

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                        7. Simplified75.1%

                          \[\leadsto \color{blue}{\frac{\frac{y}{x}}{x + 1}} \]
                        8. Taylor expanded in x around inf

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \color{blue}{x}\right) \]
                        9. Step-by-step derivation
                          1. Simplified75.1%

                            \[\leadsto \frac{\frac{y}{x}}{\color{blue}{x}} \]

                          if -3.2e5 < x < -4.8e-9

                          1. Initial program 68.9%

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

                              \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                            2. *-lowering-*.f64N/A

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

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                            4. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                            5. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                            6. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                            7. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                            8. associate-+l+N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                            9. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                            10. +-lowering-+.f6468.9%

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                          3. Simplified68.9%

                            \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                          4. Add Preprocessing
                          5. Taylor expanded in y around inf

                            \[\leadsto \color{blue}{\frac{x}{{y}^{2}}} \]
                          6. Step-by-step derivation
                            1. /-lowering-/.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left({y}^{2}\right)}\right) \]
                            2. unpow2N/A

                              \[\leadsto \mathsf{/.f64}\left(x, \left(y \cdot \color{blue}{y}\right)\right) \]
                            3. *-lowering-*.f64100.0%

                              \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right) \]
                          7. Simplified100.0%

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

                          if -4.8e-9 < x < -8.2000000000000001e-53

                          1. Initial program 88.3%

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

                              \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                            2. *-lowering-*.f64N/A

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

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                            4. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                            5. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                            6. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                            7. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                            8. associate-+l+N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                            9. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                            10. +-lowering-+.f6488.3%

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                          3. Simplified88.3%

                            \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                          4. Add Preprocessing
                          5. Step-by-step derivation
                            1. associate-/r*N/A

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

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

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

                              \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                            5. /-lowering-/.f64N/A

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

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                            7. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                            8. /-lowering-/.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                            9. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                            10. associate-+r+N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                            11. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                            12. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                            13. +-lowering-+.f64100.0%

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                          6. Applied egg-rr100.0%

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

                            \[\leadsto \mathsf{/.f64}\left(\color{blue}{\left(\frac{y}{1 + x}\right)}, \mathsf{+.f64}\left(x, y\right)\right) \]
                          8. Step-by-step derivation
                            1. /-lowering-/.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(1 + x\right)\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                            2. +-commutativeN/A

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(x + 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                            3. +-lowering-+.f6469.8%

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                          9. Simplified69.8%

                            \[\leadsto \frac{\color{blue}{\frac{y}{x + 1}}}{x + y} \]
                          10. Taylor expanded in x around 0

                            \[\leadsto \mathsf{/.f64}\left(\color{blue}{y}, \mathsf{+.f64}\left(x, y\right)\right) \]
                          11. Step-by-step derivation
                            1. Simplified69.8%

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

                            if -8.2000000000000001e-53 < x

                            1. Initial program 76.6%

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

                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                              2. *-lowering-*.f64N/A

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

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                              4. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                              5. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                              6. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                              7. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                              8. associate-+l+N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                              9. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                              10. +-lowering-+.f6476.6%

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                            3. Simplified76.6%

                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                            4. Add Preprocessing
                            5. Taylor expanded in x around 0

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

                                \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left(y \cdot \left(1 + y\right)\right)}\right) \]
                              2. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{\left(1 + y\right)}\right)\right) \]
                              3. +-commutativeN/A

                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \left(y + \color{blue}{1}\right)\right)\right) \]
                              4. +-lowering-+.f6458.8%

                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right) \]
                            7. Simplified58.8%

                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(y + 1\right)}} \]
                          12. Recombined 4 regimes into one program.
                          13. Final simplification63.6%

                            \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -320000:\\ \;\;\;\;\frac{\frac{y}{x}}{x}\\ \mathbf{elif}\;x \leq -4.8 \cdot 10^{-9}:\\ \;\;\;\;\frac{x}{y \cdot y}\\ \mathbf{elif}\;x \leq -8.2 \cdot 10^{-53}:\\ \;\;\;\;\frac{y}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{y \cdot \left(y + 1\right)}\\ \end{array} \]
                          14. Add Preprocessing

                          Alternative 6: 75.9% accurate, 0.8× speedup?

                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq -2.1 \cdot 10^{-195}:\\ \;\;\;\;\frac{\frac{y}{x}}{x}\\ \mathbf{elif}\;y \leq 3.1 \cdot 10^{-130}:\\ \;\;\;\;\frac{y}{x}\\ \mathbf{elif}\;y \leq 1:\\ \;\;\;\;\frac{x}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{y}}{y}\\ \end{array} \end{array} \]
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          (FPCore (x y)
                           :precision binary64
                           (if (<= y -2.1e-195)
                             (/ (/ y x) x)
                             (if (<= y 3.1e-130) (/ y x) (if (<= y 1.0) (/ x y) (/ (/ x y) y)))))
                          assert(x < y);
                          double code(double x, double y) {
                          	double tmp;
                          	if (y <= -2.1e-195) {
                          		tmp = (y / x) / x;
                          	} else if (y <= 3.1e-130) {
                          		tmp = y / x;
                          	} else if (y <= 1.0) {
                          		tmp = x / y;
                          	} else {
                          		tmp = (x / y) / y;
                          	}
                          	return tmp;
                          }
                          
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          real(8) function code(x, y)
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              real(8) :: tmp
                              if (y <= (-2.1d-195)) then
                                  tmp = (y / x) / x
                              else if (y <= 3.1d-130) then
                                  tmp = y / x
                              else if (y <= 1.0d0) then
                                  tmp = x / y
                              else
                                  tmp = (x / y) / y
                              end if
                              code = tmp
                          end function
                          
                          assert x < y;
                          public static double code(double x, double y) {
                          	double tmp;
                          	if (y <= -2.1e-195) {
                          		tmp = (y / x) / x;
                          	} else if (y <= 3.1e-130) {
                          		tmp = y / x;
                          	} else if (y <= 1.0) {
                          		tmp = x / y;
                          	} else {
                          		tmp = (x / y) / y;
                          	}
                          	return tmp;
                          }
                          
                          [x, y] = sort([x, y])
                          def code(x, y):
                          	tmp = 0
                          	if y <= -2.1e-195:
                          		tmp = (y / x) / x
                          	elif y <= 3.1e-130:
                          		tmp = y / x
                          	elif y <= 1.0:
                          		tmp = x / y
                          	else:
                          		tmp = (x / y) / y
                          	return tmp
                          
                          x, y = sort([x, y])
                          function code(x, y)
                          	tmp = 0.0
                          	if (y <= -2.1e-195)
                          		tmp = Float64(Float64(y / x) / x);
                          	elseif (y <= 3.1e-130)
                          		tmp = Float64(y / x);
                          	elseif (y <= 1.0)
                          		tmp = Float64(x / y);
                          	else
                          		tmp = Float64(Float64(x / y) / y);
                          	end
                          	return tmp
                          end
                          
                          x, y = num2cell(sort([x, y])){:}
                          function tmp_2 = code(x, y)
                          	tmp = 0.0;
                          	if (y <= -2.1e-195)
                          		tmp = (y / x) / x;
                          	elseif (y <= 3.1e-130)
                          		tmp = y / x;
                          	elseif (y <= 1.0)
                          		tmp = x / y;
                          	else
                          		tmp = (x / y) / y;
                          	end
                          	tmp_2 = tmp;
                          end
                          
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          code[x_, y_] := If[LessEqual[y, -2.1e-195], N[(N[(y / x), $MachinePrecision] / x), $MachinePrecision], If[LessEqual[y, 3.1e-130], N[(y / x), $MachinePrecision], If[LessEqual[y, 1.0], N[(x / y), $MachinePrecision], N[(N[(x / y), $MachinePrecision] / y), $MachinePrecision]]]]
                          
                          \begin{array}{l}
                          [x, y] = \mathsf{sort}([x, y])\\
                          \\
                          \begin{array}{l}
                          \mathbf{if}\;y \leq -2.1 \cdot 10^{-195}:\\
                          \;\;\;\;\frac{\frac{y}{x}}{x}\\
                          
                          \mathbf{elif}\;y \leq 3.1 \cdot 10^{-130}:\\
                          \;\;\;\;\frac{y}{x}\\
                          
                          \mathbf{elif}\;y \leq 1:\\
                          \;\;\;\;\frac{x}{y}\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\frac{\frac{x}{y}}{y}\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 4 regimes
                          2. if y < -2.1e-195

                            1. Initial program 73.1%

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

                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                              2. *-lowering-*.f64N/A

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

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                              4. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                              5. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                              6. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                              7. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                              8. associate-+l+N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                              9. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                              10. +-lowering-+.f6473.1%

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                            3. Simplified73.1%

                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                            4. Add Preprocessing
                            5. Taylor expanded in y around 0

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

                                \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                              2. /-lowering-/.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                              3. /-lowering-/.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                              4. +-commutativeN/A

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                              5. +-lowering-+.f6440.3%

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                            7. Simplified40.3%

                              \[\leadsto \color{blue}{\frac{\frac{y}{x}}{x + 1}} \]
                            8. Taylor expanded in x around inf

                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \color{blue}{x}\right) \]
                            9. Step-by-step derivation
                              1. Simplified36.0%

                                \[\leadsto \frac{\frac{y}{x}}{\color{blue}{x}} \]

                              if -2.1e-195 < y < 3.10000000000000011e-130

                              1. Initial program 71.7%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6471.7%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified71.7%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in y around 0

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

                                  \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                                2. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                                3. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                                4. +-commutativeN/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                                5. +-lowering-+.f6489.8%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                              7. Simplified89.8%

                                \[\leadsto \color{blue}{\frac{\frac{y}{x}}{x + 1}} \]
                              8. Taylor expanded in x around 0

                                \[\leadsto \color{blue}{\frac{y}{x}} \]
                              9. Step-by-step derivation
                                1. /-lowering-/.f6468.6%

                                  \[\leadsto \mathsf{/.f64}\left(y, \color{blue}{x}\right) \]
                              10. Simplified68.6%

                                \[\leadsto \color{blue}{\frac{y}{x}} \]

                              if 3.10000000000000011e-130 < y < 1

                              1. Initial program 90.9%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6491.0%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified91.0%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in x around 0

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

                                  \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left(y \cdot \left(1 + y\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{\left(1 + y\right)}\right)\right) \]
                                3. +-commutativeN/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \left(y + \color{blue}{1}\right)\right)\right) \]
                                4. +-lowering-+.f6445.5%

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right) \]
                              7. Simplified45.5%

                                \[\leadsto \color{blue}{\frac{x}{y \cdot \left(y + 1\right)}} \]
                              8. Taylor expanded in y around 0

                                \[\leadsto \color{blue}{\frac{x}{y}} \]
                              9. Step-by-step derivation
                                1. /-lowering-/.f6443.6%

                                  \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{y}\right) \]
                              10. Simplified43.6%

                                \[\leadsto \color{blue}{\frac{x}{y}} \]

                              if 1 < y

                              1. Initial program 60.7%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6460.7%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified60.7%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in y around inf

                                \[\leadsto \color{blue}{\frac{x}{{y}^{2}}} \]
                              6. Step-by-step derivation
                                1. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left({y}^{2}\right)}\right) \]
                                2. unpow2N/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \left(y \cdot \color{blue}{y}\right)\right) \]
                                3. *-lowering-*.f6476.0%

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right) \]
                              7. Simplified76.0%

                                \[\leadsto \color{blue}{\frac{x}{y \cdot y}} \]
                              8. Step-by-step derivation
                                1. associate-/r*N/A

                                  \[\leadsto \frac{\frac{x}{y}}{\color{blue}{y}} \]
                                2. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\left(\frac{x}{y}\right), \color{blue}{y}\right) \]
                                3. /-lowering-/.f6474.3%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, y\right), y\right) \]
                              9. Applied egg-rr74.3%

                                \[\leadsto \color{blue}{\frac{\frac{x}{y}}{y}} \]
                            10. Recombined 4 regimes into one program.
                            11. Add Preprocessing

                            Alternative 7: 74.4% accurate, 0.8× speedup?

                            \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq -5.5 \cdot 10^{-194}:\\ \;\;\;\;\frac{y}{x \cdot x}\\ \mathbf{elif}\;y \leq 2.45 \cdot 10^{-129}:\\ \;\;\;\;\frac{y}{x}\\ \mathbf{elif}\;y \leq 1:\\ \;\;\;\;\frac{x}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{y}}{y}\\ \end{array} \end{array} \]
                            NOTE: x and y should be sorted in increasing order before calling this function.
                            (FPCore (x y)
                             :precision binary64
                             (if (<= y -5.5e-194)
                               (/ y (* x x))
                               (if (<= y 2.45e-129) (/ y x) (if (<= y 1.0) (/ x y) (/ (/ x y) y)))))
                            assert(x < y);
                            double code(double x, double y) {
                            	double tmp;
                            	if (y <= -5.5e-194) {
                            		tmp = y / (x * x);
                            	} else if (y <= 2.45e-129) {
                            		tmp = y / x;
                            	} else if (y <= 1.0) {
                            		tmp = x / y;
                            	} else {
                            		tmp = (x / y) / y;
                            	}
                            	return tmp;
                            }
                            
                            NOTE: x and y should be sorted in increasing order before calling this function.
                            real(8) function code(x, y)
                                real(8), intent (in) :: x
                                real(8), intent (in) :: y
                                real(8) :: tmp
                                if (y <= (-5.5d-194)) then
                                    tmp = y / (x * x)
                                else if (y <= 2.45d-129) then
                                    tmp = y / x
                                else if (y <= 1.0d0) then
                                    tmp = x / y
                                else
                                    tmp = (x / y) / y
                                end if
                                code = tmp
                            end function
                            
                            assert x < y;
                            public static double code(double x, double y) {
                            	double tmp;
                            	if (y <= -5.5e-194) {
                            		tmp = y / (x * x);
                            	} else if (y <= 2.45e-129) {
                            		tmp = y / x;
                            	} else if (y <= 1.0) {
                            		tmp = x / y;
                            	} else {
                            		tmp = (x / y) / y;
                            	}
                            	return tmp;
                            }
                            
                            [x, y] = sort([x, y])
                            def code(x, y):
                            	tmp = 0
                            	if y <= -5.5e-194:
                            		tmp = y / (x * x)
                            	elif y <= 2.45e-129:
                            		tmp = y / x
                            	elif y <= 1.0:
                            		tmp = x / y
                            	else:
                            		tmp = (x / y) / y
                            	return tmp
                            
                            x, y = sort([x, y])
                            function code(x, y)
                            	tmp = 0.0
                            	if (y <= -5.5e-194)
                            		tmp = Float64(y / Float64(x * x));
                            	elseif (y <= 2.45e-129)
                            		tmp = Float64(y / x);
                            	elseif (y <= 1.0)
                            		tmp = Float64(x / y);
                            	else
                            		tmp = Float64(Float64(x / y) / y);
                            	end
                            	return tmp
                            end
                            
                            x, y = num2cell(sort([x, y])){:}
                            function tmp_2 = code(x, y)
                            	tmp = 0.0;
                            	if (y <= -5.5e-194)
                            		tmp = y / (x * x);
                            	elseif (y <= 2.45e-129)
                            		tmp = y / x;
                            	elseif (y <= 1.0)
                            		tmp = x / y;
                            	else
                            		tmp = (x / y) / y;
                            	end
                            	tmp_2 = tmp;
                            end
                            
                            NOTE: x and y should be sorted in increasing order before calling this function.
                            code[x_, y_] := If[LessEqual[y, -5.5e-194], N[(y / N[(x * x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.45e-129], N[(y / x), $MachinePrecision], If[LessEqual[y, 1.0], N[(x / y), $MachinePrecision], N[(N[(x / y), $MachinePrecision] / y), $MachinePrecision]]]]
                            
                            \begin{array}{l}
                            [x, y] = \mathsf{sort}([x, y])\\
                            \\
                            \begin{array}{l}
                            \mathbf{if}\;y \leq -5.5 \cdot 10^{-194}:\\
                            \;\;\;\;\frac{y}{x \cdot x}\\
                            
                            \mathbf{elif}\;y \leq 2.45 \cdot 10^{-129}:\\
                            \;\;\;\;\frac{y}{x}\\
                            
                            \mathbf{elif}\;y \leq 1:\\
                            \;\;\;\;\frac{x}{y}\\
                            
                            \mathbf{else}:\\
                            \;\;\;\;\frac{\frac{x}{y}}{y}\\
                            
                            
                            \end{array}
                            \end{array}
                            
                            Derivation
                            1. Split input into 4 regimes
                            2. if y < -5.49999999999999941e-194

                              1. Initial program 73.1%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6473.1%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified73.1%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in x around inf

                                \[\leadsto \color{blue}{\frac{y}{{x}^{2}}} \]
                              6. Step-by-step derivation
                                1. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(y, \color{blue}{\left({x}^{2}\right)}\right) \]
                                2. unpow2N/A

                                  \[\leadsto \mathsf{/.f64}\left(y, \left(x \cdot \color{blue}{x}\right)\right) \]
                                3. *-lowering-*.f6435.7%

                                  \[\leadsto \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(x, \color{blue}{x}\right)\right) \]
                              7. Simplified35.7%

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

                              if -5.49999999999999941e-194 < y < 2.45000000000000001e-129

                              1. Initial program 71.7%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6471.7%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified71.7%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in y around 0

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

                                  \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                                2. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                                3. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                                4. +-commutativeN/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                                5. +-lowering-+.f6489.8%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                              7. Simplified89.8%

                                \[\leadsto \color{blue}{\frac{\frac{y}{x}}{x + 1}} \]
                              8. Taylor expanded in x around 0

                                \[\leadsto \color{blue}{\frac{y}{x}} \]
                              9. Step-by-step derivation
                                1. /-lowering-/.f6468.6%

                                  \[\leadsto \mathsf{/.f64}\left(y, \color{blue}{x}\right) \]
                              10. Simplified68.6%

                                \[\leadsto \color{blue}{\frac{y}{x}} \]

                              if 2.45000000000000001e-129 < y < 1

                              1. Initial program 90.9%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6491.0%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified91.0%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in x around 0

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

                                  \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left(y \cdot \left(1 + y\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{\left(1 + y\right)}\right)\right) \]
                                3. +-commutativeN/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \left(y + \color{blue}{1}\right)\right)\right) \]
                                4. +-lowering-+.f6445.5%

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right) \]
                              7. Simplified45.5%

                                \[\leadsto \color{blue}{\frac{x}{y \cdot \left(y + 1\right)}} \]
                              8. Taylor expanded in y around 0

                                \[\leadsto \color{blue}{\frac{x}{y}} \]
                              9. Step-by-step derivation
                                1. /-lowering-/.f6443.6%

                                  \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{y}\right) \]
                              10. Simplified43.6%

                                \[\leadsto \color{blue}{\frac{x}{y}} \]

                              if 1 < y

                              1. Initial program 60.7%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6460.7%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified60.7%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in y around inf

                                \[\leadsto \color{blue}{\frac{x}{{y}^{2}}} \]
                              6. Step-by-step derivation
                                1. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left({y}^{2}\right)}\right) \]
                                2. unpow2N/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \left(y \cdot \color{blue}{y}\right)\right) \]
                                3. *-lowering-*.f6476.0%

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right) \]
                              7. Simplified76.0%

                                \[\leadsto \color{blue}{\frac{x}{y \cdot y}} \]
                              8. Step-by-step derivation
                                1. associate-/r*N/A

                                  \[\leadsto \frac{\frac{x}{y}}{\color{blue}{y}} \]
                                2. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\left(\frac{x}{y}\right), \color{blue}{y}\right) \]
                                3. /-lowering-/.f6474.3%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, y\right), y\right) \]
                              9. Applied egg-rr74.3%

                                \[\leadsto \color{blue}{\frac{\frac{x}{y}}{y}} \]
                            3. Recombined 4 regimes into one program.
                            4. Add Preprocessing

                            Alternative 8: 72.3% accurate, 0.8× speedup?

                            \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq -5.2 \cdot 10^{-194}:\\ \;\;\;\;\frac{y}{x \cdot x}\\ \mathbf{elif}\;y \leq 2.35 \cdot 10^{-129}:\\ \;\;\;\;\frac{y}{x}\\ \mathbf{elif}\;y \leq 1:\\ \;\;\;\;\frac{x}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{y \cdot y}\\ \end{array} \end{array} \]
                            NOTE: x and y should be sorted in increasing order before calling this function.
                            (FPCore (x y)
                             :precision binary64
                             (if (<= y -5.2e-194)
                               (/ y (* x x))
                               (if (<= y 2.35e-129) (/ y x) (if (<= y 1.0) (/ x y) (/ x (* y y))))))
                            assert(x < y);
                            double code(double x, double y) {
                            	double tmp;
                            	if (y <= -5.2e-194) {
                            		tmp = y / (x * x);
                            	} else if (y <= 2.35e-129) {
                            		tmp = y / x;
                            	} else if (y <= 1.0) {
                            		tmp = x / y;
                            	} else {
                            		tmp = x / (y * y);
                            	}
                            	return tmp;
                            }
                            
                            NOTE: x and y should be sorted in increasing order before calling this function.
                            real(8) function code(x, y)
                                real(8), intent (in) :: x
                                real(8), intent (in) :: y
                                real(8) :: tmp
                                if (y <= (-5.2d-194)) then
                                    tmp = y / (x * x)
                                else if (y <= 2.35d-129) then
                                    tmp = y / x
                                else if (y <= 1.0d0) then
                                    tmp = x / y
                                else
                                    tmp = x / (y * y)
                                end if
                                code = tmp
                            end function
                            
                            assert x < y;
                            public static double code(double x, double y) {
                            	double tmp;
                            	if (y <= -5.2e-194) {
                            		tmp = y / (x * x);
                            	} else if (y <= 2.35e-129) {
                            		tmp = y / x;
                            	} else if (y <= 1.0) {
                            		tmp = x / y;
                            	} else {
                            		tmp = x / (y * y);
                            	}
                            	return tmp;
                            }
                            
                            [x, y] = sort([x, y])
                            def code(x, y):
                            	tmp = 0
                            	if y <= -5.2e-194:
                            		tmp = y / (x * x)
                            	elif y <= 2.35e-129:
                            		tmp = y / x
                            	elif y <= 1.0:
                            		tmp = x / y
                            	else:
                            		tmp = x / (y * y)
                            	return tmp
                            
                            x, y = sort([x, y])
                            function code(x, y)
                            	tmp = 0.0
                            	if (y <= -5.2e-194)
                            		tmp = Float64(y / Float64(x * x));
                            	elseif (y <= 2.35e-129)
                            		tmp = Float64(y / x);
                            	elseif (y <= 1.0)
                            		tmp = Float64(x / y);
                            	else
                            		tmp = Float64(x / Float64(y * y));
                            	end
                            	return tmp
                            end
                            
                            x, y = num2cell(sort([x, y])){:}
                            function tmp_2 = code(x, y)
                            	tmp = 0.0;
                            	if (y <= -5.2e-194)
                            		tmp = y / (x * x);
                            	elseif (y <= 2.35e-129)
                            		tmp = y / x;
                            	elseif (y <= 1.0)
                            		tmp = x / y;
                            	else
                            		tmp = x / (y * y);
                            	end
                            	tmp_2 = tmp;
                            end
                            
                            NOTE: x and y should be sorted in increasing order before calling this function.
                            code[x_, y_] := If[LessEqual[y, -5.2e-194], N[(y / N[(x * x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.35e-129], N[(y / x), $MachinePrecision], If[LessEqual[y, 1.0], N[(x / y), $MachinePrecision], N[(x / N[(y * y), $MachinePrecision]), $MachinePrecision]]]]
                            
                            \begin{array}{l}
                            [x, y] = \mathsf{sort}([x, y])\\
                            \\
                            \begin{array}{l}
                            \mathbf{if}\;y \leq -5.2 \cdot 10^{-194}:\\
                            \;\;\;\;\frac{y}{x \cdot x}\\
                            
                            \mathbf{elif}\;y \leq 2.35 \cdot 10^{-129}:\\
                            \;\;\;\;\frac{y}{x}\\
                            
                            \mathbf{elif}\;y \leq 1:\\
                            \;\;\;\;\frac{x}{y}\\
                            
                            \mathbf{else}:\\
                            \;\;\;\;\frac{x}{y \cdot y}\\
                            
                            
                            \end{array}
                            \end{array}
                            
                            Derivation
                            1. Split input into 4 regimes
                            2. if y < -5.20000000000000003e-194

                              1. Initial program 73.1%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6473.1%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified73.1%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in x around inf

                                \[\leadsto \color{blue}{\frac{y}{{x}^{2}}} \]
                              6. Step-by-step derivation
                                1. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(y, \color{blue}{\left({x}^{2}\right)}\right) \]
                                2. unpow2N/A

                                  \[\leadsto \mathsf{/.f64}\left(y, \left(x \cdot \color{blue}{x}\right)\right) \]
                                3. *-lowering-*.f6435.7%

                                  \[\leadsto \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(x, \color{blue}{x}\right)\right) \]
                              7. Simplified35.7%

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

                              if -5.20000000000000003e-194 < y < 2.3500000000000001e-129

                              1. Initial program 71.7%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6471.7%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified71.7%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in y around 0

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

                                  \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                                2. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                                3. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                                4. +-commutativeN/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                                5. +-lowering-+.f6489.8%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                              7. Simplified89.8%

                                \[\leadsto \color{blue}{\frac{\frac{y}{x}}{x + 1}} \]
                              8. Taylor expanded in x around 0

                                \[\leadsto \color{blue}{\frac{y}{x}} \]
                              9. Step-by-step derivation
                                1. /-lowering-/.f6468.6%

                                  \[\leadsto \mathsf{/.f64}\left(y, \color{blue}{x}\right) \]
                              10. Simplified68.6%

                                \[\leadsto \color{blue}{\frac{y}{x}} \]

                              if 2.3500000000000001e-129 < y < 1

                              1. Initial program 90.9%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6491.0%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified91.0%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in x around 0

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

                                  \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left(y \cdot \left(1 + y\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{\left(1 + y\right)}\right)\right) \]
                                3. +-commutativeN/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \left(y + \color{blue}{1}\right)\right)\right) \]
                                4. +-lowering-+.f6445.5%

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right) \]
                              7. Simplified45.5%

                                \[\leadsto \color{blue}{\frac{x}{y \cdot \left(y + 1\right)}} \]
                              8. Taylor expanded in y around 0

                                \[\leadsto \color{blue}{\frac{x}{y}} \]
                              9. Step-by-step derivation
                                1. /-lowering-/.f6443.6%

                                  \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{y}\right) \]
                              10. Simplified43.6%

                                \[\leadsto \color{blue}{\frac{x}{y}} \]

                              if 1 < y

                              1. Initial program 60.7%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6460.7%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified60.7%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Taylor expanded in y around inf

                                \[\leadsto \color{blue}{\frac{x}{{y}^{2}}} \]
                              6. Step-by-step derivation
                                1. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left({y}^{2}\right)}\right) \]
                                2. unpow2N/A

                                  \[\leadsto \mathsf{/.f64}\left(x, \left(y \cdot \color{blue}{y}\right)\right) \]
                                3. *-lowering-*.f6476.0%

                                  \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right) \]
                              7. Simplified76.0%

                                \[\leadsto \color{blue}{\frac{x}{y \cdot y}} \]
                            3. Recombined 4 regimes into one program.
                            4. Add Preprocessing

                            Alternative 9: 98.5% accurate, 0.8× speedup?

                            \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} t_0 := \frac{y}{y + x}\\ \mathbf{if}\;x \leq -1:\\ \;\;\;\;\frac{x \cdot \frac{t\_0}{y + x}}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x \cdot t\_0}{y + 1}}{y + x}\\ \end{array} \end{array} \]
                            NOTE: x and y should be sorted in increasing order before calling this function.
                            (FPCore (x y)
                             :precision binary64
                             (let* ((t_0 (/ y (+ y x))))
                               (if (<= x -1.0)
                                 (/ (* x (/ t_0 (+ y x))) (+ y x))
                                 (/ (/ (* x t_0) (+ y 1.0)) (+ y x)))))
                            assert(x < y);
                            double code(double x, double y) {
                            	double t_0 = y / (y + x);
                            	double tmp;
                            	if (x <= -1.0) {
                            		tmp = (x * (t_0 / (y + x))) / (y + x);
                            	} else {
                            		tmp = ((x * t_0) / (y + 1.0)) / (y + x);
                            	}
                            	return tmp;
                            }
                            
                            NOTE: x and y should be sorted in increasing order before calling this function.
                            real(8) function code(x, y)
                                real(8), intent (in) :: x
                                real(8), intent (in) :: y
                                real(8) :: t_0
                                real(8) :: tmp
                                t_0 = y / (y + x)
                                if (x <= (-1.0d0)) then
                                    tmp = (x * (t_0 / (y + x))) / (y + x)
                                else
                                    tmp = ((x * t_0) / (y + 1.0d0)) / (y + x)
                                end if
                                code = tmp
                            end function
                            
                            assert x < y;
                            public static double code(double x, double y) {
                            	double t_0 = y / (y + x);
                            	double tmp;
                            	if (x <= -1.0) {
                            		tmp = (x * (t_0 / (y + x))) / (y + x);
                            	} else {
                            		tmp = ((x * t_0) / (y + 1.0)) / (y + x);
                            	}
                            	return tmp;
                            }
                            
                            [x, y] = sort([x, y])
                            def code(x, y):
                            	t_0 = y / (y + x)
                            	tmp = 0
                            	if x <= -1.0:
                            		tmp = (x * (t_0 / (y + x))) / (y + x)
                            	else:
                            		tmp = ((x * t_0) / (y + 1.0)) / (y + x)
                            	return tmp
                            
                            x, y = sort([x, y])
                            function code(x, y)
                            	t_0 = Float64(y / Float64(y + x))
                            	tmp = 0.0
                            	if (x <= -1.0)
                            		tmp = Float64(Float64(x * Float64(t_0 / Float64(y + x))) / Float64(y + x));
                            	else
                            		tmp = Float64(Float64(Float64(x * t_0) / Float64(y + 1.0)) / Float64(y + x));
                            	end
                            	return tmp
                            end
                            
                            x, y = num2cell(sort([x, y])){:}
                            function tmp_2 = code(x, y)
                            	t_0 = y / (y + x);
                            	tmp = 0.0;
                            	if (x <= -1.0)
                            		tmp = (x * (t_0 / (y + x))) / (y + x);
                            	else
                            		tmp = ((x * t_0) / (y + 1.0)) / (y + x);
                            	end
                            	tmp_2 = tmp;
                            end
                            
                            NOTE: x and y should be sorted in increasing order before calling this function.
                            code[x_, y_] := Block[{t$95$0 = N[(y / N[(y + x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.0], N[(N[(x * N[(t$95$0 / N[(y + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision], N[(N[(N[(x * t$95$0), $MachinePrecision] / N[(y + 1.0), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]]]
                            
                            \begin{array}{l}
                            [x, y] = \mathsf{sort}([x, y])\\
                            \\
                            \begin{array}{l}
                            t_0 := \frac{y}{y + x}\\
                            \mathbf{if}\;x \leq -1:\\
                            \;\;\;\;\frac{x \cdot \frac{t\_0}{y + x}}{y + x}\\
                            
                            \mathbf{else}:\\
                            \;\;\;\;\frac{\frac{x \cdot t\_0}{y + 1}}{y + x}\\
                            
                            
                            \end{array}
                            \end{array}
                            
                            Derivation
                            1. Split input into 2 regimes
                            2. if x < -1

                              1. Initial program 55.7%

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                2. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                4. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                5. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                10. +-lowering-+.f6455.7%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                              3. Simplified55.7%

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                              4. Add Preprocessing
                              5. Step-by-step derivation
                                1. associate-/r*N/A

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

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

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                5. /-lowering-/.f64N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                7. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                8. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                10. associate-+r+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                11. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                12. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                13. +-lowering-+.f6499.8%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                              6. Applied egg-rr99.8%

                                \[\leadsto \color{blue}{\frac{\frac{x \cdot \frac{y}{x + y}}{\left(x + y\right) + 1}}{x + y}} \]
                              7. Step-by-step derivation
                                1. associate-/l*N/A

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

                                  \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{y}{x + y}}{\left(x + y\right) + 1} \cdot x\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                                3. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{y}{x + y}}{\left(x + y\right) + 1}\right), x\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                                4. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{y}{x + y}\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                5. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(x + y\right)\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                6. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                7. +-commutativeN/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(\left(y + x\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                8. associate-+l+N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(y + \left(x + 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                9. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \left(x + 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                10. +-lowering-+.f6499.8%

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                              8. Applied egg-rr99.8%

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

                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \color{blue}{x}\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                              10. Step-by-step derivation
                                1. Simplified99.8%

                                  \[\leadsto \frac{\frac{\frac{y}{x + y}}{y + \color{blue}{x}} \cdot x}{x + y} \]

                                if -1 < x

                                1. Initial program 76.7%

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

                                    \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                  2. *-lowering-*.f64N/A

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

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                  4. *-lowering-*.f64N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                  5. +-lowering-+.f64N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                  6. *-lowering-*.f64N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                  7. +-lowering-+.f64N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                  8. associate-+l+N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                  9. +-lowering-+.f64N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                  10. +-lowering-+.f6476.7%

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                3. Simplified76.7%

                                  \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                4. Add Preprocessing
                                5. Step-by-step derivation
                                  1. associate-/r*N/A

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

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

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

                                    \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                  5. /-lowering-/.f64N/A

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

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                  7. *-lowering-*.f64N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                  8. /-lowering-/.f64N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                  9. +-lowering-+.f64N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                  10. associate-+r+N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                  11. +-lowering-+.f64N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                  12. +-lowering-+.f64N/A

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                  13. +-lowering-+.f6499.9%

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                                6. Applied egg-rr99.9%

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

                                  \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\color{blue}{y}, 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                8. Step-by-step derivation
                                  1. Simplified82.6%

                                    \[\leadsto \frac{\frac{x \cdot \frac{y}{x + y}}{\color{blue}{y} + 1}}{x + y} \]
                                9. Recombined 2 regimes into one program.
                                10. Final simplification86.9%

                                  \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -1:\\ \;\;\;\;\frac{x \cdot \frac{\frac{y}{y + x}}{y + x}}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x \cdot \frac{y}{y + x}}{y + 1}}{y + x}\\ \end{array} \]
                                11. Add Preprocessing

                                Alternative 10: 82.9% accurate, 0.9× speedup?

                                \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 8.5 \cdot 10^{-143}:\\ \;\;\;\;\frac{\frac{y}{\left(y + x\right) + 1}}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot \frac{1}{y + \left(x + 1\right)}}{y + x}\\ \end{array} \end{array} \]
                                NOTE: x and y should be sorted in increasing order before calling this function.
                                (FPCore (x y)
                                 :precision binary64
                                 (if (<= y 8.5e-143)
                                   (/ (/ y (+ (+ y x) 1.0)) (+ y x))
                                   (/ (* x (/ 1.0 (+ y (+ x 1.0)))) (+ y x))))
                                assert(x < y);
                                double code(double x, double y) {
                                	double tmp;
                                	if (y <= 8.5e-143) {
                                		tmp = (y / ((y + x) + 1.0)) / (y + x);
                                	} else {
                                		tmp = (x * (1.0 / (y + (x + 1.0)))) / (y + x);
                                	}
                                	return tmp;
                                }
                                
                                NOTE: x and y should be sorted in increasing order before calling this function.
                                real(8) function code(x, y)
                                    real(8), intent (in) :: x
                                    real(8), intent (in) :: y
                                    real(8) :: tmp
                                    if (y <= 8.5d-143) then
                                        tmp = (y / ((y + x) + 1.0d0)) / (y + x)
                                    else
                                        tmp = (x * (1.0d0 / (y + (x + 1.0d0)))) / (y + x)
                                    end if
                                    code = tmp
                                end function
                                
                                assert x < y;
                                public static double code(double x, double y) {
                                	double tmp;
                                	if (y <= 8.5e-143) {
                                		tmp = (y / ((y + x) + 1.0)) / (y + x);
                                	} else {
                                		tmp = (x * (1.0 / (y + (x + 1.0)))) / (y + x);
                                	}
                                	return tmp;
                                }
                                
                                [x, y] = sort([x, y])
                                def code(x, y):
                                	tmp = 0
                                	if y <= 8.5e-143:
                                		tmp = (y / ((y + x) + 1.0)) / (y + x)
                                	else:
                                		tmp = (x * (1.0 / (y + (x + 1.0)))) / (y + x)
                                	return tmp
                                
                                x, y = sort([x, y])
                                function code(x, y)
                                	tmp = 0.0
                                	if (y <= 8.5e-143)
                                		tmp = Float64(Float64(y / Float64(Float64(y + x) + 1.0)) / Float64(y + x));
                                	else
                                		tmp = Float64(Float64(x * Float64(1.0 / Float64(y + Float64(x + 1.0)))) / Float64(y + x));
                                	end
                                	return tmp
                                end
                                
                                x, y = num2cell(sort([x, y])){:}
                                function tmp_2 = code(x, y)
                                	tmp = 0.0;
                                	if (y <= 8.5e-143)
                                		tmp = (y / ((y + x) + 1.0)) / (y + x);
                                	else
                                		tmp = (x * (1.0 / (y + (x + 1.0)))) / (y + x);
                                	end
                                	tmp_2 = tmp;
                                end
                                
                                NOTE: x and y should be sorted in increasing order before calling this function.
                                code[x_, y_] := If[LessEqual[y, 8.5e-143], N[(N[(y / N[(N[(y + x), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 / N[(y + N[(x + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]]
                                
                                \begin{array}{l}
                                [x, y] = \mathsf{sort}([x, y])\\
                                \\
                                \begin{array}{l}
                                \mathbf{if}\;y \leq 8.5 \cdot 10^{-143}:\\
                                \;\;\;\;\frac{\frac{y}{\left(y + x\right) + 1}}{y + x}\\
                                
                                \mathbf{else}:\\
                                \;\;\;\;\frac{x \cdot \frac{1}{y + \left(x + 1\right)}}{y + x}\\
                                
                                
                                \end{array}
                                \end{array}
                                
                                Derivation
                                1. Split input into 2 regimes
                                2. if y < 8.50000000000000072e-143

                                  1. Initial program 72.6%

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

                                      \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                    2. *-lowering-*.f64N/A

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

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                    4. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                    5. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                    6. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                    7. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                    8. associate-+l+N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                    9. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                    10. +-lowering-+.f6472.6%

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                  3. Simplified72.6%

                                    \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                  4. Add Preprocessing
                                  5. Step-by-step derivation
                                    1. associate-/r*N/A

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

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

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

                                      \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                    5. /-lowering-/.f64N/A

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

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                    7. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                    8. /-lowering-/.f64N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                    9. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                    10. associate-+r+N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                    11. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                    12. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                    13. +-lowering-+.f6499.9%

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                                  6. Applied egg-rr99.9%

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

                                    \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\color{blue}{y}, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                  8. Step-by-step derivation
                                    1. Simplified61.4%

                                      \[\leadsto \frac{\frac{\color{blue}{y}}{\left(x + y\right) + 1}}{x + y} \]

                                    if 8.50000000000000072e-143 < y

                                    1. Initial program 69.7%

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

                                        \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                      2. *-lowering-*.f64N/A

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

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                      4. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                      5. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                      6. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                      7. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                      8. associate-+l+N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                      9. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                      10. +-lowering-+.f6469.7%

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                    3. Simplified69.7%

                                      \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                    4. Add Preprocessing
                                    5. Step-by-step derivation
                                      1. associate-/r*N/A

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

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

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

                                        \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                      5. /-lowering-/.f64N/A

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

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                      7. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                      8. /-lowering-/.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                      9. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                      10. associate-+r+N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                      11. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                      12. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                      13. +-lowering-+.f6499.8%

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                                    6. Applied egg-rr99.8%

                                      \[\leadsto \color{blue}{\frac{\frac{x \cdot \frac{y}{x + y}}{\left(x + y\right) + 1}}{x + y}} \]
                                    7. Step-by-step derivation
                                      1. associate-/l*N/A

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

                                        \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{y}{x + y}}{\left(x + y\right) + 1} \cdot x\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                                      3. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{y}{x + y}}{\left(x + y\right) + 1}\right), x\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                                      4. /-lowering-/.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{y}{x + y}\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                      5. /-lowering-/.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(x + y\right)\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                      6. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(\left(x + y\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                      7. +-commutativeN/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(\left(y + x\right) + 1\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                      8. associate-+l+N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(y + \left(x + 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                      9. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \left(x + 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                      10. +-lowering-+.f6499.9%

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                    8. Applied egg-rr99.9%

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

                                      \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\color{blue}{1}, \mathsf{+.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right)\right), x\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                    10. Step-by-step derivation
                                      1. Simplified65.9%

                                        \[\leadsto \frac{\frac{\color{blue}{1}}{y + \left(x + 1\right)} \cdot x}{x + y} \]
                                    11. Recombined 2 regimes into one program.
                                    12. Final simplification63.2%

                                      \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 8.5 \cdot 10^{-143}:\\ \;\;\;\;\frac{\frac{y}{\left(y + x\right) + 1}}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot \frac{1}{y + \left(x + 1\right)}}{y + x}\\ \end{array} \]
                                    13. Add Preprocessing

                                    Alternative 11: 99.8% accurate, 1.0× speedup?

                                    \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \frac{x}{\left(y + x\right) + 1} \cdot \frac{\frac{y}{y + x}}{y + x} \end{array} \]
                                    NOTE: x and y should be sorted in increasing order before calling this function.
                                    (FPCore (x y)
                                     :precision binary64
                                     (* (/ x (+ (+ y x) 1.0)) (/ (/ y (+ y x)) (+ y x))))
                                    assert(x < y);
                                    double code(double x, double y) {
                                    	return (x / ((y + x) + 1.0)) * ((y / (y + x)) / (y + x));
                                    }
                                    
                                    NOTE: x and y should be sorted in increasing order before calling this function.
                                    real(8) function code(x, y)
                                        real(8), intent (in) :: x
                                        real(8), intent (in) :: y
                                        code = (x / ((y + x) + 1.0d0)) * ((y / (y + x)) / (y + x))
                                    end function
                                    
                                    assert x < y;
                                    public static double code(double x, double y) {
                                    	return (x / ((y + x) + 1.0)) * ((y / (y + x)) / (y + x));
                                    }
                                    
                                    [x, y] = sort([x, y])
                                    def code(x, y):
                                    	return (x / ((y + x) + 1.0)) * ((y / (y + x)) / (y + x))
                                    
                                    x, y = sort([x, y])
                                    function code(x, y)
                                    	return Float64(Float64(x / Float64(Float64(y + x) + 1.0)) * Float64(Float64(y / Float64(y + x)) / Float64(y + x)))
                                    end
                                    
                                    x, y = num2cell(sort([x, y])){:}
                                    function tmp = code(x, y)
                                    	tmp = (x / ((y + x) + 1.0)) * ((y / (y + x)) / (y + x));
                                    end
                                    
                                    NOTE: x and y should be sorted in increasing order before calling this function.
                                    code[x_, y_] := N[(N[(x / N[(N[(y + x), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision] * N[(N[(y / N[(y + x), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                                    
                                    \begin{array}{l}
                                    [x, y] = \mathsf{sort}([x, y])\\
                                    \\
                                    \frac{x}{\left(y + x\right) + 1} \cdot \frac{\frac{y}{y + x}}{y + x}
                                    \end{array}
                                    
                                    Derivation
                                    1. Initial program 71.5%

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

                                        \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                      2. *-lowering-*.f64N/A

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

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                      4. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                      5. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                      6. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                      7. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                      8. associate-+l+N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                      9. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                      10. +-lowering-+.f6471.5%

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                    3. Simplified71.5%

                                      \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                    4. Add Preprocessing
                                    5. Step-by-step derivation
                                      1. associate-/r*N/A

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

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

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

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

                                        \[\leadsto \mathsf{*.f64}\left(\left(\frac{x}{x + \left(y + 1\right)}\right), \color{blue}{\left(\frac{\frac{y}{x + y}}{x + y}\right)}\right) \]
                                      6. /-lowering-/.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(x, \left(x + \left(y + 1\right)\right)\right), \left(\frac{\color{blue}{\frac{y}{x + y}}}{x + y}\right)\right) \]
                                      7. associate-+r+N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(x, \left(\left(x + y\right) + 1\right)\right), \left(\frac{\frac{y}{\color{blue}{x + y}}}{x + y}\right)\right) \]
                                      8. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(\frac{\frac{y}{\color{blue}{x + y}}}{x + y}\right)\right) \]
                                      9. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(\frac{\frac{y}{\color{blue}{x} + y}}{x + y}\right)\right) \]
                                      10. /-lowering-/.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{/.f64}\left(\left(\frac{y}{x + y}\right), \color{blue}{\left(x + y\right)}\right)\right) \]
                                      11. /-lowering-/.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(x + y\right)\right), \left(\color{blue}{x} + y\right)\right)\right) \]
                                      12. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \left(x + y\right)\right)\right) \]
                                      13. +-lowering-+.f6499.7%

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right)\right) \]
                                    6. Applied egg-rr99.7%

                                      \[\leadsto \color{blue}{\frac{x}{\left(x + y\right) + 1} \cdot \frac{\frac{y}{x + y}}{x + y}} \]
                                    7. Final simplification99.7%

                                      \[\leadsto \frac{x}{\left(y + x\right) + 1} \cdot \frac{\frac{y}{y + x}}{y + x} \]
                                    8. Add Preprocessing

                                    Alternative 12: 82.9% accurate, 1.1× speedup?

                                    \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} t_0 := \left(y + x\right) + 1\\ \mathbf{if}\;y \leq 8.5 \cdot 10^{-143}:\\ \;\;\;\;\frac{\frac{y}{t\_0}}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t\_0}}{y + x}\\ \end{array} \end{array} \]
                                    NOTE: x and y should be sorted in increasing order before calling this function.
                                    (FPCore (x y)
                                     :precision binary64
                                     (let* ((t_0 (+ (+ y x) 1.0)))
                                       (if (<= y 8.5e-143) (/ (/ y t_0) (+ y x)) (/ (/ x t_0) (+ y x)))))
                                    assert(x < y);
                                    double code(double x, double y) {
                                    	double t_0 = (y + x) + 1.0;
                                    	double tmp;
                                    	if (y <= 8.5e-143) {
                                    		tmp = (y / t_0) / (y + x);
                                    	} else {
                                    		tmp = (x / t_0) / (y + x);
                                    	}
                                    	return tmp;
                                    }
                                    
                                    NOTE: x and y should be sorted in increasing order before calling this function.
                                    real(8) function code(x, y)
                                        real(8), intent (in) :: x
                                        real(8), intent (in) :: y
                                        real(8) :: t_0
                                        real(8) :: tmp
                                        t_0 = (y + x) + 1.0d0
                                        if (y <= 8.5d-143) then
                                            tmp = (y / t_0) / (y + x)
                                        else
                                            tmp = (x / t_0) / (y + x)
                                        end if
                                        code = tmp
                                    end function
                                    
                                    assert x < y;
                                    public static double code(double x, double y) {
                                    	double t_0 = (y + x) + 1.0;
                                    	double tmp;
                                    	if (y <= 8.5e-143) {
                                    		tmp = (y / t_0) / (y + x);
                                    	} else {
                                    		tmp = (x / t_0) / (y + x);
                                    	}
                                    	return tmp;
                                    }
                                    
                                    [x, y] = sort([x, y])
                                    def code(x, y):
                                    	t_0 = (y + x) + 1.0
                                    	tmp = 0
                                    	if y <= 8.5e-143:
                                    		tmp = (y / t_0) / (y + x)
                                    	else:
                                    		tmp = (x / t_0) / (y + x)
                                    	return tmp
                                    
                                    x, y = sort([x, y])
                                    function code(x, y)
                                    	t_0 = Float64(Float64(y + x) + 1.0)
                                    	tmp = 0.0
                                    	if (y <= 8.5e-143)
                                    		tmp = Float64(Float64(y / t_0) / Float64(y + x));
                                    	else
                                    		tmp = Float64(Float64(x / t_0) / Float64(y + x));
                                    	end
                                    	return tmp
                                    end
                                    
                                    x, y = num2cell(sort([x, y])){:}
                                    function tmp_2 = code(x, y)
                                    	t_0 = (y + x) + 1.0;
                                    	tmp = 0.0;
                                    	if (y <= 8.5e-143)
                                    		tmp = (y / t_0) / (y + x);
                                    	else
                                    		tmp = (x / t_0) / (y + x);
                                    	end
                                    	tmp_2 = tmp;
                                    end
                                    
                                    NOTE: x and y should be sorted in increasing order before calling this function.
                                    code[x_, y_] := Block[{t$95$0 = N[(N[(y + x), $MachinePrecision] + 1.0), $MachinePrecision]}, If[LessEqual[y, 8.5e-143], N[(N[(y / t$95$0), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision], N[(N[(x / t$95$0), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]]]
                                    
                                    \begin{array}{l}
                                    [x, y] = \mathsf{sort}([x, y])\\
                                    \\
                                    \begin{array}{l}
                                    t_0 := \left(y + x\right) + 1\\
                                    \mathbf{if}\;y \leq 8.5 \cdot 10^{-143}:\\
                                    \;\;\;\;\frac{\frac{y}{t\_0}}{y + x}\\
                                    
                                    \mathbf{else}:\\
                                    \;\;\;\;\frac{\frac{x}{t\_0}}{y + x}\\
                                    
                                    
                                    \end{array}
                                    \end{array}
                                    
                                    Derivation
                                    1. Split input into 2 regimes
                                    2. if y < 8.50000000000000072e-143

                                      1. Initial program 72.6%

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

                                          \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                        2. *-lowering-*.f64N/A

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

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                        4. *-lowering-*.f64N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                        5. +-lowering-+.f64N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                        6. *-lowering-*.f64N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                        7. +-lowering-+.f64N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                        8. associate-+l+N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                        9. +-lowering-+.f64N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                        10. +-lowering-+.f6472.6%

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                      3. Simplified72.6%

                                        \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                      4. Add Preprocessing
                                      5. Step-by-step derivation
                                        1. associate-/r*N/A

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

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

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

                                          \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                        5. /-lowering-/.f64N/A

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

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                        7. *-lowering-*.f64N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                        8. /-lowering-/.f64N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                        9. +-lowering-+.f64N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                        10. associate-+r+N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                        11. +-lowering-+.f64N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                        12. +-lowering-+.f64N/A

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                        13. +-lowering-+.f6499.9%

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                                      6. Applied egg-rr99.9%

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

                                        \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\color{blue}{y}, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                      8. Step-by-step derivation
                                        1. Simplified61.4%

                                          \[\leadsto \frac{\frac{\color{blue}{y}}{\left(x + y\right) + 1}}{x + y} \]

                                        if 8.50000000000000072e-143 < y

                                        1. Initial program 69.7%

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

                                            \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                          2. *-lowering-*.f64N/A

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

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                          4. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                          5. +-lowering-+.f64N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                          6. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                          7. +-lowering-+.f64N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                          8. associate-+l+N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                          9. +-lowering-+.f64N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                          10. +-lowering-+.f6469.7%

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                        3. Simplified69.7%

                                          \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                        4. Add Preprocessing
                                        5. Step-by-step derivation
                                          1. associate-/r*N/A

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

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

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

                                            \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                          5. /-lowering-/.f64N/A

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

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                          7. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                          8. /-lowering-/.f64N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                          9. +-lowering-+.f64N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                          10. associate-+r+N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                          11. +-lowering-+.f64N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                          12. +-lowering-+.f64N/A

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                          13. +-lowering-+.f6499.8%

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                                        6. Applied egg-rr99.8%

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

                                          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\color{blue}{x}, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                        8. Step-by-step derivation
                                          1. Simplified65.8%

                                            \[\leadsto \frac{\frac{\color{blue}{x}}{\left(x + y\right) + 1}}{x + y} \]
                                        9. Recombined 2 regimes into one program.
                                        10. Final simplification63.2%

                                          \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 8.5 \cdot 10^{-143}:\\ \;\;\;\;\frac{\frac{y}{\left(y + x\right) + 1}}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{\left(y + x\right) + 1}}{y + x}\\ \end{array} \]
                                        11. Add Preprocessing

                                        Alternative 13: 82.9% accurate, 1.1× speedup?

                                        \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 8.5 \cdot 10^{-143}:\\ \;\;\;\;\frac{\frac{y}{x}}{x + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{\left(y + x\right) + 1}}{y + x}\\ \end{array} \end{array} \]
                                        NOTE: x and y should be sorted in increasing order before calling this function.
                                        (FPCore (x y)
                                         :precision binary64
                                         (if (<= y 8.5e-143) (/ (/ y x) (+ x 1.0)) (/ (/ x (+ (+ y x) 1.0)) (+ y x))))
                                        assert(x < y);
                                        double code(double x, double y) {
                                        	double tmp;
                                        	if (y <= 8.5e-143) {
                                        		tmp = (y / x) / (x + 1.0);
                                        	} else {
                                        		tmp = (x / ((y + x) + 1.0)) / (y + x);
                                        	}
                                        	return tmp;
                                        }
                                        
                                        NOTE: x and y should be sorted in increasing order before calling this function.
                                        real(8) function code(x, y)
                                            real(8), intent (in) :: x
                                            real(8), intent (in) :: y
                                            real(8) :: tmp
                                            if (y <= 8.5d-143) then
                                                tmp = (y / x) / (x + 1.0d0)
                                            else
                                                tmp = (x / ((y + x) + 1.0d0)) / (y + x)
                                            end if
                                            code = tmp
                                        end function
                                        
                                        assert x < y;
                                        public static double code(double x, double y) {
                                        	double tmp;
                                        	if (y <= 8.5e-143) {
                                        		tmp = (y / x) / (x + 1.0);
                                        	} else {
                                        		tmp = (x / ((y + x) + 1.0)) / (y + x);
                                        	}
                                        	return tmp;
                                        }
                                        
                                        [x, y] = sort([x, y])
                                        def code(x, y):
                                        	tmp = 0
                                        	if y <= 8.5e-143:
                                        		tmp = (y / x) / (x + 1.0)
                                        	else:
                                        		tmp = (x / ((y + x) + 1.0)) / (y + x)
                                        	return tmp
                                        
                                        x, y = sort([x, y])
                                        function code(x, y)
                                        	tmp = 0.0
                                        	if (y <= 8.5e-143)
                                        		tmp = Float64(Float64(y / x) / Float64(x + 1.0));
                                        	else
                                        		tmp = Float64(Float64(x / Float64(Float64(y + x) + 1.0)) / Float64(y + x));
                                        	end
                                        	return tmp
                                        end
                                        
                                        x, y = num2cell(sort([x, y])){:}
                                        function tmp_2 = code(x, y)
                                        	tmp = 0.0;
                                        	if (y <= 8.5e-143)
                                        		tmp = (y / x) / (x + 1.0);
                                        	else
                                        		tmp = (x / ((y + x) + 1.0)) / (y + x);
                                        	end
                                        	tmp_2 = tmp;
                                        end
                                        
                                        NOTE: x and y should be sorted in increasing order before calling this function.
                                        code[x_, y_] := If[LessEqual[y, 8.5e-143], N[(N[(y / x), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], N[(N[(x / N[(N[(y + x), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]]
                                        
                                        \begin{array}{l}
                                        [x, y] = \mathsf{sort}([x, y])\\
                                        \\
                                        \begin{array}{l}
                                        \mathbf{if}\;y \leq 8.5 \cdot 10^{-143}:\\
                                        \;\;\;\;\frac{\frac{y}{x}}{x + 1}\\
                                        
                                        \mathbf{else}:\\
                                        \;\;\;\;\frac{\frac{x}{\left(y + x\right) + 1}}{y + x}\\
                                        
                                        
                                        \end{array}
                                        \end{array}
                                        
                                        Derivation
                                        1. Split input into 2 regimes
                                        2. if y < 8.50000000000000072e-143

                                          1. Initial program 72.6%

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

                                              \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                            2. *-lowering-*.f64N/A

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

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                            4. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                            5. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                            6. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                            7. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                            8. associate-+l+N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                            9. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                            10. +-lowering-+.f6472.6%

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                          3. Simplified72.6%

                                            \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                          4. Add Preprocessing
                                          5. Taylor expanded in y around 0

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

                                              \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                                            2. /-lowering-/.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                                            3. /-lowering-/.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                                            4. +-commutativeN/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                                            5. +-lowering-+.f6460.4%

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                                          7. Simplified60.4%

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

                                          if 8.50000000000000072e-143 < y

                                          1. Initial program 69.7%

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

                                              \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                            2. *-lowering-*.f64N/A

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

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                            4. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                            5. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                            6. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                            7. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                            8. associate-+l+N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                            9. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                            10. +-lowering-+.f6469.7%

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                          3. Simplified69.7%

                                            \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                          4. Add Preprocessing
                                          5. Step-by-step derivation
                                            1. associate-/r*N/A

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

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

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

                                              \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                            5. /-lowering-/.f64N/A

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

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                            7. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                            8. /-lowering-/.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                            9. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                            10. associate-+r+N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                            11. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                            12. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                            13. +-lowering-+.f6499.8%

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                                          6. Applied egg-rr99.8%

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

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\color{blue}{x}, \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                          8. Step-by-step derivation
                                            1. Simplified65.8%

                                              \[\leadsto \frac{\frac{\color{blue}{x}}{\left(x + y\right) + 1}}{x + y} \]
                                          9. Recombined 2 regimes into one program.
                                          10. Final simplification62.5%

                                            \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 8.5 \cdot 10^{-143}:\\ \;\;\;\;\frac{\frac{y}{x}}{x + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{\left(y + x\right) + 1}}{y + x}\\ \end{array} \]
                                          11. Add Preprocessing

                                          Alternative 14: 64.8% accurate, 1.1× speedup?

                                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 2.4 \cdot 10^{-129}:\\ \;\;\;\;\frac{y}{x}\\ \mathbf{elif}\;y \leq 1:\\ \;\;\;\;\frac{x}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{y \cdot y}\\ \end{array} \end{array} \]
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          (FPCore (x y)
                                           :precision binary64
                                           (if (<= y 2.4e-129) (/ y x) (if (<= y 1.0) (/ x y) (/ x (* y y)))))
                                          assert(x < y);
                                          double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 2.4e-129) {
                                          		tmp = y / x;
                                          	} else if (y <= 1.0) {
                                          		tmp = x / y;
                                          	} else {
                                          		tmp = x / (y * y);
                                          	}
                                          	return tmp;
                                          }
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          real(8) function code(x, y)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              real(8) :: tmp
                                              if (y <= 2.4d-129) then
                                                  tmp = y / x
                                              else if (y <= 1.0d0) then
                                                  tmp = x / y
                                              else
                                                  tmp = x / (y * y)
                                              end if
                                              code = tmp
                                          end function
                                          
                                          assert x < y;
                                          public static double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 2.4e-129) {
                                          		tmp = y / x;
                                          	} else if (y <= 1.0) {
                                          		tmp = x / y;
                                          	} else {
                                          		tmp = x / (y * y);
                                          	}
                                          	return tmp;
                                          }
                                          
                                          [x, y] = sort([x, y])
                                          def code(x, y):
                                          	tmp = 0
                                          	if y <= 2.4e-129:
                                          		tmp = y / x
                                          	elif y <= 1.0:
                                          		tmp = x / y
                                          	else:
                                          		tmp = x / (y * y)
                                          	return tmp
                                          
                                          x, y = sort([x, y])
                                          function code(x, y)
                                          	tmp = 0.0
                                          	if (y <= 2.4e-129)
                                          		tmp = Float64(y / x);
                                          	elseif (y <= 1.0)
                                          		tmp = Float64(x / y);
                                          	else
                                          		tmp = Float64(x / Float64(y * y));
                                          	end
                                          	return tmp
                                          end
                                          
                                          x, y = num2cell(sort([x, y])){:}
                                          function tmp_2 = code(x, y)
                                          	tmp = 0.0;
                                          	if (y <= 2.4e-129)
                                          		tmp = y / x;
                                          	elseif (y <= 1.0)
                                          		tmp = x / y;
                                          	else
                                          		tmp = x / (y * y);
                                          	end
                                          	tmp_2 = tmp;
                                          end
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          code[x_, y_] := If[LessEqual[y, 2.4e-129], N[(y / x), $MachinePrecision], If[LessEqual[y, 1.0], N[(x / y), $MachinePrecision], N[(x / N[(y * y), $MachinePrecision]), $MachinePrecision]]]
                                          
                                          \begin{array}{l}
                                          [x, y] = \mathsf{sort}([x, y])\\
                                          \\
                                          \begin{array}{l}
                                          \mathbf{if}\;y \leq 2.4 \cdot 10^{-129}:\\
                                          \;\;\;\;\frac{y}{x}\\
                                          
                                          \mathbf{elif}\;y \leq 1:\\
                                          \;\;\;\;\frac{x}{y}\\
                                          
                                          \mathbf{else}:\\
                                          \;\;\;\;\frac{x}{y \cdot y}\\
                                          
                                          
                                          \end{array}
                                          \end{array}
                                          
                                          Derivation
                                          1. Split input into 3 regimes
                                          2. if y < 2.39999999999999989e-129

                                            1. Initial program 72.5%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6472.5%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified72.5%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Taylor expanded in y around 0

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

                                                \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                                              2. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                                              3. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                                              4. +-commutativeN/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                                              5. +-lowering-+.f6460.5%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                                            7. Simplified60.5%

                                              \[\leadsto \color{blue}{\frac{\frac{y}{x}}{x + 1}} \]
                                            8. Taylor expanded in x around 0

                                              \[\leadsto \color{blue}{\frac{y}{x}} \]
                                            9. Step-by-step derivation
                                              1. /-lowering-/.f6435.7%

                                                \[\leadsto \mathsf{/.f64}\left(y, \color{blue}{x}\right) \]
                                            10. Simplified35.7%

                                              \[\leadsto \color{blue}{\frac{y}{x}} \]

                                            if 2.39999999999999989e-129 < y < 1

                                            1. Initial program 90.9%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6491.0%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified91.0%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Taylor expanded in x around 0

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

                                                \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left(y \cdot \left(1 + y\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{\left(1 + y\right)}\right)\right) \]
                                              3. +-commutativeN/A

                                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \left(y + \color{blue}{1}\right)\right)\right) \]
                                              4. +-lowering-+.f6445.5%

                                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right) \]
                                            7. Simplified45.5%

                                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(y + 1\right)}} \]
                                            8. Taylor expanded in y around 0

                                              \[\leadsto \color{blue}{\frac{x}{y}} \]
                                            9. Step-by-step derivation
                                              1. /-lowering-/.f6443.6%

                                                \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{y}\right) \]
                                            10. Simplified43.6%

                                              \[\leadsto \color{blue}{\frac{x}{y}} \]

                                            if 1 < y

                                            1. Initial program 60.7%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6460.7%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified60.7%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Taylor expanded in y around inf

                                              \[\leadsto \color{blue}{\frac{x}{{y}^{2}}} \]
                                            6. Step-by-step derivation
                                              1. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left({y}^{2}\right)}\right) \]
                                              2. unpow2N/A

                                                \[\leadsto \mathsf{/.f64}\left(x, \left(y \cdot \color{blue}{y}\right)\right) \]
                                              3. *-lowering-*.f6476.0%

                                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right) \]
                                            7. Simplified76.0%

                                              \[\leadsto \color{blue}{\frac{x}{y \cdot y}} \]
                                          3. Recombined 3 regimes into one program.
                                          4. Add Preprocessing

                                          Alternative 15: 82.8% accurate, 1.2× speedup?

                                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 2.45 \cdot 10^{-129}:\\ \;\;\;\;\frac{\frac{y}{x + 1}}{y + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{y + 1}}{y + x}\\ \end{array} \end{array} \]
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          (FPCore (x y)
                                           :precision binary64
                                           (if (<= y 2.45e-129) (/ (/ y (+ x 1.0)) (+ y x)) (/ (/ x (+ y 1.0)) (+ y x))))
                                          assert(x < y);
                                          double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 2.45e-129) {
                                          		tmp = (y / (x + 1.0)) / (y + x);
                                          	} else {
                                          		tmp = (x / (y + 1.0)) / (y + x);
                                          	}
                                          	return tmp;
                                          }
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          real(8) function code(x, y)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              real(8) :: tmp
                                              if (y <= 2.45d-129) then
                                                  tmp = (y / (x + 1.0d0)) / (y + x)
                                              else
                                                  tmp = (x / (y + 1.0d0)) / (y + x)
                                              end if
                                              code = tmp
                                          end function
                                          
                                          assert x < y;
                                          public static double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 2.45e-129) {
                                          		tmp = (y / (x + 1.0)) / (y + x);
                                          	} else {
                                          		tmp = (x / (y + 1.0)) / (y + x);
                                          	}
                                          	return tmp;
                                          }
                                          
                                          [x, y] = sort([x, y])
                                          def code(x, y):
                                          	tmp = 0
                                          	if y <= 2.45e-129:
                                          		tmp = (y / (x + 1.0)) / (y + x)
                                          	else:
                                          		tmp = (x / (y + 1.0)) / (y + x)
                                          	return tmp
                                          
                                          x, y = sort([x, y])
                                          function code(x, y)
                                          	tmp = 0.0
                                          	if (y <= 2.45e-129)
                                          		tmp = Float64(Float64(y / Float64(x + 1.0)) / Float64(y + x));
                                          	else
                                          		tmp = Float64(Float64(x / Float64(y + 1.0)) / Float64(y + x));
                                          	end
                                          	return tmp
                                          end
                                          
                                          x, y = num2cell(sort([x, y])){:}
                                          function tmp_2 = code(x, y)
                                          	tmp = 0.0;
                                          	if (y <= 2.45e-129)
                                          		tmp = (y / (x + 1.0)) / (y + x);
                                          	else
                                          		tmp = (x / (y + 1.0)) / (y + x);
                                          	end
                                          	tmp_2 = tmp;
                                          end
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          code[x_, y_] := If[LessEqual[y, 2.45e-129], N[(N[(y / N[(x + 1.0), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision], N[(N[(x / N[(y + 1.0), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]]
                                          
                                          \begin{array}{l}
                                          [x, y] = \mathsf{sort}([x, y])\\
                                          \\
                                          \begin{array}{l}
                                          \mathbf{if}\;y \leq 2.45 \cdot 10^{-129}:\\
                                          \;\;\;\;\frac{\frac{y}{x + 1}}{y + x}\\
                                          
                                          \mathbf{else}:\\
                                          \;\;\;\;\frac{\frac{x}{y + 1}}{y + x}\\
                                          
                                          
                                          \end{array}
                                          \end{array}
                                          
                                          Derivation
                                          1. Split input into 2 regimes
                                          2. if y < 2.45000000000000001e-129

                                            1. Initial program 72.5%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6472.5%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified72.5%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Step-by-step derivation
                                              1. associate-/r*N/A

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

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

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                              5. /-lowering-/.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              7. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              8. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              10. associate-+r+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                              11. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                              12. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                              13. +-lowering-+.f6499.9%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                                            6. Applied egg-rr99.9%

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

                                              \[\leadsto \mathsf{/.f64}\left(\color{blue}{\left(\frac{y}{1 + x}\right)}, \mathsf{+.f64}\left(x, y\right)\right) \]
                                            8. Step-by-step derivation
                                              1. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(1 + x\right)\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                                              2. +-commutativeN/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(x + 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                              3. +-lowering-+.f6461.0%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                            9. Simplified61.0%

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

                                            if 2.45000000000000001e-129 < y

                                            1. Initial program 69.7%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6469.8%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified69.8%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Step-by-step derivation
                                              1. associate-/r*N/A

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

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

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                              5. /-lowering-/.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              7. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              8. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              10. associate-+r+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                              11. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                              12. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                              13. +-lowering-+.f6499.8%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                                            6. Applied egg-rr99.8%

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

                                              \[\leadsto \mathsf{/.f64}\left(\color{blue}{\left(\frac{x}{1 + y}\right)}, \mathsf{+.f64}\left(x, y\right)\right) \]
                                            8. Step-by-step derivation
                                              1. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, \left(1 + y\right)\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                                              2. +-commutativeN/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, \left(y + 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                              3. +-lowering-+.f6466.2%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(y, 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                            9. Simplified66.2%

                                              \[\leadsto \frac{\color{blue}{\frac{x}{y + 1}}}{x + y} \]
                                          3. Recombined 2 regimes into one program.
                                          4. Final simplification62.9%

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

                                          Alternative 16: 82.9% accurate, 1.2× speedup?

                                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 2.65 \cdot 10^{-129}:\\ \;\;\;\;\frac{\frac{y}{x}}{x + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{y + 1}}{y + x}\\ \end{array} \end{array} \]
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          (FPCore (x y)
                                           :precision binary64
                                           (if (<= y 2.65e-129) (/ (/ y x) (+ x 1.0)) (/ (/ x (+ y 1.0)) (+ y x))))
                                          assert(x < y);
                                          double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 2.65e-129) {
                                          		tmp = (y / x) / (x + 1.0);
                                          	} else {
                                          		tmp = (x / (y + 1.0)) / (y + x);
                                          	}
                                          	return tmp;
                                          }
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          real(8) function code(x, y)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              real(8) :: tmp
                                              if (y <= 2.65d-129) then
                                                  tmp = (y / x) / (x + 1.0d0)
                                              else
                                                  tmp = (x / (y + 1.0d0)) / (y + x)
                                              end if
                                              code = tmp
                                          end function
                                          
                                          assert x < y;
                                          public static double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 2.65e-129) {
                                          		tmp = (y / x) / (x + 1.0);
                                          	} else {
                                          		tmp = (x / (y + 1.0)) / (y + x);
                                          	}
                                          	return tmp;
                                          }
                                          
                                          [x, y] = sort([x, y])
                                          def code(x, y):
                                          	tmp = 0
                                          	if y <= 2.65e-129:
                                          		tmp = (y / x) / (x + 1.0)
                                          	else:
                                          		tmp = (x / (y + 1.0)) / (y + x)
                                          	return tmp
                                          
                                          x, y = sort([x, y])
                                          function code(x, y)
                                          	tmp = 0.0
                                          	if (y <= 2.65e-129)
                                          		tmp = Float64(Float64(y / x) / Float64(x + 1.0));
                                          	else
                                          		tmp = Float64(Float64(x / Float64(y + 1.0)) / Float64(y + x));
                                          	end
                                          	return tmp
                                          end
                                          
                                          x, y = num2cell(sort([x, y])){:}
                                          function tmp_2 = code(x, y)
                                          	tmp = 0.0;
                                          	if (y <= 2.65e-129)
                                          		tmp = (y / x) / (x + 1.0);
                                          	else
                                          		tmp = (x / (y + 1.0)) / (y + x);
                                          	end
                                          	tmp_2 = tmp;
                                          end
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          code[x_, y_] := If[LessEqual[y, 2.65e-129], N[(N[(y / x), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], N[(N[(x / N[(y + 1.0), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]]
                                          
                                          \begin{array}{l}
                                          [x, y] = \mathsf{sort}([x, y])\\
                                          \\
                                          \begin{array}{l}
                                          \mathbf{if}\;y \leq 2.65 \cdot 10^{-129}:\\
                                          \;\;\;\;\frac{\frac{y}{x}}{x + 1}\\
                                          
                                          \mathbf{else}:\\
                                          \;\;\;\;\frac{\frac{x}{y + 1}}{y + x}\\
                                          
                                          
                                          \end{array}
                                          \end{array}
                                          
                                          Derivation
                                          1. Split input into 2 regimes
                                          2. if y < 2.64999999999999987e-129

                                            1. Initial program 72.5%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6472.5%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified72.5%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Taylor expanded in y around 0

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

                                                \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                                              2. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                                              3. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                                              4. +-commutativeN/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                                              5. +-lowering-+.f6460.5%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                                            7. Simplified60.5%

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

                                            if 2.64999999999999987e-129 < y

                                            1. Initial program 69.7%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6469.8%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified69.8%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Step-by-step derivation
                                              1. associate-/r*N/A

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

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

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                              5. /-lowering-/.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              7. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              8. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                              10. associate-+r+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                              11. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                              12. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                              13. +-lowering-+.f6499.8%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                                            6. Applied egg-rr99.8%

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

                                              \[\leadsto \mathsf{/.f64}\left(\color{blue}{\left(\frac{x}{1 + y}\right)}, \mathsf{+.f64}\left(x, y\right)\right) \]
                                            8. Step-by-step derivation
                                              1. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, \left(1 + y\right)\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                                              2. +-commutativeN/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, \left(y + 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                              3. +-lowering-+.f6466.2%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(y, 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                            9. Simplified66.2%

                                              \[\leadsto \frac{\color{blue}{\frac{x}{y + 1}}}{x + y} \]
                                          3. Recombined 2 regimes into one program.
                                          4. Final simplification62.7%

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

                                          Alternative 17: 82.6% accurate, 1.4× speedup?

                                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 2.65 \cdot 10^{-129}:\\ \;\;\;\;\frac{\frac{y}{x}}{x + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{y}}{y + 1}\\ \end{array} \end{array} \]
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          (FPCore (x y)
                                           :precision binary64
                                           (if (<= y 2.65e-129) (/ (/ y x) (+ x 1.0)) (/ (/ x y) (+ y 1.0))))
                                          assert(x < y);
                                          double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 2.65e-129) {
                                          		tmp = (y / x) / (x + 1.0);
                                          	} else {
                                          		tmp = (x / y) / (y + 1.0);
                                          	}
                                          	return tmp;
                                          }
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          real(8) function code(x, y)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              real(8) :: tmp
                                              if (y <= 2.65d-129) then
                                                  tmp = (y / x) / (x + 1.0d0)
                                              else
                                                  tmp = (x / y) / (y + 1.0d0)
                                              end if
                                              code = tmp
                                          end function
                                          
                                          assert x < y;
                                          public static double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 2.65e-129) {
                                          		tmp = (y / x) / (x + 1.0);
                                          	} else {
                                          		tmp = (x / y) / (y + 1.0);
                                          	}
                                          	return tmp;
                                          }
                                          
                                          [x, y] = sort([x, y])
                                          def code(x, y):
                                          	tmp = 0
                                          	if y <= 2.65e-129:
                                          		tmp = (y / x) / (x + 1.0)
                                          	else:
                                          		tmp = (x / y) / (y + 1.0)
                                          	return tmp
                                          
                                          x, y = sort([x, y])
                                          function code(x, y)
                                          	tmp = 0.0
                                          	if (y <= 2.65e-129)
                                          		tmp = Float64(Float64(y / x) / Float64(x + 1.0));
                                          	else
                                          		tmp = Float64(Float64(x / y) / Float64(y + 1.0));
                                          	end
                                          	return tmp
                                          end
                                          
                                          x, y = num2cell(sort([x, y])){:}
                                          function tmp_2 = code(x, y)
                                          	tmp = 0.0;
                                          	if (y <= 2.65e-129)
                                          		tmp = (y / x) / (x + 1.0);
                                          	else
                                          		tmp = (x / y) / (y + 1.0);
                                          	end
                                          	tmp_2 = tmp;
                                          end
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          code[x_, y_] := If[LessEqual[y, 2.65e-129], N[(N[(y / x), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], N[(N[(x / y), $MachinePrecision] / N[(y + 1.0), $MachinePrecision]), $MachinePrecision]]
                                          
                                          \begin{array}{l}
                                          [x, y] = \mathsf{sort}([x, y])\\
                                          \\
                                          \begin{array}{l}
                                          \mathbf{if}\;y \leq 2.65 \cdot 10^{-129}:\\
                                          \;\;\;\;\frac{\frac{y}{x}}{x + 1}\\
                                          
                                          \mathbf{else}:\\
                                          \;\;\;\;\frac{\frac{x}{y}}{y + 1}\\
                                          
                                          
                                          \end{array}
                                          \end{array}
                                          
                                          Derivation
                                          1. Split input into 2 regimes
                                          2. if y < 2.64999999999999987e-129

                                            1. Initial program 72.5%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6472.5%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified72.5%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Taylor expanded in y around 0

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

                                                \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                                              2. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                                              3. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                                              4. +-commutativeN/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                                              5. +-lowering-+.f6460.5%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                                            7. Simplified60.5%

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

                                            if 2.64999999999999987e-129 < y

                                            1. Initial program 69.7%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6469.8%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified69.8%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Taylor expanded in x around 0

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

                                                \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left(y \cdot \left(1 + y\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{\left(1 + y\right)}\right)\right) \]
                                              3. +-commutativeN/A

                                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \left(y + \color{blue}{1}\right)\right)\right) \]
                                              4. +-lowering-+.f6466.9%

                                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right) \]
                                            7. Simplified66.9%

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

                                                \[\leadsto \frac{\frac{x}{y}}{\color{blue}{y + 1}} \]
                                              2. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\left(\frac{x}{y}\right), \color{blue}{\left(y + 1\right)}\right) \]
                                              3. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, y\right), \left(\color{blue}{y} + 1\right)\right) \]
                                              4. +-lowering-+.f6465.7%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(x, y\right), \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right) \]
                                            9. Applied egg-rr65.7%

                                              \[\leadsto \color{blue}{\frac{\frac{x}{y}}{y + 1}} \]
                                          3. Recombined 2 regimes into one program.
                                          4. Add Preprocessing

                                          Alternative 18: 43.0% accurate, 2.1× speedup?

                                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;x \leq -1.75 \cdot 10^{-128}:\\ \;\;\;\;\frac{y}{x}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{y}\\ \end{array} \end{array} \]
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          (FPCore (x y) :precision binary64 (if (<= x -1.75e-128) (/ y x) (/ x y)))
                                          assert(x < y);
                                          double code(double x, double y) {
                                          	double tmp;
                                          	if (x <= -1.75e-128) {
                                          		tmp = y / x;
                                          	} else {
                                          		tmp = x / y;
                                          	}
                                          	return tmp;
                                          }
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          real(8) function code(x, y)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              real(8) :: tmp
                                              if (x <= (-1.75d-128)) then
                                                  tmp = y / x
                                              else
                                                  tmp = x / y
                                              end if
                                              code = tmp
                                          end function
                                          
                                          assert x < y;
                                          public static double code(double x, double y) {
                                          	double tmp;
                                          	if (x <= -1.75e-128) {
                                          		tmp = y / x;
                                          	} else {
                                          		tmp = x / y;
                                          	}
                                          	return tmp;
                                          }
                                          
                                          [x, y] = sort([x, y])
                                          def code(x, y):
                                          	tmp = 0
                                          	if x <= -1.75e-128:
                                          		tmp = y / x
                                          	else:
                                          		tmp = x / y
                                          	return tmp
                                          
                                          x, y = sort([x, y])
                                          function code(x, y)
                                          	tmp = 0.0
                                          	if (x <= -1.75e-128)
                                          		tmp = Float64(y / x);
                                          	else
                                          		tmp = Float64(x / y);
                                          	end
                                          	return tmp
                                          end
                                          
                                          x, y = num2cell(sort([x, y])){:}
                                          function tmp_2 = code(x, y)
                                          	tmp = 0.0;
                                          	if (x <= -1.75e-128)
                                          		tmp = y / x;
                                          	else
                                          		tmp = x / y;
                                          	end
                                          	tmp_2 = tmp;
                                          end
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          code[x_, y_] := If[LessEqual[x, -1.75e-128], N[(y / x), $MachinePrecision], N[(x / y), $MachinePrecision]]
                                          
                                          \begin{array}{l}
                                          [x, y] = \mathsf{sort}([x, y])\\
                                          \\
                                          \begin{array}{l}
                                          \mathbf{if}\;x \leq -1.75 \cdot 10^{-128}:\\
                                          \;\;\;\;\frac{y}{x}\\
                                          
                                          \mathbf{else}:\\
                                          \;\;\;\;\frac{x}{y}\\
                                          
                                          
                                          \end{array}
                                          \end{array}
                                          
                                          Derivation
                                          1. Split input into 2 regimes
                                          2. if x < -1.75e-128

                                            1. Initial program 64.0%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6464.0%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified64.0%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Taylor expanded in y around 0

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

                                                \[\leadsto \frac{\frac{y}{x}}{\color{blue}{1 + x}} \]
                                              2. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{x}\right), \color{blue}{\left(1 + x\right)}\right) \]
                                              3. /-lowering-/.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(\color{blue}{1} + x\right)\right) \]
                                              4. +-commutativeN/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \left(x + \color{blue}{1}\right)\right) \]
                                              5. +-lowering-+.f6465.2%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, x\right), \mathsf{+.f64}\left(x, \color{blue}{1}\right)\right) \]
                                            7. Simplified65.2%

                                              \[\leadsto \color{blue}{\frac{\frac{y}{x}}{x + 1}} \]
                                            8. Taylor expanded in x around 0

                                              \[\leadsto \color{blue}{\frac{y}{x}} \]
                                            9. Step-by-step derivation
                                              1. /-lowering-/.f6428.2%

                                                \[\leadsto \mathsf{/.f64}\left(y, \color{blue}{x}\right) \]
                                            10. Simplified28.2%

                                              \[\leadsto \color{blue}{\frac{y}{x}} \]

                                            if -1.75e-128 < x

                                            1. Initial program 75.2%

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

                                                \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

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

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                              5. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                              8. associate-+l+N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                              10. +-lowering-+.f6475.2%

                                                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                            3. Simplified75.2%

                                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                            4. Add Preprocessing
                                            5. Taylor expanded in x around 0

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

                                                \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left(y \cdot \left(1 + y\right)\right)}\right) \]
                                              2. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{\left(1 + y\right)}\right)\right) \]
                                              3. +-commutativeN/A

                                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \left(y + \color{blue}{1}\right)\right)\right) \]
                                              4. +-lowering-+.f6457.7%

                                                \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right) \]
                                            7. Simplified57.7%

                                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(y + 1\right)}} \]
                                            8. Taylor expanded in y around 0

                                              \[\leadsto \color{blue}{\frac{x}{y}} \]
                                            9. Step-by-step derivation
                                              1. /-lowering-/.f6439.4%

                                                \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{y}\right) \]
                                            10. Simplified39.4%

                                              \[\leadsto \color{blue}{\frac{x}{y}} \]
                                          3. Recombined 2 regimes into one program.
                                          4. Add Preprocessing

                                          Alternative 19: 25.7% accurate, 5.7× speedup?

                                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \frac{x}{y} \end{array} \]
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          (FPCore (x y) :precision binary64 (/ x y))
                                          assert(x < y);
                                          double code(double x, double y) {
                                          	return x / y;
                                          }
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          real(8) function code(x, y)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              code = x / y
                                          end function
                                          
                                          assert x < y;
                                          public static double code(double x, double y) {
                                          	return x / y;
                                          }
                                          
                                          [x, y] = sort([x, y])
                                          def code(x, y):
                                          	return x / y
                                          
                                          x, y = sort([x, y])
                                          function code(x, y)
                                          	return Float64(x / y)
                                          end
                                          
                                          x, y = num2cell(sort([x, y])){:}
                                          function tmp = code(x, y)
                                          	tmp = x / y;
                                          end
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          code[x_, y_] := N[(x / y), $MachinePrecision]
                                          
                                          \begin{array}{l}
                                          [x, y] = \mathsf{sort}([x, y])\\
                                          \\
                                          \frac{x}{y}
                                          \end{array}
                                          
                                          Derivation
                                          1. Initial program 71.5%

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

                                              \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                            2. *-lowering-*.f64N/A

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

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                            4. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                            5. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                            6. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                            7. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                            8. associate-+l+N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                            9. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                            10. +-lowering-+.f6471.5%

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                          3. Simplified71.5%

                                            \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                          4. Add Preprocessing
                                          5. Taylor expanded in x around 0

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

                                              \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{\left(y \cdot \left(1 + y\right)\right)}\right) \]
                                            2. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \color{blue}{\left(1 + y\right)}\right)\right) \]
                                            3. +-commutativeN/A

                                              \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \left(y + \color{blue}{1}\right)\right)\right) \]
                                            4. +-lowering-+.f6450.3%

                                              \[\leadsto \mathsf{/.f64}\left(x, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right) \]
                                          7. Simplified50.3%

                                            \[\leadsto \color{blue}{\frac{x}{y \cdot \left(y + 1\right)}} \]
                                          8. Taylor expanded in y around 0

                                            \[\leadsto \color{blue}{\frac{x}{y}} \]
                                          9. Step-by-step derivation
                                            1. /-lowering-/.f6428.9%

                                              \[\leadsto \mathsf{/.f64}\left(x, \color{blue}{y}\right) \]
                                          10. Simplified28.9%

                                            \[\leadsto \color{blue}{\frac{x}{y}} \]
                                          11. Add Preprocessing

                                          Alternative 20: 4.3% accurate, 5.7× speedup?

                                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \frac{1}{x} \end{array} \]
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          (FPCore (x y) :precision binary64 (/ 1.0 x))
                                          assert(x < y);
                                          double code(double x, double y) {
                                          	return 1.0 / x;
                                          }
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          real(8) function code(x, y)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              code = 1.0d0 / x
                                          end function
                                          
                                          assert x < y;
                                          public static double code(double x, double y) {
                                          	return 1.0 / x;
                                          }
                                          
                                          [x, y] = sort([x, y])
                                          def code(x, y):
                                          	return 1.0 / x
                                          
                                          x, y = sort([x, y])
                                          function code(x, y)
                                          	return Float64(1.0 / x)
                                          end
                                          
                                          x, y = num2cell(sort([x, y])){:}
                                          function tmp = code(x, y)
                                          	tmp = 1.0 / x;
                                          end
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          code[x_, y_] := N[(1.0 / x), $MachinePrecision]
                                          
                                          \begin{array}{l}
                                          [x, y] = \mathsf{sort}([x, y])\\
                                          \\
                                          \frac{1}{x}
                                          \end{array}
                                          
                                          Derivation
                                          1. Initial program 71.5%

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

                                              \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                            2. *-lowering-*.f64N/A

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

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                            4. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                            5. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                            6. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                            7. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                            8. associate-+l+N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                            9. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                            10. +-lowering-+.f6471.5%

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                          3. Simplified71.5%

                                            \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                          4. Add Preprocessing
                                          5. Taylor expanded in x around inf

                                            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \color{blue}{\left({x}^{2}\right)}\right)\right) \]
                                          6. Step-by-step derivation
                                            1. unpow2N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x \cdot \color{blue}{x}\right)\right)\right) \]
                                            2. *-lowering-*.f6430.1%

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(x, \color{blue}{x}\right)\right)\right) \]
                                          7. Simplified30.1%

                                            \[\leadsto \frac{x \cdot y}{\left(x + y\right) \cdot \color{blue}{\left(x \cdot x\right)}} \]
                                          8. Taylor expanded in x around 0

                                            \[\leadsto \color{blue}{\frac{1}{x}} \]
                                          9. Step-by-step derivation
                                            1. /-lowering-/.f644.2%

                                              \[\leadsto \mathsf{/.f64}\left(1, \color{blue}{x}\right) \]
                                          10. Simplified4.2%

                                            \[\leadsto \color{blue}{\frac{1}{x}} \]
                                          11. Add Preprocessing

                                          Alternative 21: 3.5% accurate, 17.0× speedup?

                                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ 1 \end{array} \]
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          (FPCore (x y) :precision binary64 1.0)
                                          assert(x < y);
                                          double code(double x, double y) {
                                          	return 1.0;
                                          }
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          real(8) function code(x, y)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              code = 1.0d0
                                          end function
                                          
                                          assert x < y;
                                          public static double code(double x, double y) {
                                          	return 1.0;
                                          }
                                          
                                          [x, y] = sort([x, y])
                                          def code(x, y):
                                          	return 1.0
                                          
                                          x, y = sort([x, y])
                                          function code(x, y)
                                          	return 1.0
                                          end
                                          
                                          x, y = num2cell(sort([x, y])){:}
                                          function tmp = code(x, y)
                                          	tmp = 1.0;
                                          end
                                          
                                          NOTE: x and y should be sorted in increasing order before calling this function.
                                          code[x_, y_] := 1.0
                                          
                                          \begin{array}{l}
                                          [x, y] = \mathsf{sort}([x, y])\\
                                          \\
                                          1
                                          \end{array}
                                          
                                          Derivation
                                          1. Initial program 71.5%

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

                                              \[\leadsto \mathsf{/.f64}\left(\left(x \cdot y\right), \color{blue}{\left(\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right) \]
                                            2. *-lowering-*.f64N/A

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

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \left(\left(x + y\right) \cdot \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                            4. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}\right)\right) \]
                                            5. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) + 1\right)\right)\right)\right) \]
                                            6. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\left(x + y\right), \color{blue}{\left(\left(x + y\right) + 1\right)}\right)\right)\right) \]
                                            7. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(\color{blue}{\left(x + y\right)} + 1\right)\right)\right)\right) \]
                                            8. associate-+l+N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \left(x + \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                            9. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \color{blue}{\left(y + 1\right)}\right)\right)\right)\right) \]
                                            10. +-lowering-+.f6471.5%

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, y\right), \mathsf{+.f64}\left(x, \mathsf{+.f64}\left(y, \color{blue}{1}\right)\right)\right)\right)\right) \]
                                          3. Simplified71.5%

                                            \[\leadsto \color{blue}{\frac{x \cdot y}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(x + \left(y + 1\right)\right)\right)}} \]
                                          4. Add Preprocessing
                                          5. Step-by-step derivation
                                            1. associate-/r*N/A

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

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

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

                                              \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{x \cdot y}{x + y}}{x + \left(y + 1\right)}\right), \color{blue}{\left(x + y\right)}\right) \]
                                            5. /-lowering-/.f64N/A

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

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(x \cdot \frac{y}{x + y}\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                            7. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \left(\frac{y}{x + y}\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                            8. /-lowering-/.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \left(x + y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                            9. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(x + \left(y + 1\right)\right)\right), \left(x + y\right)\right) \]
                                            10. associate-+r+N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \left(\left(x + y\right) + 1\right)\right), \left(x + y\right)\right) \]
                                            11. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\left(x + y\right), 1\right)\right), \left(x + y\right)\right) \]
                                            12. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \left(x + y\right)\right) \]
                                            13. +-lowering-+.f6499.9%

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(x, y\right), 1\right)\right), \mathsf{+.f64}\left(x, \color{blue}{y}\right)\right) \]
                                          6. Applied egg-rr99.9%

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

                                            \[\leadsto \mathsf{/.f64}\left(\color{blue}{\left(\frac{y}{1 + x}\right)}, \mathsf{+.f64}\left(x, y\right)\right) \]
                                          8. Step-by-step derivation
                                            1. /-lowering-/.f64N/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(1 + x\right)\right), \mathsf{+.f64}\left(\color{blue}{x}, y\right)\right) \]
                                            2. +-commutativeN/A

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \left(x + 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                            3. +-lowering-+.f6451.2%

                                              \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, \mathsf{+.f64}\left(x, 1\right)\right), \mathsf{+.f64}\left(x, y\right)\right) \]
                                          9. Simplified51.2%

                                            \[\leadsto \frac{\color{blue}{\frac{y}{x + 1}}}{x + y} \]
                                          10. Taylor expanded in x around 0

                                            \[\leadsto \color{blue}{1} \]
                                          11. Step-by-step derivation
                                            1. Simplified3.6%

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

                                            Developer Target 1: 99.8% accurate, 0.9× speedup?

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

                                            Reproduce

                                            ?
                                            herbie shell --seed 2024158 
                                            (FPCore (x y)
                                              :name "Numeric.SpecFunctions:incompleteBetaApprox from math-functions-0.1.5.2, A"
                                              :precision binary64
                                            
                                              :alt
                                              (! :herbie-platform default (/ (/ (/ x (+ (+ y 1) x)) (+ y x)) (/ 1 (/ y (+ y x)))))
                                            
                                              (/ (* x y) (* (* (+ x y) (+ x y)) (+ (+ x y) 1.0))))