Average Error: 0.1 → 0.1
Time: 11.1s
Precision: 64
\[\left(x \cdot y\right) \cdot \left(1 - y\right)\]
\[\left(x \cdot y\right) \cdot \left(1 - y\right)\]
\left(x \cdot y\right) \cdot \left(1 - y\right)
\left(x \cdot y\right) \cdot \left(1 - y\right)
double f(double x, double y) {
        double r29956 = x;
        double r29957 = y;
        double r29958 = r29956 * r29957;
        double r29959 = 1.0;
        double r29960 = r29959 - r29957;
        double r29961 = r29958 * r29960;
        return r29961;
}

double f(double x, double y) {
        double r29962 = x;
        double r29963 = y;
        double r29964 = r29962 * r29963;
        double r29965 = 1.0;
        double r29966 = r29965 - r29963;
        double r29967 = r29964 * r29966;
        return r29967;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.1

    \[\left(x \cdot y\right) \cdot \left(1 - y\right)\]
  2. Simplified0.1

    \[\leadsto \color{blue}{\left(1 - y\right) \cdot \left(x \cdot y\right)}\]
  3. Final simplification0.1

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

Reproduce

herbie shell --seed 2019179 +o rules:numerics
(FPCore (x y)
  :name "Statistics.Distribution.Binomial:$cvariance from math-functions-0.1.5.2"
  (* (* x y) (- 1.0 y)))