\frac{-\left(f + n\right)}{f - n}\log \left(e^{\frac{-\left(f + n\right)}{f - n}}\right)double f(double f, double n) {
double r15930 = f;
double r15931 = n;
double r15932 = r15930 + r15931;
double r15933 = -r15932;
double r15934 = r15930 - r15931;
double r15935 = r15933 / r15934;
return r15935;
}
double f(double f, double n) {
double r15936 = f;
double r15937 = n;
double r15938 = r15936 + r15937;
double r15939 = -r15938;
double r15940 = r15936 - r15937;
double r15941 = r15939 / r15940;
double r15942 = exp(r15941);
double r15943 = log(r15942);
return r15943;
}



Bits error versus f



Bits error versus n
Results
Initial program 0.0
rmApplied add-log-exp0.0
Final simplification0.0
herbie shell --seed 2020035 +o rules:numerics
(FPCore (f n)
:name "subtraction fraction"
:precision binary64
(/ (- (+ f n)) (- f n)))