\frac{x}{x + 1} - \frac{x + 1}{x - 1}\begin{array}{l}
\mathbf{if}\;x \leq -9786.608325632764 \lor \neg \left(x \leq 9787.463873477589\right):\\
\;\;\;\;\left(\frac{-1}{x \cdot x} - \frac{3}{x}\right) + \frac{-3}{{x}^{3}}\\
\mathbf{else}:\\
\;\;\;\;\sqrt[3]{{\left(\frac{x}{{x}^{3} + 1} \cdot \left(x \cdot x + \left(1 - x\right)\right) - \frac{x + 1}{x + -1}\right)}^{3}}\\
\end{array}(FPCore (x) :precision binary64 (- (/ x (+ x 1.0)) (/ (+ x 1.0) (- x 1.0))))
(FPCore (x)
:precision binary64
(if (or (<= x -9786.608325632764) (not (<= x 9787.463873477589)))
(+ (- (/ -1.0 (* x x)) (/ 3.0 x)) (/ -3.0 (pow x 3.0)))
(cbrt
(pow
(-
(* (/ x (+ (pow x 3.0) 1.0)) (+ (* x x) (- 1.0 x)))
(/ (+ x 1.0) (+ x -1.0)))
3.0))))double code(double x) {
return ((double) ((x / ((double) (x + 1.0))) - (((double) (x + 1.0)) / ((double) (x - 1.0)))));
}
double code(double x) {
double tmp;
if (((x <= -9786.608325632764) || !(x <= 9787.463873477589))) {
tmp = ((double) (((double) ((-1.0 / ((double) (x * x))) - (3.0 / x))) + (-3.0 / ((double) pow(x, 3.0)))));
} else {
tmp = ((double) cbrt(((double) pow(((double) (((double) ((x / ((double) (((double) pow(x, 3.0)) + 1.0))) * ((double) (((double) (x * x)) + ((double) (1.0 - x)))))) - (((double) (x + 1.0)) / ((double) (x + -1.0))))), 3.0))));
}
return tmp;
}



Bits error versus x
Results
if x < -9786.60832563276381 or 9787.463873477589 < x Initial program 59.4
Taylor expanded around inf 0.3
Simplified0.0
if -9786.60832563276381 < x < 9787.463873477589Initial program 0.1
rmApplied flip3-+_binary640.1
Applied associate-/r/_binary640.1
Simplified0.1
rmApplied add-cbrt-cube_binary640.1
Simplified0.1
Final simplification0.1
herbie shell --seed 2020219
(FPCore (x)
:name "Asymptote C"
:precision binary64
(- (/ x (+ x 1.0)) (/ (+ x 1.0) (- x 1.0))))