Average Error: 0.0 → 0.0
Time: 4.6s
Precision: 64
\[\frac{x + y}{y + 1}\]
\[\frac{y + x}{y + 1}\]
\frac{x + y}{y + 1}
\frac{y + x}{y + 1}
double f(double x, double y) {
        double r10065784 = x;
        double r10065785 = y;
        double r10065786 = r10065784 + r10065785;
        double r10065787 = 1.0;
        double r10065788 = r10065785 + r10065787;
        double r10065789 = r10065786 / r10065788;
        return r10065789;
}

double f(double x, double y) {
        double r10065790 = y;
        double r10065791 = x;
        double r10065792 = r10065790 + r10065791;
        double r10065793 = 1.0;
        double r10065794 = r10065790 + r10065793;
        double r10065795 = r10065792 / r10065794;
        return r10065795;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[\frac{x + y}{y + 1}\]
  2. Final simplification0.0

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

Reproduce

herbie shell --seed 2019171 +o rules:numerics
(FPCore (x y)
  :name "Data.Colour.SRGB:invTransferFunction from colour-2.3.3"
  (/ (+ x y) (+ y 1.0)))