\left(\left(\left(e + d\right) + c\right) + b\right) + a
a + \log \left(\left(e^{e} \cdot e^{c}\right) \cdot e^{d + b}\right)double f(double a, double b, double c, double d, double e) {
double r1949534 = e;
double r1949535 = d;
double r1949536 = r1949534 + r1949535;
double r1949537 = c;
double r1949538 = r1949536 + r1949537;
double r1949539 = b;
double r1949540 = r1949538 + r1949539;
double r1949541 = a;
double r1949542 = r1949540 + r1949541;
return r1949542;
}
double f(double a, double b, double c, double d, double e) {
double r1949543 = a;
double r1949544 = e;
double r1949545 = exp(r1949544);
double r1949546 = c;
double r1949547 = exp(r1949546);
double r1949548 = r1949545 * r1949547;
double r1949549 = d;
double r1949550 = b;
double r1949551 = r1949549 + r1949550;
double r1949552 = exp(r1949551);
double r1949553 = r1949548 * r1949552;
double r1949554 = log(r1949553);
double r1949555 = r1949543 + r1949554;
return r1949555;
}




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.3
Simplified0.3
rmApplied add-log-exp0.3
Applied add-log-exp0.3
Applied add-log-exp0.3
Applied sum-log0.3
Applied sum-log0.3
Applied rem-exp-log0.3
Final simplification0.3
herbie shell --seed 2019156
(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))