\left(x + y\right) \cdot \left(x + y\right)
\mathsf{fma}\left(x, x, \mathsf{fma}\left(2 \cdot x, y, {y}^{2}\right)\right)double f(double x, double y) {
double r788036 = x;
double r788037 = y;
double r788038 = r788036 + r788037;
double r788039 = r788038 * r788038;
return r788039;
}
double f(double x, double y) {
double r788040 = x;
double r788041 = 2.0;
double r788042 = r788041 * r788040;
double r788043 = y;
double r788044 = pow(r788043, r788041);
double r788045 = fma(r788042, r788043, r788044);
double r788046 = fma(r788040, r788040, r788045);
return r788046;
}




Bits error versus x




Bits error versus y
| Original | 0.0 |
|---|---|
| Target | 0.0 |
| Herbie | 0.0 |
Initial program 0.0
rmApplied flip-+0.0
Applied associate-*r/18.8
Simplified18.8
Taylor expanded around 0 0.0
Simplified0.0
Final simplification0.0
herbie shell --seed 2019362 +o rules:numerics
(FPCore (x y)
:name "Examples.Basics.BasicTests:f3 from sbv-4.4"
:precision binary64
:herbie-target
(+ (* x x) (+ (* y y) (* 2 (* y x))))
(* (+ x y) (+ x y)))