\frac{e^{a}}{e^{a} + e^{b}}\log \left({\left(e^{e^{a}}\right)}^{\left(\frac{1}{e^{a} + e^{b}}\right)}\right)(FPCore (a b) :precision binary64 (/ (exp a) (+ (exp a) (exp b))))
(FPCore (a b) :precision binary64 (log (pow (exp (exp a)) (/ 1.0 (+ (exp a) (exp b))))))
double code(double a, double b) {
return exp(a) / (exp(a) + exp(b));
}
double code(double a, double b) {
return log(pow(exp(exp(a)), (1.0 / (exp(a) + exp(b)))));
}




Bits error versus a




Bits error versus b
Results
| Original | 0.7 |
|---|---|
| Target | 0.0 |
| Herbie | 0.7 |
Initial program 0.7
rmApplied add-log-exp_binary64_31860.8
rmApplied div-inv_binary64_31440.8
Applied exp-prod_binary64_31990.7
Final simplification0.7
herbie shell --seed 2020352
(FPCore (a b)
:name "Quotient of sum of exps"
:precision binary64
:herbie-target
(/ 1.0 (+ 1.0 (exp (- b a))))
(/ (exp a) (+ (exp a) (exp b))))