Average Error: 0.0 → 0.0
Time: 6.0s
Precision: 64
\[x \cdot \left(1 - x \cdot 0.5\right)\]
\[x \cdot \left(1 - x \cdot 0.5\right)\]
x \cdot \left(1 - x \cdot 0.5\right)
x \cdot \left(1 - x \cdot 0.5\right)
double f(double x) {
        double r53361 = x;
        double r53362 = 1.0;
        double r53363 = 0.5;
        double r53364 = r53361 * r53363;
        double r53365 = r53362 - r53364;
        double r53366 = r53361 * r53365;
        return r53366;
}

double f(double x) {
        double r53367 = x;
        double r53368 = 1.0;
        double r53369 = 0.5;
        double r53370 = r53367 * r53369;
        double r53371 = r53368 - r53370;
        double r53372 = r53367 * r53371;
        return r53372;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[x \cdot \left(1 - x \cdot 0.5\right)\]
  2. Final simplification0.0

    \[\leadsto x \cdot \left(1 - x \cdot 0.5\right)\]

Reproduce

herbie shell --seed 2020047 +o rules:numerics
(FPCore (x)
  :name "Numeric.SpecFunctions:log1p from math-functions-0.1.5.2, B"
  :precision binary64
  (* x (- 1 (* x 0.5))))