\frac{x}{y \cdot 3}\frac{\frac{x}{3}}{y}double f(double x, double y) {
double r395667 = x;
double r395668 = y;
double r395669 = 3.0;
double r395670 = r395668 * r395669;
double r395671 = r395667 / r395670;
return r395671;
}
double f(double x, double y) {
double r395672 = x;
double r395673 = 3.0;
double r395674 = r395672 / r395673;
double r395675 = y;
double r395676 = r395674 / r395675;
return r395676;
}




Bits error versus x




Bits error versus y
Results
| Original | 0.3 |
|---|---|
| Target | 0.3 |
| Herbie | 0.2 |
Initial program 0.3
rmApplied div-inv0.4
rmApplied pow10.4
Applied pow10.4
Applied pow-prod-down0.4
Simplified0.2
Final simplification0.2
herbie shell --seed 2019322 +o rules:numerics
(FPCore (x y)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, C"
:precision binary64
:herbie-target
(/ (/ x y) 3)
(/ x (* y 3)))