Average Error: 0.0 → 0.0
Time: 850.0ms
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 r77278 = x;
        double r77279 = 1.0;
        double r77280 = 0.5;
        double r77281 = r77278 * r77280;
        double r77282 = r77279 - r77281;
        double r77283 = r77278 * r77282;
        return r77283;
}

double f(double x) {
        double r77284 = x;
        double r77285 = 1.0;
        double r77286 = 0.5;
        double r77287 = r77284 * r77286;
        double r77288 = r77285 - r77287;
        double r77289 = r77284 * r77288;
        return r77289;
}

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 2020020 +o rules:numerics
(FPCore (x)
  :name "Numeric.SpecFunctions:log1p from math-functions-0.1.5.2, B"
  :precision binary64
  (* x (- 1 (* x 0.5))))