Initial program 9.8
\[\left(\frac{1}{x + 1} - \frac{2}{x}\right) + \frac{1}{x - 1}
\]
Simplified9.8
\[\leadsto \color{blue}{\frac{1}{1 + x} + \left(\frac{1}{x + -1} + \frac{-2}{x}\right)}
\]
Proof
(+.f64 (/.f64 1 (+.f64 1 x)) (+.f64 (/.f64 1 (+.f64 x -1)) (/.f64 -2 x))): 0 points increase in error, 0 points decrease in error
(+.f64 (/.f64 1 (Rewrite<= +-commutative_binary64 (+.f64 x 1))) (+.f64 (/.f64 1 (+.f64 x -1)) (/.f64 -2 x))): 0 points increase in error, 0 points decrease in error
(+.f64 (/.f64 1 (+.f64 x 1)) (+.f64 (/.f64 1 (+.f64 x (Rewrite<= metadata-eval (neg.f64 1)))) (/.f64 -2 x))): 0 points increase in error, 0 points decrease in error
(+.f64 (/.f64 1 (+.f64 x 1)) (+.f64 (/.f64 1 (Rewrite<= sub-neg_binary64 (-.f64 x 1))) (/.f64 -2 x))): 0 points increase in error, 0 points decrease in error
(+.f64 (/.f64 1 (+.f64 x 1)) (+.f64 (/.f64 1 (-.f64 x 1)) (/.f64 (Rewrite<= metadata-eval (neg.f64 2)) x))): 0 points increase in error, 0 points decrease in error
(+.f64 (/.f64 1 (+.f64 x 1)) (+.f64 (/.f64 1 (-.f64 x 1)) (Rewrite<= distribute-neg-frac_binary64 (neg.f64 (/.f64 2 x))))): 0 points increase in error, 0 points decrease in error
(+.f64 (/.f64 1 (+.f64 x 1)) (Rewrite<= +-commutative_binary64 (+.f64 (neg.f64 (/.f64 2 x)) (/.f64 1 (-.f64 x 1))))): 0 points increase in error, 0 points decrease in error
(Rewrite<= associate-+l+_binary64 (+.f64 (+.f64 (/.f64 1 (+.f64 x 1)) (neg.f64 (/.f64 2 x))) (/.f64 1 (-.f64 x 1)))): 1 points increase in error, 0 points decrease in error
(+.f64 (Rewrite<= sub-neg_binary64 (-.f64 (/.f64 1 (+.f64 x 1)) (/.f64 2 x))) (/.f64 1 (-.f64 x 1))): 0 points increase in error, 0 points decrease in error
Applied egg-rr9.8
\[\leadsto \color{blue}{\mathsf{fma}\left(\frac{1}{x}, -2, \frac{1}{1 + x} + \frac{1}{x + -1}\right)}
\]
Applied egg-rr9.8
\[\leadsto \color{blue}{\frac{-2}{x} + \left(\frac{1}{1 + x} + \frac{1}{x + -1}\right)}
\]
Applied egg-rr25.3
\[\leadsto \color{blue}{\frac{\mathsf{fma}\left(x, x, -1\right) + \left(x \cdot -0.5\right) \cdot \left(\left(x + 1\right) + \left(x + -1\right)\right)}{\left(x \cdot -0.5\right) \cdot \mathsf{fma}\left(x, x, -1\right)}}
\]
Taylor expanded in x around 0 0.3
\[\leadsto \frac{\color{blue}{-1}}{\left(x \cdot -0.5\right) \cdot \mathsf{fma}\left(x, x, -1\right)}
\]
Final simplification0.3
\[\leadsto \frac{-1}{\left(x \cdot -0.5\right) \cdot \mathsf{fma}\left(x, x, -1\right)}
\]