
Results
Herbie found 10 alternatives:
| Alternative | Accuracy | Speedup |
|---|
| Original | 98.8% |
|---|---|
| Target | 100.0% |
| Herbie | 98.6% |
Initial program 99.2%
add-exp-log99.2%
div-exp99.2%
Applied egg-rr99.2%
Taylor expanded in a around 0 99.3%
+-commutative99.3%
log1p-def99.3%
Simplified99.3%
Final simplification99.3%
Initial program 99.2%
add-exp-log99.2%
div-exp99.2%
Applied egg-rr99.2%
Final simplification99.2%
if (exp.f64 a) < 4.9999999999999996e-41Initial program 98.6%
add-exp-log98.6%
div-exp98.7%
Applied egg-rr98.7%
Taylor expanded in a around inf 98.7%
if 4.9999999999999996e-41 < (exp.f64 a) Initial program 99.4%
add-exp-log99.4%
div-exp99.4%
Applied egg-rr99.4%
Taylor expanded in a around 0 99.4%
neg-mul-199.4%
log1p-def99.4%
Simplified99.4%
Final simplification99.2%
Initial program 99.2%
Final simplification99.2%
if (exp.f64 a) < 4.9999999999999996e-41Initial program 98.6%
add-exp-log98.6%
div-exp98.7%
Applied egg-rr98.7%
Taylor expanded in a around inf 98.7%
if 4.9999999999999996e-41 < (exp.f64 a) Initial program 99.4%
Taylor expanded in a around 0 99.4%
Final simplification99.2%
if b < -12Initial program 97.9%
add-exp-log97.9%
div-exp97.9%
Applied egg-rr97.9%
Taylor expanded in a around 0 99.6%
neg-mul-199.6%
log1p-def99.6%
Simplified99.6%
exp-neg99.6%
log1p-udef99.6%
add-exp-log99.6%
add-sqr-sqrt99.6%
associate-/r*99.6%
Applied egg-rr98.9%
*-inverses98.9%
Simplified98.9%
if -12 < b Initial program 99.5%
Taylor expanded in b around 0 73.1%
Taylor expanded in a around 0 72.7%
Final simplification77.7%
if a < -1.34999999999999992e-45Initial program 98.8%
add-exp-log98.8%
div-exp98.8%
Applied egg-rr98.8%
Taylor expanded in a around inf 90.6%
if -1.34999999999999992e-45 < a < 4.40000000000000024e-44Initial program 100.0%
Taylor expanded in b around 0 53.0%
Taylor expanded in a around 0 53.0%
*-commutative53.0%
Simplified53.0%
if 4.40000000000000024e-44 < a Initial program 95.3%
add-exp-log95.3%
div-exp95.4%
Applied egg-rr95.4%
Taylor expanded in a around 0 95.3%
neg-mul-195.3%
log1p-def95.3%
Simplified95.3%
exp-neg95.3%
log1p-udef95.3%
add-exp-log95.3%
add-sqr-sqrt94.7%
associate-/r*94.9%
Applied egg-rr56.7%
*-inverses57.2%
Simplified57.2%
Final simplification65.7%
if b < -1.6000000000000001Initial program 97.9%
add-exp-log97.9%
div-exp97.9%
Applied egg-rr97.9%
Taylor expanded in a around 0 99.6%
neg-mul-199.6%
log1p-def99.6%
Simplified99.6%
exp-neg99.6%
log1p-udef99.6%
add-exp-log99.6%
add-sqr-sqrt99.6%
associate-/r*99.6%
Applied egg-rr98.9%
*-inverses98.9%
Simplified98.9%
if -1.6000000000000001 < b Initial program 99.5%
Taylor expanded in a around 0 82.8%
Taylor expanded in b around 0 40.4%
*-commutative40.4%
Simplified40.4%
Final simplification51.4%
if b < -1.1000000000000001Initial program 97.9%
add-exp-log97.9%
div-exp97.9%
Applied egg-rr97.9%
Taylor expanded in a around 0 99.6%
neg-mul-199.6%
log1p-def99.6%
Simplified99.6%
exp-neg99.6%
log1p-udef99.6%
add-exp-log99.6%
add-sqr-sqrt99.6%
associate-/r*99.6%
Applied egg-rr98.9%
*-inverses98.9%
Simplified98.9%
if -1.1000000000000001 < b Initial program 99.5%
Taylor expanded in a around 0 82.8%
Taylor expanded in b around 0 40.2%
Final simplification51.2%
Initial program 99.2%
Taylor expanded in a around 0 86.0%
Taylor expanded in b around 0 36.1%
Final simplification36.1%
herbie shell --seed 2023166
(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))))