\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\frac{x \cdot e^{\left(y \cdot \log z + \log a \cdot \left(t - 1\right)\right) - b}}{y}(FPCore (x y z t a b) :precision binary64 (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))
(FPCore (x y z t a b) :precision binary64 (/ (* x (exp (- (+ (* y (log z)) (* (log a) (- t 1.0))) b))) y))
double code(double x, double y, double z, double t, double a, double b) {
return (x * exp(((y * log(z)) + ((t - 1.0) * log(a))) - b)) / y;
}
double code(double x, double y, double z, double t, double a, double b) {
return (x * exp(((y * log(z)) + (log(a) * (t - 1.0))) - b)) / y;
}













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 | 2.0 |
|---|---|
| Target | 11.4 |
| Herbie | 2.0 |
| Alternative 1 | |
|---|---|
| Error | 2.7 |
| Cost | 20802 |
| Alternative 2 | |
|---|---|
| Error | 5.8 |
| Cost | 8194 |
| Alternative 3 | |
|---|---|
| Error | 8.9 |
| Cost | 8452 |
| Alternative 4 | |
|---|---|
| Error | 8.8 |
| Cost | 8196 |
| Alternative 5 | |
|---|---|
| Error | 9.8 |
| Cost | 8838 |
| Alternative 6 | |
|---|---|
| Error | 9.0 |
| Cost | 8453 |
| Alternative 7 | |
|---|---|
| Error | 9.9 |
| Cost | 7629 |
| Alternative 8 | |
|---|---|
| Error | 10.0 |
| Cost | 64 |
| Alternative 9 | |
|---|---|
| Error | 62.0 |
| Cost | 64 |

Initial program 2.0
Simplified2.0
Final simplification2.0
herbie shell --seed 2021044
(FPCore (x y z t a b)
:name "Numeric.SpecFunctions:incompleteBetaWorker from math-functions-0.1.5.2, A"
:precision binary64
:herbie-target
(if (< t -0.8845848504127471) (/ (* x (/ (pow a (- t 1.0)) y)) (- (+ b 1.0) (* y (log z)))) (if (< t 852031.2288374073) (/ (* (/ x y) (pow a (- t 1.0))) (exp (- b (* (log z) y)))) (/ (* x (/ (pow a (- t 1.0)) y)) (- (+ b 1.0) (* y (log z))))))
(/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))