\left(\left(\left(e + d\right) + c\right) + b\right) + a
\log \left(\left(e^{e} \cdot e^{d}\right) \cdot \left(e^{a} \cdot \left(e^{c} \cdot e^{b}\right)\right)\right)double f(double a, double b, double c, double d, double e) {
double r4150652 = e;
double r4150653 = d;
double r4150654 = r4150652 + r4150653;
double r4150655 = c;
double r4150656 = r4150654 + r4150655;
double r4150657 = b;
double r4150658 = r4150656 + r4150657;
double r4150659 = a;
double r4150660 = r4150658 + r4150659;
return r4150660;
}
double f(double a, double b, double c, double d, double e) {
double r4150661 = e;
double r4150662 = exp(r4150661);
double r4150663 = d;
double r4150664 = exp(r4150663);
double r4150665 = r4150662 * r4150664;
double r4150666 = a;
double r4150667 = exp(r4150666);
double r4150668 = c;
double r4150669 = exp(r4150668);
double r4150670 = b;
double r4150671 = exp(r4150670);
double r4150672 = r4150669 * r4150671;
double r4150673 = r4150667 * r4150672;
double r4150674 = r4150665 * r4150673;
double r4150675 = log(r4150674);
return r4150675;
}




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 add-log-exp0.4
Applied sum-log0.4
Applied sum-log0.3
Applied sum-log0.2
Applied sum-log0.0
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 add-log-exp0.3
Applied add-log-exp0.3
Applied sum-log0.3
Applied sum-log0.0
Applied rem-exp-log0.0
Final simplification0.0
herbie shell --seed 2019163 +o rules:numerics
(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))