\left(\left(\left(e + d\right) + c\right) + b\right) + a
\log \left(\left(e^{b} \cdot e^{e}\right) \cdot \left(e^{a} \cdot \left(e^{c} \cdot e^{d}\right)\right)\right)double f(double a, double b, double c, double d, double e) {
double r3487033 = e;
double r3487034 = d;
double r3487035 = r3487033 + r3487034;
double r3487036 = c;
double r3487037 = r3487035 + r3487036;
double r3487038 = b;
double r3487039 = r3487037 + r3487038;
double r3487040 = a;
double r3487041 = r3487039 + r3487040;
return r3487041;
}
double f(double a, double b, double c, double d, double e) {
double r3487042 = b;
double r3487043 = exp(r3487042);
double r3487044 = e;
double r3487045 = exp(r3487044);
double r3487046 = r3487043 * r3487045;
double r3487047 = a;
double r3487048 = exp(r3487047);
double r3487049 = c;
double r3487050 = exp(r3487049);
double r3487051 = d;
double r3487052 = exp(r3487051);
double r3487053 = r3487050 * r3487052;
double r3487054 = r3487048 * r3487053;
double r3487055 = r3487046 * r3487054;
double r3487056 = log(r3487055);
return r3487056;
}




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.0 |
Initial program 0.4
rmApplied associate-+l+0.3
rmApplied add-log-exp0.3
Applied add-log-exp0.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.2
Applied add-log-exp0.2
Applied add-log-exp0.2
Applied sum-log0.2
Applied sum-log0.0
Applied rem-exp-log0.0
Final simplification0.0
herbie shell --seed 2019151
(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))