Average Error: 0.0 → 0.0
Time: 15.1s
Precision: 64
\[2 \cdot \left(x \cdot x - x \cdot y\right)\]
\[2 \cdot \left(x \cdot x - x \cdot y\right)\]
2 \cdot \left(x \cdot x - x \cdot y\right)
2 \cdot \left(x \cdot x - x \cdot y\right)
double f(double x, double y) {
        double r414418 = 2.0;
        double r414419 = x;
        double r414420 = r414419 * r414419;
        double r414421 = y;
        double r414422 = r414419 * r414421;
        double r414423 = r414420 - r414422;
        double r414424 = r414418 * r414423;
        return r414424;
}

double f(double x, double y) {
        double r414425 = 2.0;
        double r414426 = x;
        double r414427 = r414426 * r414426;
        double r414428 = y;
        double r414429 = r414426 * r414428;
        double r414430 = r414427 - r414429;
        double r414431 = r414425 * r414430;
        return r414431;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.0
Target0.0
Herbie0.0
\[\left(x \cdot 2\right) \cdot \left(x - y\right)\]

Derivation

  1. Initial program 0.0

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

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

Reproduce

herbie shell --seed 2019304 +o rules:numerics
(FPCore (x y)
  :name "Linear.Matrix:fromQuaternion from linear-1.19.1.3, A"
  :precision binary64

  :herbie-target
  (* (* x 2) (- x y))

  (* 2 (- (* x x) (* x y))))