Average Error: 0.0 → 0.0
Time: 5.2s
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 r50949 = x;
        double r50950 = 1.0;
        double r50951 = 0.5;
        double r50952 = r50949 * r50951;
        double r50953 = r50950 - r50952;
        double r50954 = r50949 * r50953;
        return r50954;
}

double f(double x) {
        double r50955 = x;
        double r50956 = 1.0;
        double r50957 = 0.5;
        double r50958 = r50955 * r50957;
        double r50959 = r50956 - r50958;
        double r50960 = r50955 * r50959;
        return r50960;
}

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