Average Error: 0.0 → 0.1
Time: 15.8s
Precision: 64
\[\frac{x - y}{1 - y}\]
\[\frac{1}{\frac{1 - y}{x - y}}\]
\frac{x - y}{1 - y}
\frac{1}{\frac{1 - y}{x - y}}
double f(double x, double y) {
        double r151327 = x;
        double r151328 = y;
        double r151329 = r151327 - r151328;
        double r151330 = 1.0;
        double r151331 = r151330 - r151328;
        double r151332 = r151329 / r151331;
        return r151332;
}

double f(double x, double y) {
        double r151333 = 1.0;
        double r151334 = 1.0;
        double r151335 = y;
        double r151336 = r151334 - r151335;
        double r151337 = x;
        double r151338 = r151337 - r151335;
        double r151339 = r151336 / r151338;
        double r151340 = r151333 / r151339;
        return r151340;
}

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}{1 - y}\]
  2. Using strategy rm
  3. Applied clear-num0.1

    \[\leadsto \color{blue}{\frac{1}{\frac{1 - y}{x - y}}}\]
  4. Final simplification0.1

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

Reproduce

herbie shell --seed 2019304 
(FPCore (x y)
  :name "Diagrams.Trail:splitAtParam  from diagrams-lib-1.3.0.3, C"
  :precision binary64
  (/ (- x y) (- 1 y)))