Average Error: 0.0 → 0.0
Time: 3.3s
Precision: 64
\[\left(1 + a\right) - x\]
\[\left(1 + a\right) - x\]
\left(1 + a\right) - x
\left(1 + a\right) - x
double f(double a, double x) {
        double r52476 = 1.0;
        double r52477 = a;
        double r52478 = r52476 + r52477;
        double r52479 = x;
        double r52480 = r52478 - r52479;
        return r52480;
}

double f(double a, double x) {
        double r52481 = 1.0;
        double r52482 = a;
        double r52483 = r52481 + r52482;
        double r52484 = x;
        double r52485 = r52483 - r52484;
        return r52485;
}

Error

Bits error versus a

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[\left(1 + a\right) - x\]
  2. Final simplification0.0

    \[\leadsto \left(1 + a\right) - x\]

Reproduce

herbie shell --seed 1 
(FPCore (a x)
  :name "1+a-x"
  :precision binary64
  (- (+ 1 a) x))