\frac{1}{x + 1} - \frac{1}{x}\frac{\frac{-1}{x}}{x + 1}double f(double x) {
double r1768321 = 1.0;
double r1768322 = x;
double r1768323 = r1768322 + r1768321;
double r1768324 = r1768321 / r1768323;
double r1768325 = r1768321 / r1768322;
double r1768326 = r1768324 - r1768325;
return r1768326;
}
double f(double x) {
double r1768327 = -1.0;
double r1768328 = x;
double r1768329 = r1768327 / r1768328;
double r1768330 = 1.0;
double r1768331 = r1768328 + r1768330;
double r1768332 = r1768329 / r1768331;
return r1768332;
}



Bits error versus x
Results
Initial program 14.4
rmApplied frac-sub13.7
Simplified0.4
Simplified0.4
rmApplied *-un-lft-identity0.4
Applied distribute-rgt-out0.4
Applied associate-/r*0.1
Final simplification0.1
herbie shell --seed 2019112
(FPCore (x)
:name "2frac (problem 3.3.1)"
(- (/ 1 (+ x 1)) (/ 1 x)))