e^{a \cdot x} - 1\log \left(e^{e^{a \cdot x} - 1}\right)(FPCore (a x) :precision binary64 (- (exp (* a x)) 1.0))
(FPCore (a x) :precision binary64 (log (exp (- (exp (* a x)) 1.0))))
double code(double a, double x) {
return exp(a * x) - 1.0;
}
double code(double a, double x) {
return log(exp(exp(a * x) - 1.0));
}




Bits error versus a




Bits error versus x
Results
| Original | 30.0 |
|---|---|
| Target | 0.2 |
| Herbie | 30.1 |
Initial program 30.0
rmApplied add-log-exp_binary6430.0
Applied add-log-exp_binary6430.1
Applied diff-log_binary6430.1
Simplified30.1
Final simplification30.1
herbie shell --seed 2020270
(FPCore (a x)
:name "expax (section 3.5)"
:precision binary64
:herbie-expected 14
:herbie-target
(if (< (fabs (* a x)) 0.1) (* (* a x) (+ 1.0 (+ (/ (* a x) 2.0) (/ (pow (* a x) 2.0) 6.0)))) (- (exp (* a x)) 1.0))
(- (exp (* a x)) 1.0))