- Split input into 4 regimes
if y < -1.3375011635662419e+154 or -2.8086776667333143e-164 < y < -2.0859057630987112e-190
Initial program 59.6
\[\frac{\left(x - y\right) \cdot \left(x + y\right)}{x \cdot x + y \cdot y}\]
Taylor expanded around 0 4.5
\[\leadsto \color{blue}{-1}\]
if -1.3375011635662419e+154 < y < -2.8086776667333143e-164
Initial program 0.2
\[\frac{\left(x - y\right) \cdot \left(x + y\right)}{x \cdot x + y \cdot y}\]
- Using strategy
rm Applied add-sqr-sqrt0.2
\[\leadsto \frac{\left(x - y\right) \cdot \left(x + y\right)}{\color{blue}{\sqrt{x \cdot x + y \cdot y} \cdot \sqrt{x \cdot x + y \cdot y}}}\]
Applied times-frac0.4
\[\leadsto \color{blue}{\frac{x - y}{\sqrt{x \cdot x + y \cdot y}} \cdot \frac{x + y}{\sqrt{x \cdot x + y \cdot y}}}\]
- Using strategy
rm Applied add-cbrt-cube17.3
\[\leadsto \frac{x - y}{\sqrt{x \cdot x + y \cdot y}} \cdot \frac{x + y}{\color{blue}{\sqrt[3]{\left(\sqrt{x \cdot x + y \cdot y} \cdot \sqrt{x \cdot x + y \cdot y}\right) \cdot \sqrt{x \cdot x + y \cdot y}}}}\]
Applied add-cbrt-cube17.0
\[\leadsto \frac{x - y}{\sqrt{x \cdot x + y \cdot y}} \cdot \frac{\color{blue}{\sqrt[3]{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(x + y\right)}}}{\sqrt[3]{\left(\sqrt{x \cdot x + y \cdot y} \cdot \sqrt{x \cdot x + y \cdot y}\right) \cdot \sqrt{x \cdot x + y \cdot y}}}\]
Applied cbrt-undiv17.0
\[\leadsto \frac{x - y}{\sqrt{x \cdot x + y \cdot y}} \cdot \color{blue}{\sqrt[3]{\frac{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(x + y\right)}{\left(\sqrt{x \cdot x + y \cdot y} \cdot \sqrt{x \cdot x + y \cdot y}\right) \cdot \sqrt{x \cdot x + y \cdot y}}}}\]
Applied add-cbrt-cube17.0
\[\leadsto \color{blue}{\sqrt[3]{\left(\frac{x - y}{\sqrt{x \cdot x + y \cdot y}} \cdot \frac{x - y}{\sqrt{x \cdot x + y \cdot y}}\right) \cdot \frac{x - y}{\sqrt{x \cdot x + y \cdot y}}}} \cdot \sqrt[3]{\frac{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(x + y\right)}{\left(\sqrt{x \cdot x + y \cdot y} \cdot \sqrt{x \cdot x + y \cdot y}\right) \cdot \sqrt{x \cdot x + y \cdot y}}}\]
Applied cbrt-unprod17.0
\[\leadsto \color{blue}{\sqrt[3]{\left(\left(\frac{x - y}{\sqrt{x \cdot x + y \cdot y}} \cdot \frac{x - y}{\sqrt{x \cdot x + y \cdot y}}\right) \cdot \frac{x - y}{\sqrt{x \cdot x + y \cdot y}}\right) \cdot \frac{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(x + y\right)}{\left(\sqrt{x \cdot x + y \cdot y} \cdot \sqrt{x \cdot x + y \cdot y}\right) \cdot \sqrt{x \cdot x + y \cdot y}}}}\]
Simplified0.4
\[\leadsto \sqrt[3]{\color{blue}{\left(\frac{x - y}{\sqrt{x \cdot x + y \cdot y}} \cdot \left(\frac{\left(x - y\right) \cdot \left(x - y\right)}{x \cdot x + y \cdot y} \cdot \frac{\left(y + x\right) \cdot \left(y + x\right)}{x \cdot x + y \cdot y}\right)\right) \cdot \frac{y + x}{\sqrt{x \cdot x + y \cdot y}}}}\]
if -2.0859057630987112e-190 < y < 1.5094977530774565e-195
Initial program 29.3
\[\frac{\left(x - y\right) \cdot \left(x + y\right)}{x \cdot x + y \cdot y}\]
- Using strategy
rm Applied associate-/l*29.6
\[\leadsto \color{blue}{\frac{x - y}{\frac{x \cdot x + y \cdot y}{x + y}}}\]
Taylor expanded around inf 13.5
\[\leadsto \color{blue}{1}\]
if 1.5094977530774565e-195 < y
Initial program 6.0
\[\frac{\left(x - y\right) \cdot \left(x + y\right)}{x \cdot x + y \cdot y}\]
- Using strategy
rm Applied add-sqr-sqrt6.0
\[\leadsto \frac{\left(x - y\right) \cdot \left(x + y\right)}{\color{blue}{\sqrt{x \cdot x + y \cdot y} \cdot \sqrt{x \cdot x + y \cdot y}}}\]
Applied times-frac6.4
\[\leadsto \color{blue}{\frac{x - y}{\sqrt{x \cdot x + y \cdot y}} \cdot \frac{x + y}{\sqrt{x \cdot x + y \cdot y}}}\]
- Recombined 4 regimes into one program.
Final simplification5.8
\[\leadsto \begin{array}{l}
\mathbf{if}\;y \le -1.3375011635662419 \cdot 10^{+154}:\\
\;\;\;\;-1\\
\mathbf{elif}\;y \le -2.8086776667333143 \cdot 10^{-164}:\\
\;\;\;\;\sqrt[3]{\left(\left(\frac{\left(x - y\right) \cdot \left(x - y\right)}{x \cdot x + y \cdot y} \cdot \frac{\left(y + x\right) \cdot \left(y + x\right)}{x \cdot x + y \cdot y}\right) \cdot \frac{x - y}{\sqrt{x \cdot x + y \cdot y}}\right) \cdot \frac{y + x}{\sqrt{x \cdot x + y \cdot y}}}\\
\mathbf{elif}\;y \le -2.0859057630987112 \cdot 10^{-190}:\\
\;\;\;\;-1\\
\mathbf{elif}\;y \le 1.5094977530774565 \cdot 10^{-195}:\\
\;\;\;\;1\\
\mathbf{else}:\\
\;\;\;\;\frac{x - y}{\sqrt{x \cdot x + y \cdot y}} \cdot \frac{y + x}{\sqrt{x \cdot x + y \cdot y}}\\
\end{array}\]