\left(\left(\left(e + d\right) + c\right) + b\right) + a
a + \log \left(e^{e + c} \cdot e^{b + d}\right)double f(double a, double b, double c, double d, double e) {
double r2042690 = e;
double r2042691 = d;
double r2042692 = r2042690 + r2042691;
double r2042693 = c;
double r2042694 = r2042692 + r2042693;
double r2042695 = b;
double r2042696 = r2042694 + r2042695;
double r2042697 = a;
double r2042698 = r2042696 + r2042697;
return r2042698;
}
double f(double a, double b, double c, double d, double e) {
double r2042699 = a;
double r2042700 = e;
double r2042701 = c;
double r2042702 = r2042700 + r2042701;
double r2042703 = exp(r2042702);
double r2042704 = b;
double r2042705 = d;
double r2042706 = r2042704 + r2042705;
double r2042707 = exp(r2042706);
double r2042708 = r2042703 * r2042707;
double r2042709 = log(r2042708);
double r2042710 = r2042699 + r2042709;
return r2042710;
}




Bits error versus a




Bits error versus b




Bits error versus c




Bits error versus d




Bits error versus e
Results
| Original | 0.4 |
|---|---|
| Target | 0.2 |
| Herbie | 0.3 |
Initial program 0.4
rmApplied add-log-exp0.4
Applied add-log-exp0.4
Applied add-log-exp0.4
Applied add-log-exp0.4
Applied sum-log0.4
Applied sum-log0.3
Applied sum-log0.2
Simplified0.3
rmApplied exp-sum0.3
Final simplification0.3
herbie shell --seed 2019154
(FPCore (a b c d e)
:name "Expression 1, p15"
:pre (<= 1 a 2 b 4 c 8 d 16 e 32)
:herbie-target
(+ (+ d (+ c (+ a b))) e)
(+ (+ (+ (+ e d) c) b) a))