-\left(\left(a \cdot a\right) \cdot b\right) \cdot b
-\left(a \cdot b\right) \cdot \left(a \cdot b\right)
(FPCore (a b angle) :precision binary64 (- (* (* (* a a) b) b)))
(FPCore (a b angle) :precision binary64 (- (* (* a b) (* a b))))
double code(double a, double b, double angle) {
return -(((a * a) * b) * b);
}
double code(double a, double b, double angle) {
return -((a * b) * (a * b));
}






Bits error versus a






Bits error versus b






Bits error versus angle
Results
| Alternative 1 | |
|---|---|
| Error | 15.9 |
| Cost | 512 |
| Alternative 2 | |
|---|---|
| Error | 37.4 |
| Cost | 64 |
| Alternative 3 | |
|---|---|
| Error | 62.6 |
| Cost | 64 |


Initial program 15.9
rmApplied add-sqr-sqrt_binary6440.2
Applied associate-*r*_binary6440.2
Simplified37.6
rmApplied pow1_binary6437.6
Applied pow1_binary6437.6
Applied pow1_binary6437.6
Applied pow-prod-down_binary6437.6
Applied pow-prod-down_binary6437.6
Simplified0.3
Simplified0.3
Final simplification0.3
herbie shell --seed 2021040
(FPCore (a b angle)
:name "ab-angle->ABCF D"
:precision binary64
(- (* (* (* a a) b) b)))