e^{\log a + \log b}b \cdot a
double f(double a, double b) {
double r86288 = a;
double r86289 = log(r86288);
double r86290 = b;
double r86291 = log(r86290);
double r86292 = r86289 + r86291;
double r86293 = exp(r86292);
return r86293;
}
double f(double a, double b) {
double r86294 = b;
double r86295 = a;
double r86296 = r86294 * r86295;
return r86296;
}




Bits error versus a




Bits error versus b
Results
| Original | 5.7 |
|---|---|
| Target | 0 |
| Herbie | 0 |
Initial program 5.7
Simplified0
Final simplification0
herbie shell --seed 2020047 +o rules:numerics
(FPCore (a b)
:name "Exp of sum of logs"
:precision binary64
:herbie-target
(* a b)
(exp (+ (log a) (log b))))