\frac{1}{x + 1} - \frac{1}{x - 1}\frac{\frac{1}{x + 1}}{x - 1} \cdot \left(-2\right)double f(double x) {
double r140949 = 1.0;
double r140950 = x;
double r140951 = r140950 + r140949;
double r140952 = r140949 / r140951;
double r140953 = r140950 - r140949;
double r140954 = r140949 / r140953;
double r140955 = r140952 - r140954;
return r140955;
}
double f(double x) {
double r140956 = 1.0;
double r140957 = x;
double r140958 = r140957 + r140956;
double r140959 = r140956 / r140958;
double r140960 = r140957 - r140956;
double r140961 = r140959 / r140960;
double r140962 = 2.0;
double r140963 = -r140962;
double r140964 = r140961 * r140963;
return r140964;
}



Bits error versus x
Results
Initial program 14.8
rmApplied flip--29.1
Applied associate-/r/29.2
Applied flip-+14.8
Applied associate-/r/14.8
Applied distribute-lft-out--14.2
Taylor expanded around 0 0.4
rmApplied difference-of-squares0.4
Applied associate-/r*0.1
Final simplification0.1
herbie shell --seed 2020042
(FPCore (x)
:name "Asymptote A"
:precision binary64
(- (/ 1 (+ x 1)) (/ 1 (- x 1))))