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

Percentage Accurate: 69.1% → 99.3%
Time: 3.5s
Alternatives: 15
Speedup: 1.7×

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));
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

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

real(8) function code(x, y)
use fmin_fmax_functions
    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}

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 15 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.1% 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));
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

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

real(8) function code(x, y)
use fmin_fmax_functions
    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.3% accurate, 1.0× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \left(-1 - y\right)\right)} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
(FPCore (x y)
 :precision binary64
 (/ (/ y (+ x y)) (* (/ (+ x y) x) (- x (- -1.0 y)))))
assert(x < y);
double code(double x, double y) {
	return (y / (x + y)) / (((x + y) / x) * (x - (-1.0 - y)));
}
NOTE: x and y should be sorted in increasing order before calling this function.
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

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

real(8) function code(x, y)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    code = (y / (x + y)) / (((x + y) / x) * (x - ((-1.0d0) - y)))
end function
assert x < y;
public static double code(double x, double y) {
	return (y / (x + y)) / (((x + y) / x) * (x - (-1.0 - y)));
}
[x, y] = sort([x, y])
def code(x, y):
	return (y / (x + y)) / (((x + y) / x) * (x - (-1.0 - y)))
x, y = sort([x, y])
function code(x, y)
	return Float64(Float64(y / Float64(x + y)) / Float64(Float64(Float64(x + y) / x) * Float64(x - Float64(-1.0 - y))))
end
x, y = num2cell(sort([x, y])){:}
function tmp = code(x, y)
	tmp = (y / (x + y)) / (((x + y) / x) * (x - (-1.0 - y)));
end
NOTE: x and y should be sorted in increasing order before calling this function.
code[x_, y_] := N[(N[(y / N[(x + y), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(x + y), $MachinePrecision] / x), $MachinePrecision] * N[(x - N[(-1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
\\
\frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \left(-1 - y\right)\right)}
\end{array}
Derivation
  1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
    15. lower-*.f6493.6

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

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

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

      \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
    19. lift-+.f64N/A

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

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

      \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
    22. metadata-eval93.6

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

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

      \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
    25. lower-+.f6493.6

      \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
  3. Applied rewrites93.6%

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

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

      \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
    3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
    15. lower-/.f6499.3

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

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

      \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
    18. lift-+.f6499.3

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

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

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

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

      \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
    4. add-flipN/A

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

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

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

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

      \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x + \left(y + 1\right)\right)}} \]
    9. metadata-evalN/A

      \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \left(y + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right)\right)} \]
    10. sub-flipN/A

      \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(y - -1\right)}\right)} \]
    11. sub-negate-revN/A

      \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(\mathsf{neg}\left(\left(-1 - y\right)\right)\right)}\right)} \]
    12. sub-flip-reverseN/A

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

      \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
    14. lower--.f6499.3

      \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{\left(-1 - y\right)}\right)} \]
  7. Applied rewrites99.3%

    \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\frac{x + y}{x} \cdot \left(x - \left(-1 - y\right)\right)}} \]
  8. Add Preprocessing

