e^{\log a + \log b}a \cdot b
double f(double a, double b) {
double r150041 = a;
double r150042 = log(r150041);
double r150043 = b;
double r150044 = log(r150043);
double r150045 = r150042 + r150044;
double r150046 = exp(r150045);
return r150046;
}
double f(double a, double b) {
double r150047 = a;
double r150048 = b;
double r150049 = r150047 * r150048;
return r150049;
}




Bits error versus a




Bits error versus b
Results
| Original | 5.7 |
|---|---|
| Target | 0 |
| Herbie | 0 |
Initial program 5.7
rmApplied exp-sum5.5
Simplified4.7
Simplified0
Final simplification0
herbie shell --seed 2020003
(FPCore (a b)
:name "Exp of sum of logs"
:precision binary64
:herbie-target
(* a b)
(exp (+ (log a) (log b))))