Average Error: 32.1 → 0
Time: 3.2s
Precision: 64
\[10^{+30} + \left(x - 10^{+30}\right) \cdot 1\]
\[x\]
10^{+30} + \left(x - 10^{+30}\right) \cdot 1
x
double f(double x) {
        double r49895701 = 1e+30;
        double r49895702 = x;
        double r49895703 = r49895702 - r49895701;
        double r49895704 = 1.0;
        double r49895705 = r49895703 * r49895704;
        double r49895706 = r49895701 + r49895705;
        return r49895706;
}

double f(double x) {
        double r49895707 = x;
        return r49895707;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 32.1

    \[10^{+30} + \left(x - 10^{+30}\right) \cdot 1\]
  2. Simplified0

    \[\leadsto \color{blue}{x}\]
  3. Final simplification0

    \[\leadsto x\]

Reproduce

herbie shell --seed 1 
(FPCore (x)
  :name "1e30 + (x - 1e30)*1"
  (+ 1e+30 (* (- x 1e+30) 1)))