\left(\left(\left(e + d\right) + c\right) + b\right) + a
\log \left(e^{e} \cdot \left(e^{a} \cdot \left(e^{b} \cdot \left(e^{d} \cdot e^{c}\right)\right)\right)\right)double f(double a, double b, double c, double d, double e) {
double r36476084 = e;
double r36476085 = d;
double r36476086 = r36476084 + r36476085;
double r36476087 = c;
double r36476088 = r36476086 + r36476087;
double r36476089 = b;
double r36476090 = r36476088 + r36476089;
double r36476091 = a;
double r36476092 = r36476090 + r36476091;
return r36476092;
}
double f(double a, double b, double c, double d, double e) {
double r36476093 = e;
double r36476094 = exp(r36476093);
double r36476095 = a;
double r36476096 = exp(r36476095);
double r36476097 = b;
double r36476098 = exp(r36476097);
double r36476099 = d;
double r36476100 = exp(r36476099);
double r36476101 = c;
double r36476102 = exp(r36476101);
double r36476103 = r36476100 * r36476102;
double r36476104 = r36476098 * r36476103;
double r36476105 = r36476096 * r36476104;
double r36476106 = r36476094 * r36476105;
double r36476107 = log(r36476106);
return r36476107;
}




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 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
Taylor expanded around -inf 0.3
rmApplied add-log-exp0.3
Applied add-log-exp0.3
Applied sum-log0.3
Applied add-log-exp0.3
Applied sum-log0.2
Applied add-log-exp0.2
Applied sum-log0.2
Applied add-log-exp0.2
Applied sum-log0.0
Applied rem-exp-log0.0
Final simplification0.0
herbie shell --seed 2019119
(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))