e^{\log a + \log b}b \cdot a
double f(double a, double b) {
double r121298 = a;
double r121299 = log(r121298);
double r121300 = b;
double r121301 = log(r121300);
double r121302 = r121299 + r121301;
double r121303 = exp(r121302);
return r121303;
}
double f(double a, double b) {
double r121304 = b;
double r121305 = a;
double r121306 = r121304 * r121305;
return r121306;
}




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 2019325
(FPCore (a b)
:name "Exp of sum of logs"
:precision binary64
:herbie-target
(* a b)
(exp (+ (log a) (log b))))