Alternative 2: 96.9% accurate, 0.8× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} t_0 := x - \left(-1 - y\right)\\ t_1 := \frac{y}{x + y}\\ \mathbf{if}\;x \leq -2.35 \cdot 10^{+166}:\\ \;\;\;\;\frac{t\_1}{\frac{x + y}{x} \cdot \left(x - -1\right)}\\ \mathbf{elif}\;x \leq 5.5 \cdot 10^{-90}:\\ \;\;\;\;\frac{t\_1 \cdot x}{t\_0 \cdot \left(x + y\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1 \cdot \frac{x}{t\_0}}{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
 (let* ((t_0 (- x (- -1.0 y))) (t_1 (/ y (+ x y))))
   (if (<= x -2.35e+166)
     (/ t_1 (* (/ (+ x y) x) (- x -1.0)))
     (if (<= x 5.5e-90)
       (/ (* t_1 x) (* t_0 (+ x y)))
       (/ (* 1.0 (/ x t_0)) (+ x y))))))
assert(x < y);
double code(double x, double y) {
	double t_0 = x - (-1.0 - y);
	double t_1 = y / (x + y);
	double tmp;
	if (x <= -2.35e+166) {
		tmp = t_1 / (((x + y) / x) * (x - -1.0));
	} else if (x <= 5.5e-90) {
		tmp = (t_1 * x) / (t_0 * (x + y));
	} else {
		tmp = (1.0 * (x / t_0)) / (x + y);
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

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

real(8) function code(x, y)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8) :: t_0
    real(8) :: t_1
    real(8) :: tmp
    t_0 = x - ((-1.0d0) - y)
    t_1 = y / (x + y)
    if (x <= (-2.35d+166)) then
        tmp = t_1 / (((x + y) / x) * (x - (-1.0d0)))
    else if (x <= 5.5d-90) then
        tmp = (t_1 * x) / (t_0 * (x + y))
    else
        tmp = (1.0d0 * (x / t_0)) / (x + y)
    end if
    code = tmp
end function
assert x < y;
public static double code(double x, double y) {
	double t_0 = x - (-1.0 - y);
	double t_1 = y / (x + y);
	double tmp;
	if (x <= -2.35e+166) {
		tmp = t_1 / (((x + y) / x) * (x - -1.0));
	} else if (x <= 5.5e-90) {
		tmp = (t_1 * x) / (t_0 * (x + y));
	} else {
		tmp = (1.0 * (x / t_0)) / (x + y);
	}
	return tmp;
}
[x, y] = sort([x, y])
def code(x, y):
	t_0 = x - (-1.0 - y)
	t_1 = y / (x + y)
	tmp = 0
	if x <= -2.35e+166:
		tmp = t_1 / (((x + y) / x) * (x - -1.0))
	elif x <= 5.5e-90:
		tmp = (t_1 * x) / (t_0 * (x + y))
	else:
		tmp = (1.0 * (x / t_0)) / (x + y)
	return tmp
x, y = sort([x, y])
function code(x, y)
	t_0 = Float64(x - Float64(-1.0 - y))
	t_1 = Float64(y / Float64(x + y))
	tmp = 0.0
	if (x <= -2.35e+166)
		tmp = Float64(t_1 / Float64(Float64(Float64(x + y) / x) * Float64(x - -1.0)));
	elseif (x <= 5.5e-90)
		tmp = Float64(Float64(t_1 * x) / Float64(t_0 * Float64(x + y)));
	else
		tmp = Float64(Float64(1.0 * Float64(x / t_0)) / Float64(x + y));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
function tmp_2 = code(x, y)
	t_0 = x - (-1.0 - y);
	t_1 = y / (x + y);
	tmp = 0.0;
	if (x <= -2.35e+166)
		tmp = t_1 / (((x + y) / x) * (x - -1.0));
	elseif (x <= 5.5e-90)
		tmp = (t_1 * x) / (t_0 * (x + y));
	else
		tmp = (1.0 * (x / t_0)) / (x + y);
	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[(x - N[(-1.0 - y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(y / N[(x + y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -2.35e+166], N[(t$95$1 / N[(N[(N[(x + y), $MachinePrecision] / x), $MachinePrecision] * N[(x - -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 5.5e-90], N[(N[(t$95$1 * x), $MachinePrecision] / N[(t$95$0 * N[(x + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 * N[(x / t$95$0), $MachinePrecision]), $MachinePrecision] / N[(x + y), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
\\
\begin{array}{l}
t_0 := x - \left(-1 - y\right)\\
t_1 := \frac{y}{x + y}\\
\mathbf{if}\;x \leq -2.35 \cdot 10^{+166}:\\
\;\;\;\;\frac{t\_1}{\frac{x + y}{x} \cdot \left(x - -1\right)}\\

\mathbf{elif}\;x \leq 5.5 \cdot 10^{-90}:\\
\;\;\;\;\frac{t\_1 \cdot x}{t\_0 \cdot \left(x + y\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if x < -2.35e166

    1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
      15. lower-*.f6493.6

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

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

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

        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
      19. lift-+.f64N/A

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

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

        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
      22. metadata-eval93.6

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

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

        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
      25. lower-+.f6493.6

        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
    3. Applied rewrites93.6%

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

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

        \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
      3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
      15. lower-/.f6499.3

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

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

        \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
      18. lift-+.f6499.3

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

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

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

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

        \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
      4. add-flipN/A

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

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

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

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

        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x + \left(y + 1\right)\right)}} \]
      9. metadata-evalN/A

        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \left(y + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right)\right)} \]
      10. sub-flipN/A

        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(y - -1\right)}\right)} \]
      11. sub-negate-revN/A

        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(\mathsf{neg}\left(\left(-1 - y\right)\right)\right)}\right)} \]
      12. sub-flip-reverseN/A

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

        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
      14. lower--.f6499.3

        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{\left(-1 - y\right)}\right)} \]
    7. Applied rewrites99.3%

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

      \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{-1}\right)} \]
    9. Step-by-step derivation
      1. Applied rewrites76.5%

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

      if -2.35e166 < x < 5.5000000000000003e-90

      1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
        15. lower-*.f6493.6

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

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

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

          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
        19. lift-+.f64N/A

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

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

          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
        22. metadata-eval93.6

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

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

          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
        25. lower-+.f6493.6

          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
      3. Applied rewrites93.6%

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

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

          \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
        3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
        15. lower-/.f6499.3

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

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

          \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
        18. lift-+.f6499.3

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

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

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

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

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

          \[\leadsto \frac{y}{x + y} \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
        5. metadata-evalN/A

          \[\leadsto \frac{y}{x + y} \cdot \frac{1}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
        6. add-flipN/A

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

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

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

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

          \[\leadsto \frac{y}{x + y} \cdot \frac{1}{\frac{\left(\color{blue}{\left(y + x\right)} + 1\right) \cdot \left(x + y\right)}{x}} \]
        11. metadata-evalN/A

          \[\leadsto \frac{y}{x + y} \cdot \frac{1}{\frac{\left(\left(y + x\right) + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right) \cdot \left(x + y\right)}{x}} \]
        12. sub-flipN/A

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

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

          \[\leadsto \frac{y}{x + y} \cdot \frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}}{x}} \]
        15. div-flipN/A

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

          \[\leadsto \color{blue}{\frac{\frac{y}{x + y} \cdot x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
      7. Applied rewrites93.7%

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

      if 5.5000000000000003e-90 < x

      1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
        15. lower-*.f6493.6

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

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

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

          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
        19. lift-+.f64N/A

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

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

          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
        22. metadata-eval93.6

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

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

          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
        25. lower-+.f6493.6

          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
      3. Applied rewrites93.6%

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

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

          \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
        3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
        15. lower-/.f6499.3

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

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

          \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
        18. lift-+.f6499.3

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

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

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

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

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

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

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

            \[\leadsto 1 \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
          5. metadata-evalN/A

            \[\leadsto 1 \cdot \frac{1}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
          6. add-flipN/A

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

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

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

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

            \[\leadsto 1 \cdot \frac{1}{\frac{\left(\color{blue}{\left(y + x\right)} + 1\right) \cdot \left(x + y\right)}{x}} \]
          11. metadata-evalN/A

            \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right) \cdot \left(x + y\right)}{x}} \]
          12. sub-flipN/A

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

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

            \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}}{x}} \]
          15. div-flipN/A

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

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

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

            \[\leadsto 1 \cdot \frac{\frac{x}{\left(y + x\right) - -1}}{\color{blue}{x + y}} \]
        3. Applied rewrites51.5%

          \[\leadsto \color{blue}{\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{x + y}} \]
      8. Recombined 3 regimes into one program.
      9. Add Preprocessing

      Alternative 3: 93.2% accurate, 0.9× speedup?

      \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 230000:\\ \;\;\;\;\frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - -1\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{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 (<= y 230000.0)
         (/ (/ y (+ x y)) (* (/ (+ x y) x) (- x -1.0)))
         (/ (* 1.0 (/ x (- x (- -1.0 y)))) (+ x y))))
      assert(x < y);
      double code(double x, double y) {
      	double tmp;
      	if (y <= 230000.0) {
      		tmp = (y / (x + y)) / (((x + y) / x) * (x - -1.0));
      	} else {
      		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (x + y);
      	}
      	return tmp;
      }
      
      NOTE: x and y should be sorted in increasing order before calling this function.
      module fmin_fmax_functions
          implicit none
          private
          public fmax
          public fmin
      
          interface fmax
              module procedure fmax88
              module procedure fmax44
              module procedure fmax84
              module procedure fmax48
          end interface
          interface fmin
              module procedure fmin88
              module procedure fmin44
              module procedure fmin84
              module procedure fmin48
          end interface
      contains
          real(8) function fmax88(x, y) result (res)
              real(8), intent (in) :: x
              real(8), intent (in) :: y
              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
          end function
          real(4) function fmax44(x, y) result (res)
              real(4), intent (in) :: x
              real(4), intent (in) :: y
              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
          end function
          real(8) function fmax84(x, y) result(res)
              real(8), intent (in) :: x
              real(4), intent (in) :: y
              res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
          end function
          real(8) function fmax48(x, y) result(res)
              real(4), intent (in) :: x
              real(8), intent (in) :: y
              res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
          end function
          real(8) function fmin88(x, y) result (res)
              real(8), intent (in) :: x
              real(8), intent (in) :: y
              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
          end function
          real(4) function fmin44(x, y) result (res)
              real(4), intent (in) :: x
              real(4), intent (in) :: y
              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
          end function
          real(8) function fmin84(x, y) result(res)
              real(8), intent (in) :: x
              real(4), intent (in) :: y
              res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
          end function
          real(8) function fmin48(x, y) result(res)
              real(4), intent (in) :: x
              real(8), intent (in) :: y
              res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
          end function
      end module
      
      real(8) function code(x, y)
      use fmin_fmax_functions
          real(8), intent (in) :: x
          real(8), intent (in) :: y
          real(8) :: tmp
          if (y <= 230000.0d0) then
              tmp = (y / (x + y)) / (((x + y) / x) * (x - (-1.0d0)))
          else
              tmp = (1.0d0 * (x / (x - ((-1.0d0) - y)))) / (x + y)
          end if
          code = tmp
      end function
      
      assert x < y;
      public static double code(double x, double y) {
      	double tmp;
      	if (y <= 230000.0) {
      		tmp = (y / (x + y)) / (((x + y) / x) * (x - -1.0));
      	} else {
      		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (x + y);
      	}
      	return tmp;
      }
      
      [x, y] = sort([x, y])
      def code(x, y):
      	tmp = 0
      	if y <= 230000.0:
      		tmp = (y / (x + y)) / (((x + y) / x) * (x - -1.0))
      	else:
      		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (x + y)
      	return tmp
      
      x, y = sort([x, y])
      function code(x, y)
      	tmp = 0.0
      	if (y <= 230000.0)
      		tmp = Float64(Float64(y / Float64(x + y)) / Float64(Float64(Float64(x + y) / x) * Float64(x - -1.0)));
      	else
      		tmp = Float64(Float64(1.0 * Float64(x / Float64(x - Float64(-1.0 - y)))) / Float64(x + y));
      	end
      	return tmp
      end
      
      x, y = num2cell(sort([x, y])){:}
      function tmp_2 = code(x, y)
      	tmp = 0.0;
      	if (y <= 230000.0)
      		tmp = (y / (x + y)) / (((x + y) / x) * (x - -1.0));
      	else
      		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (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[y, 230000.0], N[(N[(y / N[(x + y), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(x + y), $MachinePrecision] / x), $MachinePrecision] * N[(x - -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 * N[(x / N[(x - N[(-1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + y), $MachinePrecision]), $MachinePrecision]]
      
      \begin{array}{l}
      [x, y] = \mathsf{sort}([x, y])\\
      \\
      \begin{array}{l}
      \mathbf{if}\;y \leq 230000:\\
      \;\;\;\;\frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - -1\right)}\\
      
      \mathbf{else}:\\
      \;\;\;\;\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{x + y}\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if y < 2.3e5

        1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
          15. lower-*.f6493.6

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

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

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

            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
          19. lift-+.f64N/A

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

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

            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
          22. metadata-eval93.6

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

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

            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
          25. lower-+.f6493.6

            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
        3. Applied rewrites93.6%

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

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

            \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
          3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

            \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
          15. lower-/.f6499.3

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

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

            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
          18. lift-+.f6499.3

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

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

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

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

            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
          4. add-flipN/A

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

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

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

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

            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x + \left(y + 1\right)\right)}} \]
          9. metadata-evalN/A

            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \left(y + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right)\right)} \]
          10. sub-flipN/A

            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(y - -1\right)}\right)} \]
          11. sub-negate-revN/A

            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(\mathsf{neg}\left(\left(-1 - y\right)\right)\right)}\right)} \]
          12. sub-flip-reverseN/A

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

            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
          14. lower--.f6499.3

            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{\left(-1 - y\right)}\right)} \]
        7. Applied rewrites99.3%

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

          \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{-1}\right)} \]
        9. Step-by-step derivation
          1. Applied rewrites76.5%

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

          if 2.3e5 < y

          1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
            15. lower-*.f6493.6

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

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

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

              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
            19. lift-+.f64N/A

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

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

              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
            22. metadata-eval93.6

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

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

              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
            25. lower-+.f6493.6

              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
          3. Applied rewrites93.6%

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

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

              \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
            3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
            15. lower-/.f6499.3

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

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

              \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
            18. lift-+.f6499.3

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

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

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

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

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

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

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

                \[\leadsto 1 \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
              5. metadata-evalN/A

                \[\leadsto 1 \cdot \frac{1}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
              6. add-flipN/A

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

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

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

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

                \[\leadsto 1 \cdot \frac{1}{\frac{\left(\color{blue}{\left(y + x\right)} + 1\right) \cdot \left(x + y\right)}{x}} \]
              11. metadata-evalN/A

                \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right) \cdot \left(x + y\right)}{x}} \]
              12. sub-flipN/A

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

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

                \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}}{x}} \]
              15. div-flipN/A

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

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

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

                \[\leadsto 1 \cdot \frac{\frac{x}{\left(y + x\right) - -1}}{\color{blue}{x + y}} \]
            3. Applied rewrites51.5%

              \[\leadsto \color{blue}{\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{x + y}} \]
          8. Recombined 2 regimes into one program.
          9. Add Preprocessing

          Alternative 4: 92.4% accurate, 0.8× speedup?

          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} t_0 := \frac{y}{x + y}\\ \mathbf{if}\;x \leq -2.5 \cdot 10^{-5}:\\ \;\;\;\;\frac{t\_0}{1 + x}\\ \mathbf{elif}\;x \leq 5.5 \cdot 10^{-90}:\\ \;\;\;\;\frac{t\_0 \cdot x}{\left(y - -1\right) \cdot \left(x + y\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{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
           (let* ((t_0 (/ y (+ x y))))
             (if (<= x -2.5e-5)
               (/ t_0 (+ 1.0 x))
               (if (<= x 5.5e-90)
                 (/ (* t_0 x) (* (- y -1.0) (+ x y)))
                 (/ (* 1.0 (/ x (- x (- -1.0 y)))) (+ x y))))))
          assert(x < y);
          double code(double x, double y) {
          	double t_0 = y / (x + y);
          	double tmp;
          	if (x <= -2.5e-5) {
          		tmp = t_0 / (1.0 + x);
          	} else if (x <= 5.5e-90) {
          		tmp = (t_0 * x) / ((y - -1.0) * (x + y));
          	} else {
          		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (x + y);
          	}
          	return tmp;
          }
          
          NOTE: x and y should be sorted in increasing order before calling this function.
          module fmin_fmax_functions
              implicit none
              private
              public fmax
              public fmin
          
              interface fmax
                  module procedure fmax88
                  module procedure fmax44
                  module procedure fmax84
                  module procedure fmax48
              end interface
              interface fmin
                  module procedure fmin88
                  module procedure fmin44
                  module procedure fmin84
                  module procedure fmin48
              end interface
          contains
              real(8) function fmax88(x, y) result (res)
                  real(8), intent (in) :: x
                  real(8), intent (in) :: y
                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
              end function
              real(4) function fmax44(x, y) result (res)
                  real(4), intent (in) :: x
                  real(4), intent (in) :: y
                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
              end function
              real(8) function fmax84(x, y) result(res)
                  real(8), intent (in) :: x
                  real(4), intent (in) :: y
                  res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
              end function
              real(8) function fmax48(x, y) result(res)
                  real(4), intent (in) :: x
                  real(8), intent (in) :: y
                  res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
              end function
              real(8) function fmin88(x, y) result (res)
                  real(8), intent (in) :: x
                  real(8), intent (in) :: y
                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
              end function
              real(4) function fmin44(x, y) result (res)
                  real(4), intent (in) :: x
                  real(4), intent (in) :: y
                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
              end function
              real(8) function fmin84(x, y) result(res)
                  real(8), intent (in) :: x
                  real(4), intent (in) :: y
                  res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
              end function
              real(8) function fmin48(x, y) result(res)
                  real(4), intent (in) :: x
                  real(8), intent (in) :: y
                  res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
              end function
          end module
          
          real(8) function code(x, y)
          use fmin_fmax_functions
              real(8), intent (in) :: x
              real(8), intent (in) :: y
              real(8) :: t_0
              real(8) :: tmp
              t_0 = y / (x + y)
              if (x <= (-2.5d-5)) then
                  tmp = t_0 / (1.0d0 + x)
              else if (x <= 5.5d-90) then
                  tmp = (t_0 * x) / ((y - (-1.0d0)) * (x + y))
              else
                  tmp = (1.0d0 * (x / (x - ((-1.0d0) - y)))) / (x + y)
              end if
              code = tmp
          end function
          
          assert x < y;
          public static double code(double x, double y) {
          	double t_0 = y / (x + y);
          	double tmp;
          	if (x <= -2.5e-5) {
          		tmp = t_0 / (1.0 + x);
          	} else if (x <= 5.5e-90) {
          		tmp = (t_0 * x) / ((y - -1.0) * (x + y));
          	} else {
          		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (x + y);
          	}
          	return tmp;
          }
          
          [x, y] = sort([x, y])
          def code(x, y):
          	t_0 = y / (x + y)
          	tmp = 0
          	if x <= -2.5e-5:
          		tmp = t_0 / (1.0 + x)
          	elif x <= 5.5e-90:
          		tmp = (t_0 * x) / ((y - -1.0) * (x + y))
          	else:
          		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (x + y)
          	return tmp
          
          x, y = sort([x, y])
          function code(x, y)
          	t_0 = Float64(y / Float64(x + y))
          	tmp = 0.0
          	if (x <= -2.5e-5)
          		tmp = Float64(t_0 / Float64(1.0 + x));
          	elseif (x <= 5.5e-90)
          		tmp = Float64(Float64(t_0 * x) / Float64(Float64(y - -1.0) * Float64(x + y)));
          	else
          		tmp = Float64(Float64(1.0 * Float64(x / Float64(x - Float64(-1.0 - y)))) / Float64(x + y));
          	end
          	return tmp
          end
          
          x, y = num2cell(sort([x, y])){:}
          function tmp_2 = code(x, y)
          	t_0 = y / (x + y);
          	tmp = 0.0;
          	if (x <= -2.5e-5)
          		tmp = t_0 / (1.0 + x);
          	elseif (x <= 5.5e-90)
          		tmp = (t_0 * x) / ((y - -1.0) * (x + y));
          	else
          		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (x + y);
          	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[(x + y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -2.5e-5], N[(t$95$0 / N[(1.0 + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 5.5e-90], N[(N[(t$95$0 * x), $MachinePrecision] / N[(N[(y - -1.0), $MachinePrecision] * N[(x + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 * N[(x / N[(x - N[(-1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + y), $MachinePrecision]), $MachinePrecision]]]]
          
          \begin{array}{l}
          [x, y] = \mathsf{sort}([x, y])\\
          \\
          \begin{array}{l}
          t_0 := \frac{y}{x + y}\\
          \mathbf{if}\;x \leq -2.5 \cdot 10^{-5}:\\
          \;\;\;\;\frac{t\_0}{1 + x}\\
          
          \mathbf{elif}\;x \leq 5.5 \cdot 10^{-90}:\\
          \;\;\;\;\frac{t\_0 \cdot x}{\left(y - -1\right) \cdot \left(x + y\right)}\\
          
          \mathbf{else}:\\
          \;\;\;\;\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{x + y}\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if x < -2.50000000000000012e-5

            1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
              15. lower-*.f6493.6

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

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

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

                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
              19. lift-+.f64N/A

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

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

                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
              22. metadata-eval93.6

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

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

                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
              25. lower-+.f6493.6

                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
            3. Applied rewrites93.6%

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

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

                \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
              3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
              15. lower-/.f6499.3

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

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

                \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
              18. lift-+.f6499.3

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

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

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

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

                \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
              4. add-flipN/A

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

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

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

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

                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x + \left(y + 1\right)\right)}} \]
              9. metadata-evalN/A

                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \left(y + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right)\right)} \]
              10. sub-flipN/A

                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(y - -1\right)}\right)} \]
              11. sub-negate-revN/A

                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(\mathsf{neg}\left(\left(-1 - y\right)\right)\right)}\right)} \]
              12. sub-flip-reverseN/A

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

                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
              14. lower--.f6499.3

                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{\left(-1 - y\right)}\right)} \]
            7. Applied rewrites99.3%

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

              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{1 + x}} \]
            9. Step-by-step derivation
              1. lower-+.f6451.3

                \[\leadsto \frac{\frac{y}{x + y}}{1 + \color{blue}{x}} \]
            10. Applied rewrites51.3%

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

            if -2.50000000000000012e-5 < x < 5.5000000000000003e-90

            1. Initial program 69.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. Taylor expanded in x around 0

              \[\leadsto \frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \color{blue}{\left(1 + y\right)}} \]
            3. Step-by-step derivation
              1. lower-+.f6458.7

                \[\leadsto \frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(1 + \color{blue}{y}\right)} \]
            4. Applied rewrites58.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \frac{\frac{y}{\color{blue}{x + y}} \cdot x}{\left(x + y\right) \cdot \left(1 + y\right)} \]
            6. Applied rewrites75.8%

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

            if 5.5000000000000003e-90 < x

            1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
              15. lower-*.f6493.6

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

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

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

                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
              19. lift-+.f64N/A

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

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

                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
              22. metadata-eval93.6

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

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

                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
              25. lower-+.f6493.6

                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
            3. Applied rewrites93.6%

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

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

                \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
              3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
              15. lower-/.f6499.3

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

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

                \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
              18. lift-+.f6499.3

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

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

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

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

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

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

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

                  \[\leadsto 1 \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
                5. metadata-evalN/A

                  \[\leadsto 1 \cdot \frac{1}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                6. add-flipN/A

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

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

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

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

                  \[\leadsto 1 \cdot \frac{1}{\frac{\left(\color{blue}{\left(y + x\right)} + 1\right) \cdot \left(x + y\right)}{x}} \]
                11. metadata-evalN/A

                  \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right) \cdot \left(x + y\right)}{x}} \]
                12. sub-flipN/A

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

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

                  \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}}{x}} \]
                15. div-flipN/A

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

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

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

                  \[\leadsto 1 \cdot \frac{\frac{x}{\left(y + x\right) - -1}}{\color{blue}{x + y}} \]
              3. Applied rewrites51.5%

                \[\leadsto \color{blue}{\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{x + y}} \]
            8. Recombined 3 regimes into one program.
            9. Add Preprocessing

            Alternative 5: 88.3% accurate, 0.8× speedup?

            \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 3.6 \cdot 10^{-167}:\\ \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\ \mathbf{elif}\;y \leq 3500:\\ \;\;\;\;\frac{y}{\left(1 + x\right) \cdot \left(\left(y + x\right) \cdot \left(y + x\right)\right)} \cdot x\\ \mathbf{else}:\\ \;\;\;\;\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{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 (<= y 3.6e-167)
               (/ (/ y (+ x y)) (+ 1.0 x))
               (if (<= y 3500.0)
                 (* (/ y (* (+ 1.0 x) (* (+ y x) (+ y x)))) x)
                 (/ (* 1.0 (/ x (- x (- -1.0 y)))) (+ x y)))))
            assert(x < y);
            double code(double x, double y) {
            	double tmp;
            	if (y <= 3.6e-167) {
            		tmp = (y / (x + y)) / (1.0 + x);
            	} else if (y <= 3500.0) {
            		tmp = (y / ((1.0 + x) * ((y + x) * (y + x)))) * x;
            	} else {
            		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (x + y);
            	}
            	return tmp;
            }
            
            NOTE: x and y should be sorted in increasing order before calling this function.
            module fmin_fmax_functions
                implicit none
                private
                public fmax
                public fmin
            
                interface fmax
                    module procedure fmax88
                    module procedure fmax44
                    module procedure fmax84
                    module procedure fmax48
                end interface
                interface fmin
                    module procedure fmin88
                    module procedure fmin44
                    module procedure fmin84
                    module procedure fmin48
                end interface
            contains
                real(8) function fmax88(x, y) result (res)
                    real(8), intent (in) :: x
                    real(8), intent (in) :: y
                    res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                end function
                real(4) function fmax44(x, y) result (res)
                    real(4), intent (in) :: x
                    real(4), intent (in) :: y
                    res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                end function
                real(8) function fmax84(x, y) result(res)
                    real(8), intent (in) :: x
                    real(4), intent (in) :: y
                    res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                end function
                real(8) function fmax48(x, y) result(res)
                    real(4), intent (in) :: x
                    real(8), intent (in) :: y
                    res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                end function
                real(8) function fmin88(x, y) result (res)
                    real(8), intent (in) :: x
                    real(8), intent (in) :: y
                    res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                end function
                real(4) function fmin44(x, y) result (res)
                    real(4), intent (in) :: x
                    real(4), intent (in) :: y
                    res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                end function
                real(8) function fmin84(x, y) result(res)
                    real(8), intent (in) :: x
                    real(4), intent (in) :: y
                    res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                end function
                real(8) function fmin48(x, y) result(res)
                    real(4), intent (in) :: x
                    real(8), intent (in) :: y
                    res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                end function
            end module
            
            real(8) function code(x, y)
            use fmin_fmax_functions
                real(8), intent (in) :: x
                real(8), intent (in) :: y
                real(8) :: tmp
                if (y <= 3.6d-167) then
                    tmp = (y / (x + y)) / (1.0d0 + x)
                else if (y <= 3500.0d0) then
                    tmp = (y / ((1.0d0 + x) * ((y + x) * (y + x)))) * x
                else
                    tmp = (1.0d0 * (x / (x - ((-1.0d0) - y)))) / (x + y)
                end if
                code = tmp
            end function
            
            assert x < y;
            public static double code(double x, double y) {
            	double tmp;
            	if (y <= 3.6e-167) {
            		tmp = (y / (x + y)) / (1.0 + x);
            	} else if (y <= 3500.0) {
            		tmp = (y / ((1.0 + x) * ((y + x) * (y + x)))) * x;
            	} else {
            		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (x + y);
            	}
            	return tmp;
            }
            
            [x, y] = sort([x, y])
            def code(x, y):
            	tmp = 0
            	if y <= 3.6e-167:
            		tmp = (y / (x + y)) / (1.0 + x)
            	elif y <= 3500.0:
            		tmp = (y / ((1.0 + x) * ((y + x) * (y + x)))) * x
            	else:
            		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (x + y)
            	return tmp
            
            x, y = sort([x, y])
            function code(x, y)
            	tmp = 0.0
            	if (y <= 3.6e-167)
            		tmp = Float64(Float64(y / Float64(x + y)) / Float64(1.0 + x));
            	elseif (y <= 3500.0)
            		tmp = Float64(Float64(y / Float64(Float64(1.0 + x) * Float64(Float64(y + x) * Float64(y + x)))) * x);
            	else
            		tmp = Float64(Float64(1.0 * Float64(x / Float64(x - Float64(-1.0 - y)))) / Float64(x + y));
            	end
            	return tmp
            end
            
            x, y = num2cell(sort([x, y])){:}
            function tmp_2 = code(x, y)
            	tmp = 0.0;
            	if (y <= 3.6e-167)
            		tmp = (y / (x + y)) / (1.0 + x);
            	elseif (y <= 3500.0)
            		tmp = (y / ((1.0 + x) * ((y + x) * (y + x)))) * x;
            	else
            		tmp = (1.0 * (x / (x - (-1.0 - y)))) / (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[y, 3.6e-167], N[(N[(y / N[(x + y), $MachinePrecision]), $MachinePrecision] / N[(1.0 + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3500.0], N[(N[(y / N[(N[(1.0 + x), $MachinePrecision] * N[(N[(y + x), $MachinePrecision] * N[(y + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision], N[(N[(1.0 * N[(x / N[(x - N[(-1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + y), $MachinePrecision]), $MachinePrecision]]]
            
            \begin{array}{l}
            [x, y] = \mathsf{sort}([x, y])\\
            \\
            \begin{array}{l}
            \mathbf{if}\;y \leq 3.6 \cdot 10^{-167}:\\
            \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\
            
            \mathbf{elif}\;y \leq 3500:\\
            \;\;\;\;\frac{y}{\left(1 + x\right) \cdot \left(\left(y + x\right) \cdot \left(y + x\right)\right)} \cdot x\\
            
            \mathbf{else}:\\
            \;\;\;\;\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{x + y}\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 3 regimes
            2. if y < 3.6000000000000001e-167

              1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                15. lower-*.f6493.6

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

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

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

                  \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                19. lift-+.f64N/A

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

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

                  \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                22. metadata-eval93.6

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

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

                  \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                25. lower-+.f6493.6

                  \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
              3. Applied rewrites93.6%

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

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

                  \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                15. lower-/.f6499.3

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

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

                  \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                18. lift-+.f6499.3

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

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

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

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

                  \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                4. add-flipN/A

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

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

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

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

                  \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x + \left(y + 1\right)\right)}} \]
                9. metadata-evalN/A

                  \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \left(y + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right)\right)} \]
                10. sub-flipN/A

                  \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(y - -1\right)}\right)} \]
                11. sub-negate-revN/A

                  \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(\mathsf{neg}\left(\left(-1 - y\right)\right)\right)}\right)} \]
                12. sub-flip-reverseN/A

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

                  \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
                14. lower--.f6499.3

                  \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{\left(-1 - y\right)}\right)} \]
              7. Applied rewrites99.3%

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

                \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{1 + x}} \]
              9. Step-by-step derivation
                1. lower-+.f6451.3

                  \[\leadsto \frac{\frac{y}{x + y}}{1 + \color{blue}{x}} \]
              10. Applied rewrites51.3%

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

              if 3.6000000000000001e-167 < y < 3500

              1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

                  \[\leadsto \color{blue}{\frac{y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)} \cdot x} \]
              3. Applied rewrites81.8%

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

                \[\leadsto \frac{y}{\color{blue}{\left(1 + x\right)} \cdot \left(\left(y + x\right) \cdot \left(y + x\right)\right)} \cdot x \]
              5. Step-by-step derivation
                1. lower-+.f6472.1

                  \[\leadsto \frac{y}{\left(1 + \color{blue}{x}\right) \cdot \left(\left(y + x\right) \cdot \left(y + x\right)\right)} \cdot x \]
              6. Applied rewrites72.1%

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

              if 3500 < y

              1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                15. lower-*.f6493.6

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

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

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

                  \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                19. lift-+.f64N/A

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

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

                  \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                22. metadata-eval93.6

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

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

                  \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                25. lower-+.f6493.6

                  \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
              3. Applied rewrites93.6%

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

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

                  \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                15. lower-/.f6499.3

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

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

                  \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                18. lift-+.f6499.3

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

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

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

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

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

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

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

                    \[\leadsto 1 \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
                  5. metadata-evalN/A

                    \[\leadsto 1 \cdot \frac{1}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                  6. add-flipN/A

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

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

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

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

                    \[\leadsto 1 \cdot \frac{1}{\frac{\left(\color{blue}{\left(y + x\right)} + 1\right) \cdot \left(x + y\right)}{x}} \]
                  11. metadata-evalN/A

                    \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right) \cdot \left(x + y\right)}{x}} \]
                  12. sub-flipN/A

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

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

                    \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}}{x}} \]
                  15. div-flipN/A

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

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

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

                    \[\leadsto 1 \cdot \frac{\frac{x}{\left(y + x\right) - -1}}{\color{blue}{x + y}} \]
                3. Applied rewrites51.5%

                  \[\leadsto \color{blue}{\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{x + y}} \]
              8. Recombined 3 regimes into one program.
              9. Add Preprocessing

              Alternative 6: 86.8% accurate, 0.9× speedup?

              \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} t_0 := x - \left(-1 - y\right)\\ \mathbf{if}\;y \leq 4.4 \cdot 10^{-195}:\\ \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\ \mathbf{elif}\;y \leq 1.8 \cdot 10^{+156}:\\ \;\;\;\;\frac{1 \cdot x}{t\_0 \cdot \left(x + y\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1 \cdot \frac{x}{t\_0}}{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
               (let* ((t_0 (- x (- -1.0 y))))
                 (if (<= y 4.4e-195)
                   (/ (/ y (+ x y)) (+ 1.0 x))
                   (if (<= y 1.8e+156)
                     (/ (* 1.0 x) (* t_0 (+ x y)))
                     (/ (* 1.0 (/ x t_0)) (+ x y))))))
              assert(x < y);
              double code(double x, double y) {
              	double t_0 = x - (-1.0 - y);
              	double tmp;
              	if (y <= 4.4e-195) {
              		tmp = (y / (x + y)) / (1.0 + x);
              	} else if (y <= 1.8e+156) {
              		tmp = (1.0 * x) / (t_0 * (x + y));
              	} else {
              		tmp = (1.0 * (x / t_0)) / (x + y);
              	}
              	return tmp;
              }
              
              NOTE: x and y should be sorted in increasing order before calling this function.
              module fmin_fmax_functions
                  implicit none
                  private
                  public fmax
                  public fmin
              
                  interface fmax
                      module procedure fmax88
                      module procedure fmax44
                      module procedure fmax84
                      module procedure fmax48
                  end interface
                  interface fmin
                      module procedure fmin88
                      module procedure fmin44
                      module procedure fmin84
                      module procedure fmin48
                  end interface
              contains
                  real(8) function fmax88(x, y) result (res)
                      real(8), intent (in) :: x
                      real(8), intent (in) :: y
                      res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                  end function
                  real(4) function fmax44(x, y) result (res)
                      real(4), intent (in) :: x
                      real(4), intent (in) :: y
                      res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                  end function
                  real(8) function fmax84(x, y) result(res)
                      real(8), intent (in) :: x
                      real(4), intent (in) :: y
                      res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                  end function
                  real(8) function fmax48(x, y) result(res)
                      real(4), intent (in) :: x
                      real(8), intent (in) :: y
                      res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                  end function
                  real(8) function fmin88(x, y) result (res)
                      real(8), intent (in) :: x
                      real(8), intent (in) :: y
                      res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                  end function
                  real(4) function fmin44(x, y) result (res)
                      real(4), intent (in) :: x
                      real(4), intent (in) :: y
                      res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                  end function
                  real(8) function fmin84(x, y) result(res)
                      real(8), intent (in) :: x
                      real(4), intent (in) :: y
                      res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                  end function
                  real(8) function fmin48(x, y) result(res)
                      real(4), intent (in) :: x
                      real(8), intent (in) :: y
                      res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                  end function
              end module
              
              real(8) function code(x, y)
              use fmin_fmax_functions
                  real(8), intent (in) :: x
                  real(8), intent (in) :: y
                  real(8) :: t_0
                  real(8) :: tmp
                  t_0 = x - ((-1.0d0) - y)
                  if (y <= 4.4d-195) then
                      tmp = (y / (x + y)) / (1.0d0 + x)
                  else if (y <= 1.8d+156) then
                      tmp = (1.0d0 * x) / (t_0 * (x + y))
                  else
                      tmp = (1.0d0 * (x / t_0)) / (x + y)
                  end if
                  code = tmp
              end function
              
              assert x < y;
              public static double code(double x, double y) {
              	double t_0 = x - (-1.0 - y);
              	double tmp;
              	if (y <= 4.4e-195) {
              		tmp = (y / (x + y)) / (1.0 + x);
              	} else if (y <= 1.8e+156) {
              		tmp = (1.0 * x) / (t_0 * (x + y));
              	} else {
              		tmp = (1.0 * (x / t_0)) / (x + y);
              	}
              	return tmp;
              }
              
              [x, y] = sort([x, y])
              def code(x, y):
              	t_0 = x - (-1.0 - y)
              	tmp = 0
              	if y <= 4.4e-195:
              		tmp = (y / (x + y)) / (1.0 + x)
              	elif y <= 1.8e+156:
              		tmp = (1.0 * x) / (t_0 * (x + y))
              	else:
              		tmp = (1.0 * (x / t_0)) / (x + y)
              	return tmp
              
              x, y = sort([x, y])
              function code(x, y)
              	t_0 = Float64(x - Float64(-1.0 - y))
              	tmp = 0.0
              	if (y <= 4.4e-195)
              		tmp = Float64(Float64(y / Float64(x + y)) / Float64(1.0 + x));
              	elseif (y <= 1.8e+156)
              		tmp = Float64(Float64(1.0 * x) / Float64(t_0 * Float64(x + y)));
              	else
              		tmp = Float64(Float64(1.0 * Float64(x / t_0)) / Float64(x + y));
              	end
              	return tmp
              end
              
              x, y = num2cell(sort([x, y])){:}
              function tmp_2 = code(x, y)
              	t_0 = x - (-1.0 - y);
              	tmp = 0.0;
              	if (y <= 4.4e-195)
              		tmp = (y / (x + y)) / (1.0 + x);
              	elseif (y <= 1.8e+156)
              		tmp = (1.0 * x) / (t_0 * (x + y));
              	else
              		tmp = (1.0 * (x / t_0)) / (x + y);
              	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[(x - N[(-1.0 - y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 4.4e-195], N[(N[(y / N[(x + y), $MachinePrecision]), $MachinePrecision] / N[(1.0 + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.8e+156], N[(N[(1.0 * x), $MachinePrecision] / N[(t$95$0 * N[(x + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 * N[(x / t$95$0), $MachinePrecision]), $MachinePrecision] / N[(x + y), $MachinePrecision]), $MachinePrecision]]]]
              
              \begin{array}{l}
              [x, y] = \mathsf{sort}([x, y])\\
              \\
              \begin{array}{l}
              t_0 := x - \left(-1 - y\right)\\
              \mathbf{if}\;y \leq 4.4 \cdot 10^{-195}:\\
              \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\
              
              \mathbf{elif}\;y \leq 1.8 \cdot 10^{+156}:\\
              \;\;\;\;\frac{1 \cdot x}{t\_0 \cdot \left(x + y\right)}\\
              
              \mathbf{else}:\\
              \;\;\;\;\frac{1 \cdot \frac{x}{t\_0}}{x + y}\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 3 regimes
              2. if y < 4.40000000000000011e-195

                1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                  15. lower-*.f6493.6

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

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

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

                    \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                  19. lift-+.f64N/A

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

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

                    \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                  22. metadata-eval93.6

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

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

                    \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                  25. lower-+.f6493.6

                    \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                3. Applied rewrites93.6%

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

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

                    \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                  3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                  15. lower-/.f6499.3

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

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

                    \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                  18. lift-+.f6499.3

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

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

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

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

                    \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                  4. add-flipN/A

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

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

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

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

                    \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x + \left(y + 1\right)\right)}} \]
                  9. metadata-evalN/A

                    \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \left(y + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right)\right)} \]
                  10. sub-flipN/A

                    \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(y - -1\right)}\right)} \]
                  11. sub-negate-revN/A

                    \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(\mathsf{neg}\left(\left(-1 - y\right)\right)\right)}\right)} \]
                  12. sub-flip-reverseN/A

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

                    \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
                  14. lower--.f6499.3

                    \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{\left(-1 - y\right)}\right)} \]
                7. Applied rewrites99.3%

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

                  \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{1 + x}} \]
                9. Step-by-step derivation
                  1. lower-+.f6451.3

                    \[\leadsto \frac{\frac{y}{x + y}}{1 + \color{blue}{x}} \]
                10. Applied rewrites51.3%

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

                if 4.40000000000000011e-195 < y < 1.79999999999999989e156

                1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                  15. lower-*.f6493.6

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

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

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

                    \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                  19. lift-+.f64N/A

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

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

                    \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                  22. metadata-eval93.6

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

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

                    \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                  25. lower-+.f6493.6

                    \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                3. Applied rewrites93.6%

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

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

                    \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                  3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                  15. lower-/.f6499.3

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

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

                    \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                  18. lift-+.f6499.3

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

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

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

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

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

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

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

                      \[\leadsto 1 \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
                    5. metadata-evalN/A

                      \[\leadsto 1 \cdot \frac{1}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                    6. add-flipN/A

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

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

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

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

                      \[\leadsto 1 \cdot \frac{1}{\frac{\left(\color{blue}{\left(y + x\right)} + 1\right) \cdot \left(x + y\right)}{x}} \]
                    11. metadata-evalN/A

                      \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right) \cdot \left(x + y\right)}{x}} \]
                    12. sub-flipN/A

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

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

                      \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}}{x}} \]
                    15. div-flipN/A

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

                      \[\leadsto \color{blue}{\frac{1 \cdot x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                  3. Applied rewrites65.9%

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

                  if 1.79999999999999989e156 < y

                  1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                    15. lower-*.f6493.6

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

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

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

                      \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                    19. lift-+.f64N/A

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

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

                      \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                    22. metadata-eval93.6

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

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

                      \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                    25. lower-+.f6493.6

                      \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                  3. Applied rewrites93.6%

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

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

                      \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                    3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                    15. lower-/.f6499.3

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

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

                      \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                    18. lift-+.f6499.3

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

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

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

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

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

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

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

                        \[\leadsto 1 \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
                      5. metadata-evalN/A

                        \[\leadsto 1 \cdot \frac{1}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                      6. add-flipN/A

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

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

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

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

                        \[\leadsto 1 \cdot \frac{1}{\frac{\left(\color{blue}{\left(y + x\right)} + 1\right) \cdot \left(x + y\right)}{x}} \]
                      11. metadata-evalN/A

                        \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right) \cdot \left(x + y\right)}{x}} \]
                      12. sub-flipN/A

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

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

                        \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}}{x}} \]
                      15. div-flipN/A

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

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

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

                        \[\leadsto 1 \cdot \frac{\frac{x}{\left(y + x\right) - -1}}{\color{blue}{x + y}} \]
                    3. Applied rewrites51.5%

                      \[\leadsto \color{blue}{\frac{1 \cdot \frac{x}{x - \left(-1 - y\right)}}{x + y}} \]
                  8. Recombined 3 regimes into one program.
                  9. Add Preprocessing

                  Alternative 7: 86.8% accurate, 0.9× speedup?

                  \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} t_0 := x - \left(-1 - y\right)\\ \mathbf{if}\;y \leq 4.4 \cdot 10^{-195}:\\ \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\ \mathbf{elif}\;y \leq 1.8 \cdot 10^{+156}:\\ \;\;\;\;\frac{1 \cdot x}{t\_0 \cdot \left(x + y\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{t\_0} \cdot \frac{x}{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
                   (let* ((t_0 (- x (- -1.0 y))))
                     (if (<= y 4.4e-195)
                       (/ (/ y (+ x y)) (+ 1.0 x))
                       (if (<= y 1.8e+156)
                         (/ (* 1.0 x) (* t_0 (+ x y)))
                         (* (/ 1.0 t_0) (/ x (+ x y)))))))
                  assert(x < y);
                  double code(double x, double y) {
                  	double t_0 = x - (-1.0 - y);
                  	double tmp;
                  	if (y <= 4.4e-195) {
                  		tmp = (y / (x + y)) / (1.0 + x);
                  	} else if (y <= 1.8e+156) {
                  		tmp = (1.0 * x) / (t_0 * (x + y));
                  	} else {
                  		tmp = (1.0 / t_0) * (x / (x + y));
                  	}
                  	return tmp;
                  }
                  
                  NOTE: x and y should be sorted in increasing order before calling this function.
                  module fmin_fmax_functions
                      implicit none
                      private
                      public fmax
                      public fmin
                  
                      interface fmax
                          module procedure fmax88
                          module procedure fmax44
                          module procedure fmax84
                          module procedure fmax48
                      end interface
                      interface fmin
                          module procedure fmin88
                          module procedure fmin44
                          module procedure fmin84
                          module procedure fmin48
                      end interface
                  contains
                      real(8) function fmax88(x, y) result (res)
                          real(8), intent (in) :: x
                          real(8), intent (in) :: y
                          res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                      end function
                      real(4) function fmax44(x, y) result (res)
                          real(4), intent (in) :: x
                          real(4), intent (in) :: y
                          res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                      end function
                      real(8) function fmax84(x, y) result(res)
                          real(8), intent (in) :: x
                          real(4), intent (in) :: y
                          res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                      end function
                      real(8) function fmax48(x, y) result(res)
                          real(4), intent (in) :: x
                          real(8), intent (in) :: y
                          res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                      end function
                      real(8) function fmin88(x, y) result (res)
                          real(8), intent (in) :: x
                          real(8), intent (in) :: y
                          res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                      end function
                      real(4) function fmin44(x, y) result (res)
                          real(4), intent (in) :: x
                          real(4), intent (in) :: y
                          res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                      end function
                      real(8) function fmin84(x, y) result(res)
                          real(8), intent (in) :: x
                          real(4), intent (in) :: y
                          res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                      end function
                      real(8) function fmin48(x, y) result(res)
                          real(4), intent (in) :: x
                          real(8), intent (in) :: y
                          res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                      end function
                  end module
                  
                  real(8) function code(x, y)
                  use fmin_fmax_functions
                      real(8), intent (in) :: x
                      real(8), intent (in) :: y
                      real(8) :: t_0
                      real(8) :: tmp
                      t_0 = x - ((-1.0d0) - y)
                      if (y <= 4.4d-195) then
                          tmp = (y / (x + y)) / (1.0d0 + x)
                      else if (y <= 1.8d+156) then
                          tmp = (1.0d0 * x) / (t_0 * (x + y))
                      else
                          tmp = (1.0d0 / t_0) * (x / (x + y))
                      end if
                      code = tmp
                  end function
                  
                  assert x < y;
                  public static double code(double x, double y) {
                  	double t_0 = x - (-1.0 - y);
                  	double tmp;
                  	if (y <= 4.4e-195) {
                  		tmp = (y / (x + y)) / (1.0 + x);
                  	} else if (y <= 1.8e+156) {
                  		tmp = (1.0 * x) / (t_0 * (x + y));
                  	} else {
                  		tmp = (1.0 / t_0) * (x / (x + y));
                  	}
                  	return tmp;
                  }
                  
                  [x, y] = sort([x, y])
                  def code(x, y):
                  	t_0 = x - (-1.0 - y)
                  	tmp = 0
                  	if y <= 4.4e-195:
                  		tmp = (y / (x + y)) / (1.0 + x)
                  	elif y <= 1.8e+156:
                  		tmp = (1.0 * x) / (t_0 * (x + y))
                  	else:
                  		tmp = (1.0 / t_0) * (x / (x + y))
                  	return tmp
                  
                  x, y = sort([x, y])
                  function code(x, y)
                  	t_0 = Float64(x - Float64(-1.0 - y))
                  	tmp = 0.0
                  	if (y <= 4.4e-195)
                  		tmp = Float64(Float64(y / Float64(x + y)) / Float64(1.0 + x));
                  	elseif (y <= 1.8e+156)
                  		tmp = Float64(Float64(1.0 * x) / Float64(t_0 * Float64(x + y)));
                  	else
                  		tmp = Float64(Float64(1.0 / t_0) * Float64(x / Float64(x + y)));
                  	end
                  	return tmp
                  end
                  
                  x, y = num2cell(sort([x, y])){:}
                  function tmp_2 = code(x, y)
                  	t_0 = x - (-1.0 - y);
                  	tmp = 0.0;
                  	if (y <= 4.4e-195)
                  		tmp = (y / (x + y)) / (1.0 + x);
                  	elseif (y <= 1.8e+156)
                  		tmp = (1.0 * x) / (t_0 * (x + y));
                  	else
                  		tmp = (1.0 / t_0) * (x / (x + y));
                  	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[(x - N[(-1.0 - y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 4.4e-195], N[(N[(y / N[(x + y), $MachinePrecision]), $MachinePrecision] / N[(1.0 + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.8e+156], N[(N[(1.0 * x), $MachinePrecision] / N[(t$95$0 * N[(x + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 / t$95$0), $MachinePrecision] * N[(x / N[(x + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
                  
                  \begin{array}{l}
                  [x, y] = \mathsf{sort}([x, y])\\
                  \\
                  \begin{array}{l}
                  t_0 := x - \left(-1 - y\right)\\
                  \mathbf{if}\;y \leq 4.4 \cdot 10^{-195}:\\
                  \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\
                  
                  \mathbf{elif}\;y \leq 1.8 \cdot 10^{+156}:\\
                  \;\;\;\;\frac{1 \cdot x}{t\_0 \cdot \left(x + y\right)}\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;\frac{1}{t\_0} \cdot \frac{x}{x + y}\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 3 regimes
                  2. if y < 4.40000000000000011e-195

                    1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                      15. lower-*.f6493.6

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

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

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

                        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                      19. lift-+.f64N/A

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

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

                        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                      22. metadata-eval93.6

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

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

                        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                      25. lower-+.f6493.6

                        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                    3. Applied rewrites93.6%

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

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

                        \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                      3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                      15. lower-/.f6499.3

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

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

                        \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                      18. lift-+.f6499.3

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

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

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

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

                        \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                      4. add-flipN/A

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

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

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

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

                        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x + \left(y + 1\right)\right)}} \]
                      9. metadata-evalN/A

                        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \left(y + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right)\right)} \]
                      10. sub-flipN/A

                        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(y - -1\right)}\right)} \]
                      11. sub-negate-revN/A

                        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(\mathsf{neg}\left(\left(-1 - y\right)\right)\right)}\right)} \]
                      12. sub-flip-reverseN/A

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

                        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
                      14. lower--.f6499.3

                        \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{\left(-1 - y\right)}\right)} \]
                    7. Applied rewrites99.3%

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

                      \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{1 + x}} \]
                    9. Step-by-step derivation
                      1. lower-+.f6451.3

                        \[\leadsto \frac{\frac{y}{x + y}}{1 + \color{blue}{x}} \]
                    10. Applied rewrites51.3%

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

                    if 4.40000000000000011e-195 < y < 1.79999999999999989e156

                    1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                      15. lower-*.f6493.6

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

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

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

                        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                      19. lift-+.f64N/A

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

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

                        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                      22. metadata-eval93.6

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

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

                        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                      25. lower-+.f6493.6

                        \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                    3. Applied rewrites93.6%

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

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

                        \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                      3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                      15. lower-/.f6499.3

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

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

                        \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                      18. lift-+.f6499.3

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

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

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

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

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

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

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

                          \[\leadsto 1 \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
                        5. metadata-evalN/A

                          \[\leadsto 1 \cdot \frac{1}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                        6. add-flipN/A

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

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

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

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

                          \[\leadsto 1 \cdot \frac{1}{\frac{\left(\color{blue}{\left(y + x\right)} + 1\right) \cdot \left(x + y\right)}{x}} \]
                        11. metadata-evalN/A

                          \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right) \cdot \left(x + y\right)}{x}} \]
                        12. sub-flipN/A

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

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

                          \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}}{x}} \]
                        15. div-flipN/A

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

                          \[\leadsto \color{blue}{\frac{1 \cdot x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                      3. Applied rewrites65.9%

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

                      if 1.79999999999999989e156 < y

                      1. Initial program 69.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. lift-/.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                        15. lower-*.f6493.6

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

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

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

                          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                        19. lift-+.f64N/A

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

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

                          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                        22. metadata-eval93.6

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

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

                          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                        25. lower-+.f6493.6

                          \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                      3. Applied rewrites93.6%

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

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

                          \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                        3. div-flipN/A

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

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

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

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

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

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

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

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

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

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

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

                          \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                        15. lower-/.f6499.3

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

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

                          \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                        18. lift-+.f6499.3

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

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

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

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

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

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

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

                            \[\leadsto \frac{1}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                          5. add-flipN/A

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

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

                            \[\leadsto \color{blue}{\frac{\frac{1}{\left(x + y\right) + 1}}{\frac{x + y}{x}}} \]
                          8. mult-flipN/A

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

                            \[\leadsto \frac{1}{\left(x + y\right) + 1} \cdot \frac{1}{\color{blue}{\frac{x + y}{x}}} \]
                          10. div-flipN/A

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

                            \[\leadsto \color{blue}{\frac{1}{\left(x + y\right) + 1} \cdot \frac{x}{x + y}} \]
                        3. Applied rewrites51.5%

                          \[\leadsto \color{blue}{\frac{1}{x - \left(-1 - y\right)} \cdot \frac{x}{x + y}} \]
                      8. Recombined 3 regimes into one program.
                      9. Add Preprocessing

                      Alternative 8: 86.7% accurate, 0.9× speedup?

                      \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 4.4 \cdot 10^{-195}:\\ \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\ \mathbf{elif}\;y \leq 1.8 \cdot 10^{+156}:\\ \;\;\;\;\frac{1 \cdot x}{\left(x - \left(-1 - y\right)\right) \cdot \left(x + y\right)}\\ \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 4.4e-195)
                         (/ (/ y (+ x y)) (+ 1.0 x))
                         (if (<= y 1.8e+156)
                           (/ (* 1.0 x) (* (- x (- -1.0 y)) (+ x y)))
                           (/ (/ x y) (- y -1.0)))))
                      assert(x < y);
                      double code(double x, double y) {
                      	double tmp;
                      	if (y <= 4.4e-195) {
                      		tmp = (y / (x + y)) / (1.0 + x);
                      	} else if (y <= 1.8e+156) {
                      		tmp = (1.0 * x) / ((x - (-1.0 - y)) * (x + y));
                      	} else {
                      		tmp = (x / y) / (y - -1.0);
                      	}
                      	return tmp;
                      }
                      
                      NOTE: x and y should be sorted in increasing order before calling this function.
                      module fmin_fmax_functions
                          implicit none
                          private
                          public fmax
                          public fmin
                      
                          interface fmax
                              module procedure fmax88
                              module procedure fmax44
                              module procedure fmax84
                              module procedure fmax48
                          end interface
                          interface fmin
                              module procedure fmin88
                              module procedure fmin44
                              module procedure fmin84
                              module procedure fmin48
                          end interface
                      contains
                          real(8) function fmax88(x, y) result (res)
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                          end function
                          real(4) function fmax44(x, y) result (res)
                              real(4), intent (in) :: x
                              real(4), intent (in) :: y
                              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                          end function
                          real(8) function fmax84(x, y) result(res)
                              real(8), intent (in) :: x
                              real(4), intent (in) :: y
                              res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                          end function
                          real(8) function fmax48(x, y) result(res)
                              real(4), intent (in) :: x
                              real(8), intent (in) :: y
                              res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                          end function
                          real(8) function fmin88(x, y) result (res)
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                          end function
                          real(4) function fmin44(x, y) result (res)
                              real(4), intent (in) :: x
                              real(4), intent (in) :: y
                              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                          end function
                          real(8) function fmin84(x, y) result(res)
                              real(8), intent (in) :: x
                              real(4), intent (in) :: y
                              res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                          end function
                          real(8) function fmin48(x, y) result(res)
                              real(4), intent (in) :: x
                              real(8), intent (in) :: y
                              res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                          end function
                      end module
                      
                      real(8) function code(x, y)
                      use fmin_fmax_functions
                          real(8), intent (in) :: x
                          real(8), intent (in) :: y
                          real(8) :: tmp
                          if (y <= 4.4d-195) then
                              tmp = (y / (x + y)) / (1.0d0 + x)
                          else if (y <= 1.8d+156) then
                              tmp = (1.0d0 * x) / ((x - ((-1.0d0) - y)) * (x + y))
                          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 <= 4.4e-195) {
                      		tmp = (y / (x + y)) / (1.0 + x);
                      	} else if (y <= 1.8e+156) {
                      		tmp = (1.0 * x) / ((x - (-1.0 - y)) * (x + y));
                      	} else {
                      		tmp = (x / y) / (y - -1.0);
                      	}
                      	return tmp;
                      }
                      
                      [x, y] = sort([x, y])
                      def code(x, y):
                      	tmp = 0
                      	if y <= 4.4e-195:
                      		tmp = (y / (x + y)) / (1.0 + x)
                      	elif y <= 1.8e+156:
                      		tmp = (1.0 * x) / ((x - (-1.0 - y)) * (x + y))
                      	else:
                      		tmp = (x / y) / (y - -1.0)
                      	return tmp
                      
                      x, y = sort([x, y])
                      function code(x, y)
                      	tmp = 0.0
                      	if (y <= 4.4e-195)
                      		tmp = Float64(Float64(y / Float64(x + y)) / Float64(1.0 + x));
                      	elseif (y <= 1.8e+156)
                      		tmp = Float64(Float64(1.0 * x) / Float64(Float64(x - Float64(-1.0 - y)) * Float64(x + y)));
                      	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 <= 4.4e-195)
                      		tmp = (y / (x + y)) / (1.0 + x);
                      	elseif (y <= 1.8e+156)
                      		tmp = (1.0 * x) / ((x - (-1.0 - y)) * (x + y));
                      	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, 4.4e-195], N[(N[(y / N[(x + y), $MachinePrecision]), $MachinePrecision] / N[(1.0 + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.8e+156], N[(N[(1.0 * x), $MachinePrecision] / N[(N[(x - N[(-1.0 - y), $MachinePrecision]), $MachinePrecision] * N[(x + y), $MachinePrecision]), $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 4.4 \cdot 10^{-195}:\\
                      \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\
                      
                      \mathbf{elif}\;y \leq 1.8 \cdot 10^{+156}:\\
                      \;\;\;\;\frac{1 \cdot x}{\left(x - \left(-1 - y\right)\right) \cdot \left(x + y\right)}\\
                      
                      \mathbf{else}:\\
                      \;\;\;\;\frac{\frac{x}{y}}{y - -1}\\
                      
                      
                      \end{array}
                      \end{array}
                      
                      Derivation
                      1. Split input into 3 regimes
                      2. if y < 4.40000000000000011e-195

                        1. Initial program 69.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. lift-/.f64N/A

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

                            \[\leadsto \frac{\color{blue}{x \cdot y}}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          3. *-commutativeN/A

                            \[\leadsto \frac{\color{blue}{y \cdot x}}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          4. lift-*.f64N/A

                            \[\leadsto \frac{y \cdot x}{\color{blue}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                          5. lift-*.f64N/A

                            \[\leadsto \frac{y \cdot x}{\color{blue}{\left(\left(x + y\right) \cdot \left(x + y\right)\right)} \cdot \left(\left(x + y\right) + 1\right)} \]
                          6. associate-*l*N/A

                            \[\leadsto \frac{y \cdot x}{\color{blue}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}} \]
                          7. times-fracN/A

                            \[\leadsto \color{blue}{\frac{y}{x + y} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                          8. lower-*.f64N/A

                            \[\leadsto \color{blue}{\frac{y}{x + y} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                          9. lower-/.f64N/A

                            \[\leadsto \color{blue}{\frac{y}{x + y}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          10. lift-+.f64N/A

                            \[\leadsto \frac{y}{\color{blue}{x + y}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          11. +-commutativeN/A

                            \[\leadsto \frac{y}{\color{blue}{y + x}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          12. lower-+.f64N/A

                            \[\leadsto \frac{y}{\color{blue}{y + x}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          13. lower-/.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                          14. *-commutativeN/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                          15. lower-*.f6493.6

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                          16. lift-+.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right)} \cdot \left(x + y\right)} \]
                          17. add-flipN/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                          18. lower--.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                          19. lift-+.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(x + y\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                          20. +-commutativeN/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                          21. lower-+.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                          22. metadata-eval93.6

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - \color{blue}{-1}\right) \cdot \left(x + y\right)} \]
                          23. lift-+.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(x + y\right)}} \]
                          24. +-commutativeN/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                          25. lower-+.f6493.6

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                        3. Applied rewrites93.6%

                          \[\leadsto \color{blue}{\frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                        4. Step-by-step derivation
                          1. lift-*.f64N/A

                            \[\leadsto \color{blue}{\frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                          2. lift-/.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                          3. div-flipN/A

                            \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                          4. mult-flip-revN/A

                            \[\leadsto \color{blue}{\frac{\frac{y}{y + x}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                          5. lower-/.f64N/A

                            \[\leadsto \color{blue}{\frac{\frac{y}{y + x}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                          6. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{\color{blue}{y + x}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                          7. +-commutativeN/A

                            \[\leadsto \frac{\frac{y}{\color{blue}{x + y}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                          8. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{\color{blue}{x + y}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                          9. lift-*.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\frac{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}}{x}} \]
                          10. associate-/l*N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \frac{y + x}{x}}} \]
                          11. lower-*.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \frac{y + x}{x}}} \]
                          12. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(y + x\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                          13. +-commutativeN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                          14. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                          15. lower-/.f6499.3

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \color{blue}{\frac{y + x}{x}}} \]
                          16. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{y + x}}{x}} \]
                          17. +-commutativeN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                          18. lift-+.f6499.3

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                        5. Applied rewrites99.3%

                          \[\leadsto \color{blue}{\frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}}} \]
                        6. Step-by-step derivation
                          1. lift-*.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}}} \]
                          2. lift--.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
                          3. metadata-evalN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                          4. add-flipN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(x + y\right) + 1\right)} \cdot \frac{x + y}{x}} \]
                          5. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} + 1\right) \cdot \frac{x + y}{x}} \]
                          6. *-commutativeN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\frac{x + y}{x} \cdot \left(\left(x + y\right) + 1\right)}} \]
                          7. lower-*.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\frac{x + y}{x} \cdot \left(\left(x + y\right) + 1\right)}} \]
                          8. associate-+l+N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x + \left(y + 1\right)\right)}} \]
                          9. metadata-evalN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \left(y + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right)\right)} \]
                          10. sub-flipN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(y - -1\right)}\right)} \]
                          11. sub-negate-revN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(\mathsf{neg}\left(\left(-1 - y\right)\right)\right)}\right)} \]
                          12. sub-flip-reverseN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
                          13. lower--.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
                          14. lower--.f6499.3

                            \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{\left(-1 - y\right)}\right)} \]
                        7. Applied rewrites99.3%

                          \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\frac{x + y}{x} \cdot \left(x - \left(-1 - y\right)\right)}} \]
                        8. Taylor expanded in y around 0

                          \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{1 + x}} \]
                        9. Step-by-step derivation
                          1. lower-+.f6451.3

                            \[\leadsto \frac{\frac{y}{x + y}}{1 + \color{blue}{x}} \]
                        10. Applied rewrites51.3%

                          \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{1 + x}} \]

                        if 4.40000000000000011e-195 < y < 1.79999999999999989e156

                        1. Initial program 69.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. lift-/.f64N/A

                            \[\leadsto \color{blue}{\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                          2. lift-*.f64N/A

                            \[\leadsto \frac{\color{blue}{x \cdot y}}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          3. *-commutativeN/A

                            \[\leadsto \frac{\color{blue}{y \cdot x}}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          4. lift-*.f64N/A

                            \[\leadsto \frac{y \cdot x}{\color{blue}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                          5. lift-*.f64N/A

                            \[\leadsto \frac{y \cdot x}{\color{blue}{\left(\left(x + y\right) \cdot \left(x + y\right)\right)} \cdot \left(\left(x + y\right) + 1\right)} \]
                          6. associate-*l*N/A

                            \[\leadsto \frac{y \cdot x}{\color{blue}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}} \]
                          7. times-fracN/A

                            \[\leadsto \color{blue}{\frac{y}{x + y} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                          8. lower-*.f64N/A

                            \[\leadsto \color{blue}{\frac{y}{x + y} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                          9. lower-/.f64N/A

                            \[\leadsto \color{blue}{\frac{y}{x + y}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          10. lift-+.f64N/A

                            \[\leadsto \frac{y}{\color{blue}{x + y}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          11. +-commutativeN/A

                            \[\leadsto \frac{y}{\color{blue}{y + x}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          12. lower-+.f64N/A

                            \[\leadsto \frac{y}{\color{blue}{y + x}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                          13. lower-/.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                          14. *-commutativeN/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                          15. lower-*.f6493.6

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                          16. lift-+.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right)} \cdot \left(x + y\right)} \]
                          17. add-flipN/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                          18. lower--.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                          19. lift-+.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(x + y\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                          20. +-commutativeN/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                          21. lower-+.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                          22. metadata-eval93.6

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - \color{blue}{-1}\right) \cdot \left(x + y\right)} \]
                          23. lift-+.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(x + y\right)}} \]
                          24. +-commutativeN/A

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                          25. lower-+.f6493.6

                            \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                        3. Applied rewrites93.6%

                          \[\leadsto \color{blue}{\frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                        4. Step-by-step derivation
                          1. lift-*.f64N/A

                            \[\leadsto \color{blue}{\frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                          2. lift-/.f64N/A

                            \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                          3. div-flipN/A

                            \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                          4. mult-flip-revN/A

                            \[\leadsto \color{blue}{\frac{\frac{y}{y + x}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                          5. lower-/.f64N/A

                            \[\leadsto \color{blue}{\frac{\frac{y}{y + x}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                          6. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{\color{blue}{y + x}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                          7. +-commutativeN/A

                            \[\leadsto \frac{\frac{y}{\color{blue}{x + y}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                          8. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{\color{blue}{x + y}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                          9. lift-*.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\frac{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}}{x}} \]
                          10. associate-/l*N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \frac{y + x}{x}}} \]
                          11. lower-*.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \frac{y + x}{x}}} \]
                          12. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(y + x\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                          13. +-commutativeN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                          14. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                          15. lower-/.f6499.3

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \color{blue}{\frac{y + x}{x}}} \]
                          16. lift-+.f64N/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{y + x}}{x}} \]
                          17. +-commutativeN/A

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                          18. lift-+.f6499.3

                            \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                        5. Applied rewrites99.3%

                          \[\leadsto \color{blue}{\frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}}} \]
                        6. Taylor expanded in x around 0

                          \[\leadsto \frac{\color{blue}{1}}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}} \]
                        7. Step-by-step derivation
                          1. Applied rewrites50.9%

                            \[\leadsto \frac{\color{blue}{1}}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}} \]
                          2. Step-by-step derivation
                            1. lift-/.f64N/A

                              \[\leadsto \color{blue}{\frac{1}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}}} \]
                            2. mult-flipN/A

                              \[\leadsto \color{blue}{1 \cdot \frac{1}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}}} \]
                            3. lift-*.f64N/A

                              \[\leadsto 1 \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}}} \]
                            4. lift--.f64N/A

                              \[\leadsto 1 \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
                            5. metadata-evalN/A

                              \[\leadsto 1 \cdot \frac{1}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                            6. add-flipN/A

                              \[\leadsto 1 \cdot \frac{1}{\color{blue}{\left(\left(x + y\right) + 1\right)} \cdot \frac{x + y}{x}} \]
                            7. lift-+.f64N/A

                              \[\leadsto 1 \cdot \frac{1}{\left(\color{blue}{\left(x + y\right)} + 1\right) \cdot \frac{x + y}{x}} \]
                            8. lift-/.f64N/A

                              \[\leadsto 1 \cdot \frac{1}{\left(\left(x + y\right) + 1\right) \cdot \color{blue}{\frac{x + y}{x}}} \]
                            9. associate-*r/N/A

                              \[\leadsto 1 \cdot \frac{1}{\color{blue}{\frac{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}{x}}} \]
                            10. +-commutativeN/A

                              \[\leadsto 1 \cdot \frac{1}{\frac{\left(\color{blue}{\left(y + x\right)} + 1\right) \cdot \left(x + y\right)}{x}} \]
                            11. metadata-evalN/A

                              \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right) \cdot \left(x + y\right)}{x}} \]
                            12. sub-flipN/A

                              \[\leadsto 1 \cdot \frac{1}{\frac{\color{blue}{\left(\left(y + x\right) - -1\right)} \cdot \left(x + y\right)}{x}} \]
                            13. lift-+.f64N/A

                              \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(x + y\right)}}{x}} \]
                            14. +-commutativeN/A

                              \[\leadsto 1 \cdot \frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}}{x}} \]
                            15. div-flipN/A

                              \[\leadsto 1 \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                            16. associate-*r/N/A

                              \[\leadsto \color{blue}{\frac{1 \cdot x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                          3. Applied rewrites65.9%

                            \[\leadsto \color{blue}{\frac{1 \cdot x}{\left(x - \left(-1 - y\right)\right) \cdot \left(x + y\right)}} \]

                          if 1.79999999999999989e156 < y

                          1. Initial program 69.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. Taylor expanded in x around 0

                            \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                          3. Step-by-step derivation
                            1. lower-/.f64N/A

                              \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                            2. lower-*.f64N/A

                              \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                            3. lower-+.f6448.7

                              \[\leadsto \frac{x}{y \cdot \left(1 + \color{blue}{y}\right)} \]
                          4. Applied rewrites48.7%

                            \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                          5. Step-by-step derivation
                            1. lift-/.f64N/A

                              \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                            2. lift-*.f64N/A

                              \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                            3. associate-/r*N/A

                              \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1 + y}} \]
                            4. lower-/.f64N/A

                              \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1 + y}} \]
                            5. lower-/.f6450.1

                              \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1} + y} \]
                            6. lift-+.f64N/A

                              \[\leadsto \frac{\frac{x}{y}}{1 + \color{blue}{y}} \]
                            7. +-commutativeN/A

                              \[\leadsto \frac{\frac{x}{y}}{y + \color{blue}{1}} \]
                            8. add-flipN/A

                              \[\leadsto \frac{\frac{x}{y}}{y - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}} \]
                            9. metadata-evalN/A

                              \[\leadsto \frac{\frac{x}{y}}{y - -1} \]
                            10. lower--.f6450.1

                              \[\leadsto \frac{\frac{x}{y}}{y - \color{blue}{-1}} \]
                          6. Applied rewrites50.1%

                            \[\leadsto \frac{\frac{x}{y}}{\color{blue}{y - -1}} \]
                        8. Recombined 3 regimes into one program.
                        9. Add Preprocessing

                        Alternative 9: 84.2% accurate, 1.0× speedup?

                        \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 2.45 \cdot 10^{-83}:\\ \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\ \mathbf{elif}\;y \leq 1.8 \cdot 10^{+156}:\\ \;\;\;\;\frac{1 \cdot x}{\left(y - -1\right) \cdot \left(x + y\right)}\\ \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.45e-83)
                           (/ (/ y (+ x y)) (+ 1.0 x))
                           (if (<= y 1.8e+156)
                             (/ (* 1.0 x) (* (- y -1.0) (+ x y)))
                             (/ (/ x y) (- y -1.0)))))
                        assert(x < y);
                        double code(double x, double y) {
                        	double tmp;
                        	if (y <= 2.45e-83) {
                        		tmp = (y / (x + y)) / (1.0 + x);
                        	} else if (y <= 1.8e+156) {
                        		tmp = (1.0 * x) / ((y - -1.0) * (x + y));
                        	} else {
                        		tmp = (x / y) / (y - -1.0);
                        	}
                        	return tmp;
                        }
                        
                        NOTE: x and y should be sorted in increasing order before calling this function.
                        module fmin_fmax_functions
                            implicit none
                            private
                            public fmax
                            public fmin
                        
                            interface fmax
                                module procedure fmax88
                                module procedure fmax44
                                module procedure fmax84
                                module procedure fmax48
                            end interface
                            interface fmin
                                module procedure fmin88
                                module procedure fmin44
                                module procedure fmin84
                                module procedure fmin48
                            end interface
                        contains
                            real(8) function fmax88(x, y) result (res)
                                real(8), intent (in) :: x
                                real(8), intent (in) :: y
                                res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                            end function
                            real(4) function fmax44(x, y) result (res)
                                real(4), intent (in) :: x
                                real(4), intent (in) :: y
                                res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                            end function
                            real(8) function fmax84(x, y) result(res)
                                real(8), intent (in) :: x
                                real(4), intent (in) :: y
                                res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                            end function
                            real(8) function fmax48(x, y) result(res)
                                real(4), intent (in) :: x
                                real(8), intent (in) :: y
                                res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                            end function
                            real(8) function fmin88(x, y) result (res)
                                real(8), intent (in) :: x
                                real(8), intent (in) :: y
                                res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                            end function
                            real(4) function fmin44(x, y) result (res)
                                real(4), intent (in) :: x
                                real(4), intent (in) :: y
                                res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                            end function
                            real(8) function fmin84(x, y) result(res)
                                real(8), intent (in) :: x
                                real(4), intent (in) :: y
                                res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                            end function
                            real(8) function fmin48(x, y) result(res)
                                real(4), intent (in) :: x
                                real(8), intent (in) :: y
                                res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                            end function
                        end module
                        
                        real(8) function code(x, y)
                        use fmin_fmax_functions
                            real(8), intent (in) :: x
                            real(8), intent (in) :: y
                            real(8) :: tmp
                            if (y <= 2.45d-83) then
                                tmp = (y / (x + y)) / (1.0d0 + x)
                            else if (y <= 1.8d+156) then
                                tmp = (1.0d0 * x) / ((y - (-1.0d0)) * (x + y))
                            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.45e-83) {
                        		tmp = (y / (x + y)) / (1.0 + x);
                        	} else if (y <= 1.8e+156) {
                        		tmp = (1.0 * x) / ((y - -1.0) * (x + y));
                        	} else {
                        		tmp = (x / y) / (y - -1.0);
                        	}
                        	return tmp;
                        }
                        
                        [x, y] = sort([x, y])
                        def code(x, y):
                        	tmp = 0
                        	if y <= 2.45e-83:
                        		tmp = (y / (x + y)) / (1.0 + x)
                        	elif y <= 1.8e+156:
                        		tmp = (1.0 * x) / ((y - -1.0) * (x + y))
                        	else:
                        		tmp = (x / y) / (y - -1.0)
                        	return tmp
                        
                        x, y = sort([x, y])
                        function code(x, y)
                        	tmp = 0.0
                        	if (y <= 2.45e-83)
                        		tmp = Float64(Float64(y / Float64(x + y)) / Float64(1.0 + x));
                        	elseif (y <= 1.8e+156)
                        		tmp = Float64(Float64(1.0 * x) / Float64(Float64(y - -1.0) * Float64(x + y)));
                        	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.45e-83)
                        		tmp = (y / (x + y)) / (1.0 + x);
                        	elseif (y <= 1.8e+156)
                        		tmp = (1.0 * x) / ((y - -1.0) * (x + y));
                        	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.45e-83], N[(N[(y / N[(x + y), $MachinePrecision]), $MachinePrecision] / N[(1.0 + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.8e+156], N[(N[(1.0 * x), $MachinePrecision] / N[(N[(y - -1.0), $MachinePrecision] * N[(x + y), $MachinePrecision]), $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.45 \cdot 10^{-83}:\\
                        \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\
                        
                        \mathbf{elif}\;y \leq 1.8 \cdot 10^{+156}:\\
                        \;\;\;\;\frac{1 \cdot x}{\left(y - -1\right) \cdot \left(x + y\right)}\\
                        
                        \mathbf{else}:\\
                        \;\;\;\;\frac{\frac{x}{y}}{y - -1}\\
                        
                        
                        \end{array}
                        \end{array}
                        
                        Derivation
                        1. Split input into 3 regimes
                        2. if y < 2.45e-83

                          1. Initial program 69.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. lift-/.f64N/A

                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                            2. lift-*.f64N/A

                              \[\leadsto \frac{\color{blue}{x \cdot y}}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                            3. *-commutativeN/A

                              \[\leadsto \frac{\color{blue}{y \cdot x}}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                            4. lift-*.f64N/A

                              \[\leadsto \frac{y \cdot x}{\color{blue}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                            5. lift-*.f64N/A

                              \[\leadsto \frac{y \cdot x}{\color{blue}{\left(\left(x + y\right) \cdot \left(x + y\right)\right)} \cdot \left(\left(x + y\right) + 1\right)} \]
                            6. associate-*l*N/A

                              \[\leadsto \frac{y \cdot x}{\color{blue}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}} \]
                            7. times-fracN/A

                              \[\leadsto \color{blue}{\frac{y}{x + y} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                            8. lower-*.f64N/A

                              \[\leadsto \color{blue}{\frac{y}{x + y} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                            9. lower-/.f64N/A

                              \[\leadsto \color{blue}{\frac{y}{x + y}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                            10. lift-+.f64N/A

                              \[\leadsto \frac{y}{\color{blue}{x + y}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                            11. +-commutativeN/A

                              \[\leadsto \frac{y}{\color{blue}{y + x}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                            12. lower-+.f64N/A

                              \[\leadsto \frac{y}{\color{blue}{y + x}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                            13. lower-/.f64N/A

                              \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                            14. *-commutativeN/A

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                            15. lower-*.f6493.6

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                            16. lift-+.f64N/A

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right)} \cdot \left(x + y\right)} \]
                            17. add-flipN/A

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                            18. lower--.f64N/A

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                            19. lift-+.f64N/A

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(x + y\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                            20. +-commutativeN/A

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                            21. lower-+.f64N/A

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                            22. metadata-eval93.6

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - \color{blue}{-1}\right) \cdot \left(x + y\right)} \]
                            23. lift-+.f64N/A

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(x + y\right)}} \]
                            24. +-commutativeN/A

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                            25. lower-+.f6493.6

                              \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                          3. Applied rewrites93.6%

                            \[\leadsto \color{blue}{\frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                          4. Step-by-step derivation
                            1. lift-*.f64N/A

                              \[\leadsto \color{blue}{\frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                            2. lift-/.f64N/A

                              \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                            3. div-flipN/A

                              \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                            4. mult-flip-revN/A

                              \[\leadsto \color{blue}{\frac{\frac{y}{y + x}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                            5. lower-/.f64N/A

                              \[\leadsto \color{blue}{\frac{\frac{y}{y + x}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                            6. lift-+.f64N/A

                              \[\leadsto \frac{\frac{y}{\color{blue}{y + x}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                            7. +-commutativeN/A

                              \[\leadsto \frac{\frac{y}{\color{blue}{x + y}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                            8. lift-+.f64N/A

                              \[\leadsto \frac{\frac{y}{\color{blue}{x + y}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                            9. lift-*.f64N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\frac{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}}{x}} \]
                            10. associate-/l*N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \frac{y + x}{x}}} \]
                            11. lower-*.f64N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \frac{y + x}{x}}} \]
                            12. lift-+.f64N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(y + x\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                            13. +-commutativeN/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                            14. lift-+.f64N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                            15. lower-/.f6499.3

                              \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \color{blue}{\frac{y + x}{x}}} \]
                            16. lift-+.f64N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{y + x}}{x}} \]
                            17. +-commutativeN/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                            18. lift-+.f6499.3

                              \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                          5. Applied rewrites99.3%

                            \[\leadsto \color{blue}{\frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}}} \]
                          6. Step-by-step derivation
                            1. lift-*.f64N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}}} \]
                            2. lift--.f64N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
                            3. metadata-evalN/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                            4. add-flipN/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(x + y\right) + 1\right)} \cdot \frac{x + y}{x}} \]
                            5. lift-+.f64N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} + 1\right) \cdot \frac{x + y}{x}} \]
                            6. *-commutativeN/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\frac{x + y}{x} \cdot \left(\left(x + y\right) + 1\right)}} \]
                            7. lower-*.f64N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\frac{x + y}{x} \cdot \left(\left(x + y\right) + 1\right)}} \]
                            8. associate-+l+N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x + \left(y + 1\right)\right)}} \]
                            9. metadata-evalN/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \left(y + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right)\right)} \]
                            10. sub-flipN/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(y - -1\right)}\right)} \]
                            11. sub-negate-revN/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(\mathsf{neg}\left(\left(-1 - y\right)\right)\right)}\right)} \]
                            12. sub-flip-reverseN/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
                            13. lower--.f64N/A

                              \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
                            14. lower--.f6499.3

                              \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{\left(-1 - y\right)}\right)} \]
                          7. Applied rewrites99.3%

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\frac{x + y}{x} \cdot \left(x - \left(-1 - y\right)\right)}} \]
                          8. Taylor expanded in y around 0

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{1 + x}} \]
                          9. Step-by-step derivation
                            1. lower-+.f6451.3

                              \[\leadsto \frac{\frac{y}{x + y}}{1 + \color{blue}{x}} \]
                          10. Applied rewrites51.3%

                            \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{1 + x}} \]

                          if 2.45e-83 < y < 1.79999999999999989e156

                          1. Initial program 69.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. Taylor expanded in x around 0

                            \[\leadsto \frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \color{blue}{\left(1 + y\right)}} \]
                          3. Step-by-step derivation
                            1. lower-+.f6458.7

                              \[\leadsto \frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(1 + \color{blue}{y}\right)} \]
                          4. Applied rewrites58.7%

                            \[\leadsto \frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \color{blue}{\left(1 + y\right)}} \]
                          5. Step-by-step derivation
                            1. lift-/.f64N/A

                              \[\leadsto \color{blue}{\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(1 + y\right)}} \]
                            2. lift-*.f64N/A

                              \[\leadsto \frac{x \cdot y}{\color{blue}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(1 + y\right)}} \]
                            3. lift-*.f64N/A

                              \[\leadsto \frac{x \cdot y}{\color{blue}{\left(\left(x + y\right) \cdot \left(x + y\right)\right)} \cdot \left(1 + y\right)} \]
                            4. associate-*l*N/A

                              \[\leadsto \frac{x \cdot y}{\color{blue}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(1 + y\right)\right)}} \]
                            5. lift-+.f64N/A

                              \[\leadsto \frac{x \cdot y}{\color{blue}{\left(x + y\right)} \cdot \left(\left(x + y\right) \cdot \left(1 + y\right)\right)} \]
                            6. +-commutativeN/A

                              \[\leadsto \frac{x \cdot y}{\color{blue}{\left(y + x\right)} \cdot \left(\left(x + y\right) \cdot \left(1 + y\right)\right)} \]
                            7. lift-+.f64N/A

                              \[\leadsto \frac{x \cdot y}{\color{blue}{\left(y + x\right)} \cdot \left(\left(x + y\right) \cdot \left(1 + y\right)\right)} \]
                            8. associate-/r*N/A

                              \[\leadsto \color{blue}{\frac{\frac{x \cdot y}{y + x}}{\left(x + y\right) \cdot \left(1 + y\right)}} \]
                            9. lift-*.f64N/A

                              \[\leadsto \frac{\frac{\color{blue}{x \cdot y}}{y + x}}{\left(x + y\right) \cdot \left(1 + y\right)} \]
                            10. *-commutativeN/A

                              \[\leadsto \frac{\frac{\color{blue}{y \cdot x}}{y + x}}{\left(x + y\right) \cdot \left(1 + y\right)} \]
                            11. associate-*l/N/A

                              \[\leadsto \frac{\color{blue}{\frac{y}{y + x} \cdot x}}{\left(x + y\right) \cdot \left(1 + y\right)} \]
                            12. lift-/.f64N/A

                              \[\leadsto \frac{\color{blue}{\frac{y}{y + x}} \cdot x}{\left(x + y\right) \cdot \left(1 + y\right)} \]
                            13. lower-/.f64N/A

                              \[\leadsto \color{blue}{\frac{\frac{y}{y + x} \cdot x}{\left(x + y\right) \cdot \left(1 + y\right)}} \]
                            14. lower-*.f64N/A

                              \[\leadsto \frac{\color{blue}{\frac{y}{y + x} \cdot x}}{\left(x + y\right) \cdot \left(1 + y\right)} \]
                            15. lift-+.f64N/A

                              \[\leadsto \frac{\frac{y}{\color{blue}{y + x}} \cdot x}{\left(x + y\right) \cdot \left(1 + y\right)} \]
                            16. +-commutativeN/A

                              \[\leadsto \frac{\frac{y}{\color{blue}{x + y}} \cdot x}{\left(x + y\right) \cdot \left(1 + y\right)} \]
                            17. lift-+.f64N/A

                              \[\leadsto \frac{\frac{y}{\color{blue}{x + y}} \cdot x}{\left(x + y\right) \cdot \left(1 + y\right)} \]
                          6. Applied rewrites75.8%

                            \[\leadsto \color{blue}{\frac{\frac{y}{x + y} \cdot x}{\left(y - -1\right) \cdot \left(x + y\right)}} \]
                          7. Taylor expanded in x around 0

                            \[\leadsto \frac{\color{blue}{1} \cdot x}{\left(y - -1\right) \cdot \left(x + y\right)} \]
                          8. Step-by-step derivation
                            1. Applied rewrites51.8%

                              \[\leadsto \frac{\color{blue}{1} \cdot x}{\left(y - -1\right) \cdot \left(x + y\right)} \]

                            if 1.79999999999999989e156 < y

                            1. Initial program 69.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. Taylor expanded in x around 0

                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                            3. Step-by-step derivation
                              1. lower-/.f64N/A

                                \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                              2. lower-*.f64N/A

                                \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                              3. lower-+.f6448.7

                                \[\leadsto \frac{x}{y \cdot \left(1 + \color{blue}{y}\right)} \]
                            4. Applied rewrites48.7%

                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                            5. Step-by-step derivation
                              1. lift-/.f64N/A

                                \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                              2. lift-*.f64N/A

                                \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                              3. associate-/r*N/A

                                \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1 + y}} \]
                              4. lower-/.f64N/A

                                \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1 + y}} \]
                              5. lower-/.f6450.1

                                \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1} + y} \]
                              6. lift-+.f64N/A

                                \[\leadsto \frac{\frac{x}{y}}{1 + \color{blue}{y}} \]
                              7. +-commutativeN/A

                                \[\leadsto \frac{\frac{x}{y}}{y + \color{blue}{1}} \]
                              8. add-flipN/A

                                \[\leadsto \frac{\frac{x}{y}}{y - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}} \]
                              9. metadata-evalN/A

                                \[\leadsto \frac{\frac{x}{y}}{y - -1} \]
                              10. lower--.f6450.1

                                \[\leadsto \frac{\frac{x}{y}}{y - \color{blue}{-1}} \]
                            6. Applied rewrites50.1%

                              \[\leadsto \frac{\frac{x}{y}}{\color{blue}{y - -1}} \]
                          9. Recombined 3 regimes into one program.
                          10. Add Preprocessing

                          Alternative 10: 82.7% accurate, 1.4× speedup?

                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 5.5 \cdot 10^{-83}:\\ \;\;\;\;\frac{\frac{y}{x + y}}{1 + 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 (<= y 5.5e-83) (/ (/ y (+ x y)) (+ 1.0 x)) (/ (/ x y) (- y -1.0))))
                          assert(x < y);
                          double code(double x, double y) {
                          	double tmp;
                          	if (y <= 5.5e-83) {
                          		tmp = (y / (x + y)) / (1.0 + x);
                          	} else {
                          		tmp = (x / y) / (y - -1.0);
                          	}
                          	return tmp;
                          }
                          
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          module fmin_fmax_functions
                              implicit none
                              private
                              public fmax
                              public fmin
                          
                              interface fmax
                                  module procedure fmax88
                                  module procedure fmax44
                                  module procedure fmax84
                                  module procedure fmax48
                              end interface
                              interface fmin
                                  module procedure fmin88
                                  module procedure fmin44
                                  module procedure fmin84
                                  module procedure fmin48
                              end interface
                          contains
                              real(8) function fmax88(x, y) result (res)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                              end function
                              real(4) function fmax44(x, y) result (res)
                                  real(4), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                              end function
                              real(8) function fmax84(x, y) result(res)
                                  real(8), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                              end function
                              real(8) function fmax48(x, y) result(res)
                                  real(4), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                              end function
                              real(8) function fmin88(x, y) result (res)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                              end function
                              real(4) function fmin44(x, y) result (res)
                                  real(4), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                              end function
                              real(8) function fmin84(x, y) result(res)
                                  real(8), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                              end function
                              real(8) function fmin48(x, y) result(res)
                                  real(4), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                              end function
                          end module
                          
                          real(8) function code(x, y)
                          use fmin_fmax_functions
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              real(8) :: tmp
                              if (y <= 5.5d-83) then
                                  tmp = (y / (x + y)) / (1.0d0 + 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 (y <= 5.5e-83) {
                          		tmp = (y / (x + y)) / (1.0 + x);
                          	} else {
                          		tmp = (x / y) / (y - -1.0);
                          	}
                          	return tmp;
                          }
                          
                          [x, y] = sort([x, y])
                          def code(x, y):
                          	tmp = 0
                          	if y <= 5.5e-83:
                          		tmp = (y / (x + y)) / (1.0 + x)
                          	else:
                          		tmp = (x / y) / (y - -1.0)
                          	return tmp
                          
                          x, y = sort([x, y])
                          function code(x, y)
                          	tmp = 0.0
                          	if (y <= 5.5e-83)
                          		tmp = Float64(Float64(y / Float64(x + y)) / Float64(1.0 + 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 (y <= 5.5e-83)
                          		tmp = (y / (x + y)) / (1.0 + 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[y, 5.5e-83], N[(N[(y / N[(x + y), $MachinePrecision]), $MachinePrecision] / N[(1.0 + 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}\;y \leq 5.5 \cdot 10^{-83}:\\
                          \;\;\;\;\frac{\frac{y}{x + y}}{1 + x}\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\frac{\frac{x}{y}}{y - -1}\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 2 regimes
                          2. if y < 5.49999999999999964e-83

                            1. Initial program 69.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. lift-/.f64N/A

                                \[\leadsto \color{blue}{\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                              2. lift-*.f64N/A

                                \[\leadsto \frac{\color{blue}{x \cdot y}}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                              3. *-commutativeN/A

                                \[\leadsto \frac{\color{blue}{y \cdot x}}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                              4. lift-*.f64N/A

                                \[\leadsto \frac{y \cdot x}{\color{blue}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                              5. lift-*.f64N/A

                                \[\leadsto \frac{y \cdot x}{\color{blue}{\left(\left(x + y\right) \cdot \left(x + y\right)\right)} \cdot \left(\left(x + y\right) + 1\right)} \]
                              6. associate-*l*N/A

                                \[\leadsto \frac{y \cdot x}{\color{blue}{\left(x + y\right) \cdot \left(\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)\right)}} \]
                              7. times-fracN/A

                                \[\leadsto \color{blue}{\frac{y}{x + y} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                              8. lower-*.f64N/A

                                \[\leadsto \color{blue}{\frac{y}{x + y} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                              9. lower-/.f64N/A

                                \[\leadsto \color{blue}{\frac{y}{x + y}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                              10. lift-+.f64N/A

                                \[\leadsto \frac{y}{\color{blue}{x + y}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                              11. +-commutativeN/A

                                \[\leadsto \frac{y}{\color{blue}{y + x}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                              12. lower-+.f64N/A

                                \[\leadsto \frac{y}{\color{blue}{y + x}} \cdot \frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)} \]
                              13. lower-/.f64N/A

                                \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(x + y\right) \cdot \left(\left(x + y\right) + 1\right)}} \]
                              14. *-commutativeN/A

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                              15. lower-*.f6493.6

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right) \cdot \left(x + y\right)}} \]
                              16. lift-+.f64N/A

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) + 1\right)} \cdot \left(x + y\right)} \]
                              17. add-flipN/A

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                              18. lower--.f64N/A

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\color{blue}{\left(\left(x + y\right) - \left(\mathsf{neg}\left(1\right)\right)\right)} \cdot \left(x + y\right)} \]
                              19. lift-+.f64N/A

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(x + y\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                              20. +-commutativeN/A

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                              21. lower-+.f64N/A

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\color{blue}{\left(y + x\right)} - \left(\mathsf{neg}\left(1\right)\right)\right) \cdot \left(x + y\right)} \]
                              22. metadata-eval93.6

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - \color{blue}{-1}\right) \cdot \left(x + y\right)} \]
                              23. lift-+.f64N/A

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(x + y\right)}} \]
                              24. +-commutativeN/A

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                              25. lower-+.f6493.6

                                \[\leadsto \frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \color{blue}{\left(y + x\right)}} \]
                            3. Applied rewrites93.6%

                              \[\leadsto \color{blue}{\frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                            4. Step-by-step derivation
                              1. lift-*.f64N/A

                                \[\leadsto \color{blue}{\frac{y}{y + x} \cdot \frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                              2. lift-/.f64N/A

                                \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{x}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}} \]
                              3. div-flipN/A

                                \[\leadsto \frac{y}{y + x} \cdot \color{blue}{\frac{1}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                              4. mult-flip-revN/A

                                \[\leadsto \color{blue}{\frac{\frac{y}{y + x}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                              5. lower-/.f64N/A

                                \[\leadsto \color{blue}{\frac{\frac{y}{y + x}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}}} \]
                              6. lift-+.f64N/A

                                \[\leadsto \frac{\frac{y}{\color{blue}{y + x}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                              7. +-commutativeN/A

                                \[\leadsto \frac{\frac{y}{\color{blue}{x + y}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                              8. lift-+.f64N/A

                                \[\leadsto \frac{\frac{y}{\color{blue}{x + y}}}{\frac{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}{x}} \]
                              9. lift-*.f64N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\frac{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \left(y + x\right)}}{x}} \]
                              10. associate-/l*N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \frac{y + x}{x}}} \]
                              11. lower-*.f64N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(y + x\right) - -1\right) \cdot \frac{y + x}{x}}} \]
                              12. lift-+.f64N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(y + x\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                              13. +-commutativeN/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                              14. lift-+.f64N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} - -1\right) \cdot \frac{y + x}{x}} \]
                              15. lower-/.f6499.3

                                \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \color{blue}{\frac{y + x}{x}}} \]
                              16. lift-+.f64N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{y + x}}{x}} \]
                              17. +-commutativeN/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                              18. lift-+.f6499.3

                                \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{\color{blue}{x + y}}{x}} \]
                            5. Applied rewrites99.3%

                              \[\leadsto \color{blue}{\frac{\frac{y}{x + y}}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}}} \]
                            6. Step-by-step derivation
                              1. lift-*.f64N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(x + y\right) - -1\right) \cdot \frac{x + y}{x}}} \]
                              2. lift--.f64N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(x + y\right) - -1\right)} \cdot \frac{x + y}{x}} \]
                              3. metadata-evalN/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\left(\left(x + y\right) - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}\right) \cdot \frac{x + y}{x}} \]
                              4. add-flipN/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\left(\left(x + y\right) + 1\right)} \cdot \frac{x + y}{x}} \]
                              5. lift-+.f64N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\left(\color{blue}{\left(x + y\right)} + 1\right) \cdot \frac{x + y}{x}} \]
                              6. *-commutativeN/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\frac{x + y}{x} \cdot \left(\left(x + y\right) + 1\right)}} \]
                              7. lower-*.f64N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\frac{x + y}{x} \cdot \left(\left(x + y\right) + 1\right)}} \]
                              8. associate-+l+N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x + \left(y + 1\right)\right)}} \]
                              9. metadata-evalN/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \left(y + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right)}\right)\right)} \]
                              10. sub-flipN/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(y - -1\right)}\right)} \]
                              11. sub-negate-revN/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x + \color{blue}{\left(\mathsf{neg}\left(\left(-1 - y\right)\right)\right)}\right)} \]
                              12. sub-flip-reverseN/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
                              13. lower--.f64N/A

                                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \color{blue}{\left(x - \left(-1 - y\right)\right)}} \]
                              14. lower--.f6499.3

                                \[\leadsto \frac{\frac{y}{x + y}}{\frac{x + y}{x} \cdot \left(x - \color{blue}{\left(-1 - y\right)}\right)} \]
                            7. Applied rewrites99.3%

                              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{\frac{x + y}{x} \cdot \left(x - \left(-1 - y\right)\right)}} \]
                            8. Taylor expanded in y around 0

                              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{1 + x}} \]
                            9. Step-by-step derivation
                              1. lower-+.f6451.3

                                \[\leadsto \frac{\frac{y}{x + y}}{1 + \color{blue}{x}} \]
                            10. Applied rewrites51.3%

                              \[\leadsto \frac{\frac{y}{x + y}}{\color{blue}{1 + x}} \]

                            if 5.49999999999999964e-83 < y

                            1. Initial program 69.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. Taylor expanded in x around 0

                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                            3. Step-by-step derivation
                              1. lower-/.f64N/A

                                \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                              2. lower-*.f64N/A

                                \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                              3. lower-+.f6448.7

                                \[\leadsto \frac{x}{y \cdot \left(1 + \color{blue}{y}\right)} \]
                            4. Applied rewrites48.7%

                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                            5. Step-by-step derivation
                              1. lift-/.f64N/A

                                \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                              2. lift-*.f64N/A

                                \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                              3. associate-/r*N/A

                                \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1 + y}} \]
                              4. lower-/.f64N/A

                                \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1 + y}} \]
                              5. lower-/.f6450.1

                                \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1} + y} \]
                              6. lift-+.f64N/A

                                \[\leadsto \frac{\frac{x}{y}}{1 + \color{blue}{y}} \]
                              7. +-commutativeN/A

                                \[\leadsto \frac{\frac{x}{y}}{y + \color{blue}{1}} \]
                              8. add-flipN/A

                                \[\leadsto \frac{\frac{x}{y}}{y - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}} \]
                              9. metadata-evalN/A

                                \[\leadsto \frac{\frac{x}{y}}{y - -1} \]
                              10. lower--.f6450.1

                                \[\leadsto \frac{\frac{x}{y}}{y - \color{blue}{-1}} \]
                            6. Applied rewrites50.1%

                              \[\leadsto \frac{\frac{x}{y}}{\color{blue}{y - -1}} \]
                          3. Recombined 2 regimes into one program.
                          4. Add Preprocessing

                          Alternative 11: 81.0% accurate, 1.7× speedup?

                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 3.8 \cdot 10^{-67}:\\ \;\;\;\;\frac{y}{x \cdot \left(1 + x\right)}\\ \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 3.8e-67) (/ y (* x (+ 1.0 x))) (/ (/ x y) (- y -1.0))))
                          assert(x < y);
                          double code(double x, double y) {
                          	double tmp;
                          	if (y <= 3.8e-67) {
                          		tmp = y / (x * (1.0 + x));
                          	} else {
                          		tmp = (x / y) / (y - -1.0);
                          	}
                          	return tmp;
                          }
                          
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          module fmin_fmax_functions
                              implicit none
                              private
                              public fmax
                              public fmin
                          
                              interface fmax
                                  module procedure fmax88
                                  module procedure fmax44
                                  module procedure fmax84
                                  module procedure fmax48
                              end interface
                              interface fmin
                                  module procedure fmin88
                                  module procedure fmin44
                                  module procedure fmin84
                                  module procedure fmin48
                              end interface
                          contains
                              real(8) function fmax88(x, y) result (res)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                              end function
                              real(4) function fmax44(x, y) result (res)
                                  real(4), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                              end function
                              real(8) function fmax84(x, y) result(res)
                                  real(8), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                              end function
                              real(8) function fmax48(x, y) result(res)
                                  real(4), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                              end function
                              real(8) function fmin88(x, y) result (res)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                              end function
                              real(4) function fmin44(x, y) result (res)
                                  real(4), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                              end function
                              real(8) function fmin84(x, y) result(res)
                                  real(8), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                              end function
                              real(8) function fmin48(x, y) result(res)
                                  real(4), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                              end function
                          end module
                          
                          real(8) function code(x, y)
                          use fmin_fmax_functions
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              real(8) :: tmp
                              if (y <= 3.8d-67) then
                                  tmp = y / (x * (1.0d0 + 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 (y <= 3.8e-67) {
                          		tmp = y / (x * (1.0 + x));
                          	} else {
                          		tmp = (x / y) / (y - -1.0);
                          	}
                          	return tmp;
                          }
                          
                          [x, y] = sort([x, y])
                          def code(x, y):
                          	tmp = 0
                          	if y <= 3.8e-67:
                          		tmp = y / (x * (1.0 + x))
                          	else:
                          		tmp = (x / y) / (y - -1.0)
                          	return tmp
                          
                          x, y = sort([x, y])
                          function code(x, y)
                          	tmp = 0.0
                          	if (y <= 3.8e-67)
                          		tmp = Float64(y / Float64(x * Float64(1.0 + 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 (y <= 3.8e-67)
                          		tmp = y / (x * (1.0 + 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[y, 3.8e-67], N[(y / N[(x * N[(1.0 + x), $MachinePrecision]), $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 3.8 \cdot 10^{-67}:\\
                          \;\;\;\;\frac{y}{x \cdot \left(1 + x\right)}\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\frac{\frac{x}{y}}{y - -1}\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 2 regimes
                          2. if y < 3.79999999999999988e-67

                            1. Initial program 69.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. Taylor expanded in y around 0

                              \[\leadsto \color{blue}{\frac{y}{x \cdot \left(1 + x\right)}} \]
                            3. Step-by-step derivation
                              1. lower-/.f64N/A

                                \[\leadsto \frac{y}{\color{blue}{x \cdot \left(1 + x\right)}} \]
                              2. lower-*.f64N/A

                                \[\leadsto \frac{y}{x \cdot \color{blue}{\left(1 + x\right)}} \]
                              3. lower-+.f6449.5

                                \[\leadsto \frac{y}{x \cdot \left(1 + \color{blue}{x}\right)} \]
                            4. Applied rewrites49.5%

                              \[\leadsto \color{blue}{\frac{y}{x \cdot \left(1 + x\right)}} \]

                            if 3.79999999999999988e-67 < y

                            1. Initial program 69.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. Taylor expanded in x around 0

                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                            3. Step-by-step derivation
                              1. lower-/.f64N/A

                                \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                              2. lower-*.f64N/A

                                \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                              3. lower-+.f6448.7

                                \[\leadsto \frac{x}{y \cdot \left(1 + \color{blue}{y}\right)} \]
                            4. Applied rewrites48.7%

                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                            5. Step-by-step derivation
                              1. lift-/.f64N/A

                                \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                              2. lift-*.f64N/A

                                \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                              3. associate-/r*N/A

                                \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1 + y}} \]
                              4. lower-/.f64N/A

                                \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1 + y}} \]
                              5. lower-/.f6450.1

                                \[\leadsto \frac{\frac{x}{y}}{\color{blue}{1} + y} \]
                              6. lift-+.f64N/A

                                \[\leadsto \frac{\frac{x}{y}}{1 + \color{blue}{y}} \]
                              7. +-commutativeN/A

                                \[\leadsto \frac{\frac{x}{y}}{y + \color{blue}{1}} \]
                              8. add-flipN/A

                                \[\leadsto \frac{\frac{x}{y}}{y - \color{blue}{\left(\mathsf{neg}\left(1\right)\right)}} \]
                              9. metadata-evalN/A

                                \[\leadsto \frac{\frac{x}{y}}{y - -1} \]
                              10. lower--.f6450.1

                                \[\leadsto \frac{\frac{x}{y}}{y - \color{blue}{-1}} \]
                            6. Applied rewrites50.1%

                              \[\leadsto \frac{\frac{x}{y}}{\color{blue}{y - -1}} \]
                          3. Recombined 2 regimes into one program.
                          4. Add Preprocessing

                          Alternative 12: 78.9% accurate, 1.7× speedup?

                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 3.8 \cdot 10^{-67}:\\ \;\;\;\;\frac{y}{x \cdot \left(1 + x\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{\mathsf{fma}\left(y, y, y\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 (<= y 3.8e-67) (/ y (* x (+ 1.0 x))) (/ x (fma y y y))))
                          assert(x < y);
                          double code(double x, double y) {
                          	double tmp;
                          	if (y <= 3.8e-67) {
                          		tmp = y / (x * (1.0 + x));
                          	} else {
                          		tmp = x / fma(y, y, y);
                          	}
                          	return tmp;
                          }
                          
                          x, y = sort([x, y])
                          function code(x, y)
                          	tmp = 0.0
                          	if (y <= 3.8e-67)
                          		tmp = Float64(y / Float64(x * Float64(1.0 + x)));
                          	else
                          		tmp = Float64(x / fma(y, y, y));
                          	end
                          	return tmp
                          end
                          
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          code[x_, y_] := If[LessEqual[y, 3.8e-67], N[(y / N[(x * N[(1.0 + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * y + y), $MachinePrecision]), $MachinePrecision]]
                          
                          \begin{array}{l}
                          [x, y] = \mathsf{sort}([x, y])\\
                          \\
                          \begin{array}{l}
                          \mathbf{if}\;y \leq 3.8 \cdot 10^{-67}:\\
                          \;\;\;\;\frac{y}{x \cdot \left(1 + x\right)}\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\frac{x}{\mathsf{fma}\left(y, y, y\right)}\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 2 regimes
                          2. if y < 3.79999999999999988e-67

                            1. Initial program 69.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. Taylor expanded in y around 0

                              \[\leadsto \color{blue}{\frac{y}{x \cdot \left(1 + x\right)}} \]
                            3. Step-by-step derivation
                              1. lower-/.f64N/A

                                \[\leadsto \frac{y}{\color{blue}{x \cdot \left(1 + x\right)}} \]
                              2. lower-*.f64N/A

                                \[\leadsto \frac{y}{x \cdot \color{blue}{\left(1 + x\right)}} \]
                              3. lower-+.f6449.5

                                \[\leadsto \frac{y}{x \cdot \left(1 + \color{blue}{x}\right)} \]
                            4. Applied rewrites49.5%

                              \[\leadsto \color{blue}{\frac{y}{x \cdot \left(1 + x\right)}} \]

                            if 3.79999999999999988e-67 < y

                            1. Initial program 69.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. Taylor expanded in x around 0

                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                            3. Step-by-step derivation
                              1. lower-/.f64N/A

                                \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                              2. lower-*.f64N/A

                                \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                              3. lower-+.f6448.7

                                \[\leadsto \frac{x}{y \cdot \left(1 + \color{blue}{y}\right)} \]
                            4. Applied rewrites48.7%

                              \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                            5. Step-by-step derivation
                              1. lift-*.f64N/A

                                \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                              2. lift-+.f64N/A

                                \[\leadsto \frac{x}{y \cdot \left(1 + \color{blue}{y}\right)} \]
                              3. +-commutativeN/A

                                \[\leadsto \frac{x}{y \cdot \left(y + \color{blue}{1}\right)} \]
                              4. distribute-rgt-inN/A

                                \[\leadsto \frac{x}{y \cdot y + \color{blue}{1 \cdot y}} \]
                              5. *-lft-identityN/A

                                \[\leadsto \frac{x}{y \cdot y + y} \]
                              6. lower-fma.f6448.7

                                \[\leadsto \frac{x}{\mathsf{fma}\left(y, \color{blue}{y}, y\right)} \]
                            6. Applied rewrites48.7%

                              \[\leadsto \color{blue}{\frac{x}{\mathsf{fma}\left(y, y, y\right)}} \]
                          3. Recombined 2 regimes into one program.
                          4. Add Preprocessing

                          Alternative 13: 48.7% accurate, 2.6× speedup?

                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \frac{x}{\mathsf{fma}\left(y, y, y\right)} \end{array} \]
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          (FPCore (x y) :precision binary64 (/ x (fma y y y)))
                          assert(x < y);
                          double code(double x, double y) {
                          	return x / fma(y, y, y);
                          }
                          
                          x, y = sort([x, y])
                          function code(x, y)
                          	return Float64(x / fma(y, y, y))
                          end
                          
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          code[x_, y_] := N[(x / N[(y * y + y), $MachinePrecision]), $MachinePrecision]
                          
                          \begin{array}{l}
                          [x, y] = \mathsf{sort}([x, y])\\
                          \\
                          \frac{x}{\mathsf{fma}\left(y, y, y\right)}
                          \end{array}
                          
                          Derivation
                          1. Initial program 69.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. Taylor expanded in x around 0

                            \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                          3. Step-by-step derivation
                            1. lower-/.f64N/A

                              \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                            2. lower-*.f64N/A

                              \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                            3. lower-+.f6448.7

                              \[\leadsto \frac{x}{y \cdot \left(1 + \color{blue}{y}\right)} \]
                          4. Applied rewrites48.7%

                            \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                          5. Step-by-step derivation
                            1. lift-*.f64N/A

                              \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                            2. lift-+.f64N/A

                              \[\leadsto \frac{x}{y \cdot \left(1 + \color{blue}{y}\right)} \]
                            3. +-commutativeN/A

                              \[\leadsto \frac{x}{y \cdot \left(y + \color{blue}{1}\right)} \]
                            4. distribute-rgt-inN/A

                              \[\leadsto \frac{x}{y \cdot y + \color{blue}{1 \cdot y}} \]
                            5. *-lft-identityN/A

                              \[\leadsto \frac{x}{y \cdot y + y} \]
                            6. lower-fma.f6448.7

                              \[\leadsto \frac{x}{\mathsf{fma}\left(y, \color{blue}{y}, y\right)} \]
                          6. Applied rewrites48.7%

                            \[\leadsto \color{blue}{\frac{x}{\mathsf{fma}\left(y, y, y\right)}} \]
                          7. Add Preprocessing

                          Alternative 14: 27.2% accurate, 3.1× speedup?

                          \[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \frac{1}{\frac{y}{x}} \end{array} \]
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          (FPCore (x y) :precision binary64 (/ 1.0 (/ y x)))
                          assert(x < y);
                          double code(double x, double y) {
                          	return 1.0 / (y / x);
                          }
                          
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          module fmin_fmax_functions
                              implicit none
                              private
                              public fmax
                              public fmin
                          
                              interface fmax
                                  module procedure fmax88
                                  module procedure fmax44
                                  module procedure fmax84
                                  module procedure fmax48
                              end interface
                              interface fmin
                                  module procedure fmin88
                                  module procedure fmin44
                                  module procedure fmin84
                                  module procedure fmin48
                              end interface
                          contains
                              real(8) function fmax88(x, y) result (res)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                              end function
                              real(4) function fmax44(x, y) result (res)
                                  real(4), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                              end function
                              real(8) function fmax84(x, y) result(res)
                                  real(8), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                              end function
                              real(8) function fmax48(x, y) result(res)
                                  real(4), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                              end function
                              real(8) function fmin88(x, y) result (res)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                              end function
                              real(4) function fmin44(x, y) result (res)
                                  real(4), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                              end function
                              real(8) function fmin84(x, y) result(res)
                                  real(8), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                              end function
                              real(8) function fmin48(x, y) result(res)
                                  real(4), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                              end function
                          end module
                          
                          real(8) function code(x, y)
                          use fmin_fmax_functions
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              code = 1.0d0 / (y / x)
                          end function
                          
                          assert x < y;
                          public static double code(double x, double y) {
                          	return 1.0 / (y / x);
                          }
                          
                          [x, y] = sort([x, y])
                          def code(x, y):
                          	return 1.0 / (y / x)
                          
                          x, y = sort([x, y])
                          function code(x, y)
                          	return Float64(1.0 / Float64(y / x))
                          end
                          
                          x, y = num2cell(sort([x, y])){:}
                          function tmp = code(x, y)
                          	tmp = 1.0 / (y / x);
                          end
                          
                          NOTE: x and y should be sorted in increasing order before calling this function.
                          code[x_, y_] := N[(1.0 / N[(y / x), $MachinePrecision]), $MachinePrecision]
                          
                          \begin{array}{l}
                          [x, y] = \mathsf{sort}([x, y])\\
                          \\
                          \frac{1}{\frac{y}{x}}
                          \end{array}
                          
                          Derivation
                          1. Initial program 69.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. Taylor expanded in x around 0

                            \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                          3. Step-by-step derivation
                            1. lower-/.f64N/A

                              \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                            2. lower-*.f64N/A

                              \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                            3. lower-+.f6448.7

                              \[\leadsto \frac{x}{y \cdot \left(1 + \color{blue}{y}\right)} \]
                          4. Applied rewrites48.7%

                            \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                          5. Taylor expanded in y around 0

                            \[\leadsto \frac{x}{\color{blue}{y}} \]
                          6. Step-by-step derivation
                            1. lower-/.f6426.7

                              \[\leadsto \frac{x}{y} \]
                          7. Applied rewrites26.7%

                            \[\leadsto \frac{x}{\color{blue}{y}} \]
                          8. Step-by-step derivation
                            1. lift-/.f64N/A

                              \[\leadsto \frac{x}{y} \]
                            2. div-flipN/A

                              \[\leadsto \frac{1}{\frac{y}{\color{blue}{x}}} \]
                            3. lower-/.f64N/A

                              \[\leadsto \frac{1}{\frac{y}{\color{blue}{x}}} \]
                            4. lower-/.f6427.2

                              \[\leadsto \frac{1}{\frac{y}{x}} \]
                          9. Applied rewrites27.2%

                            \[\leadsto \frac{1}{\frac{y}{\color{blue}{x}}} \]
                          10. Add Preprocessing

                          Alternative 15: 26.7% accurate, 5.5× 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.
                          module fmin_fmax_functions
                              implicit none
                              private
                              public fmax
                              public fmin
                          
                              interface fmax
                                  module procedure fmax88
                                  module procedure fmax44
                                  module procedure fmax84
                                  module procedure fmax48
                              end interface
                              interface fmin
                                  module procedure fmin88
                                  module procedure fmin44
                                  module procedure fmin84
                                  module procedure fmin48
                              end interface
                          contains
                              real(8) function fmax88(x, y) result (res)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                              end function
                              real(4) function fmax44(x, y) result (res)
                                  real(4), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                              end function
                              real(8) function fmax84(x, y) result(res)
                                  real(8), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                              end function
                              real(8) function fmax48(x, y) result(res)
                                  real(4), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                              end function
                              real(8) function fmin88(x, y) result (res)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                              end function
                              real(4) function fmin44(x, y) result (res)
                                  real(4), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                              end function
                              real(8) function fmin84(x, y) result(res)
                                  real(8), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                              end function
                              real(8) function fmin48(x, y) result(res)
                                  real(4), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                              end function
                          end module
                          
                          real(8) function code(x, y)
                          use fmin_fmax_functions
                              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 69.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. Taylor expanded in x around 0

                            \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                          3. Step-by-step derivation
                            1. lower-/.f64N/A

                              \[\leadsto \frac{x}{\color{blue}{y \cdot \left(1 + y\right)}} \]
                            2. lower-*.f64N/A

                              \[\leadsto \frac{x}{y \cdot \color{blue}{\left(1 + y\right)}} \]
                            3. lower-+.f6448.7

                              \[\leadsto \frac{x}{y \cdot \left(1 + \color{blue}{y}\right)} \]
                          4. Applied rewrites48.7%

                            \[\leadsto \color{blue}{\frac{x}{y \cdot \left(1 + y\right)}} \]
                          5. Taylor expanded in y around 0

                            \[\leadsto \frac{x}{\color{blue}{y}} \]
                          6. Step-by-step derivation
                            1. lower-/.f6426.7

                              \[\leadsto \frac{x}{y} \]
                          7. Applied rewrites26.7%

                            \[\leadsto \frac{x}{\color{blue}{y}} \]
                          8. Add Preprocessing

                          Reproduce

                          ?
                          herbie shell --seed 2025156 
                          (FPCore (x y)
                            :name "Numeric.SpecFunctions:incompleteBetaApprox from math-functions-0.1.5.2, A"
                            :precision binary64
                            (/ (* x y) (* (* (+ x y) (+ x y)) (+ (+ x y) 1.0))))