double code(double x, double y, double z, double t, double a, double b) {
return ((double) (((double) (x + ((double) (((double) (y * z)) / t)))) / ((double) (((double) (a + 1.0)) + ((double) (((double) (y * b)) / t))))));
}
double code(double x, double y, double z, double t, double a, double b) {
return ((double) (((double) (x + ((double) (((double) (y * z)) / t)))) / ((double) (a + ((double) (1.0 + ((double) (((double) (((double) cbrt(b)) * ((double) cbrt(b)))) * ((double) (y * ((double) (((double) cbrt(b)) / t))))))))))));
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t




Bits error versus a




Bits error versus b
Results
| Original | 17.0 |
|---|---|
| Target | 13.6 |
| Herbie | 16.5 |
Initial program 17.0
rmApplied div-inv17.1
Simplified17.6
rmApplied *-un-lft-identity17.6
Applied add-cube-cbrt17.8
Applied times-frac17.8
Applied associate-*l*16.6
Simplified16.6
rmApplied un-div-inv16.5
Final simplification16.5
herbie shell --seed 2020192
(FPCore (x y z t a b)
:name "Diagrams.Solve.Tridiagonal:solveCyclicTriDiagonal from diagrams-solve-0.1, B"
:precision binary64
:herbie-target
(if (< t -1.3659085366310088e-271) (* 1.0 (* (+ x (* (/ y t) z)) (/ 1.0 (+ (+ a 1.0) (* (/ y t) b))))) (if (< t 3.036967103737246e-130) (/ z b) (* 1.0 (* (+ x (* (/ y t) z)) (/ 1.0 (+ (+ a 1.0) (* (/ y t) b)))))))
(/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t))))