- Split input into 4 regimes
if b < -1.2275576669103459e+128
Initial program 51.2
\[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\]
Taylor expanded around -inf 3.2
\[\leadsto \color{blue}{\frac{c}{b} - \frac{b}{a}}\]
if -1.2275576669103459e+128 < b < -5.616574398330274e-296
Initial program 9.2
\[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\]
Taylor expanded around inf 9.2
\[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{{b}^{2} - 4 \cdot \left(a \cdot c\right)}}}{2 \cdot a}\]
Simplified9.2
\[\leadsto \frac{\left(-b\right) + \sqrt{\color{blue}{b \cdot b + \left(c \cdot -4\right) \cdot a}}}{2 \cdot a}\]
if -5.616574398330274e-296 < b < 5.1457556548524475e+64
Initial program 30.5
\[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\]
- Using strategy
rm Applied flip-+30.6
\[\leadsto \frac{\color{blue}{\frac{\left(-b\right) \cdot \left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c} \cdot \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}}}{2 \cdot a}\]
Applied associate-/l/35.4
\[\leadsto \color{blue}{\frac{\left(-b\right) \cdot \left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c} \cdot \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{\left(2 \cdot a\right) \cdot \left(\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}\right)}}\]
Simplified22.4
\[\leadsto \frac{\color{blue}{c \cdot \left(4 \cdot a\right)}}{\left(2 \cdot a\right) \cdot \left(\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}\right)}\]
- Using strategy
rm Applied *-commutative22.4
\[\leadsto \frac{c \cdot \left(4 \cdot a\right)}{\color{blue}{\left(\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}\right) \cdot \left(2 \cdot a\right)}}\]
Applied times-frac10.2
\[\leadsto \color{blue}{\frac{c}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}} \cdot \frac{4 \cdot a}{2 \cdot a}}\]
Simplified10.1
\[\leadsto \frac{c}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}} \cdot \color{blue}{2}\]
if 5.1457556548524475e+64 < b
Initial program 57.4
\[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\]
Taylor expanded around inf 3.3
\[\leadsto \color{blue}{-1 \cdot \frac{c}{b}}\]
Simplified3.3
\[\leadsto \color{blue}{-\frac{c}{b}}\]
- Recombined 4 regimes into one program.
Final simplification7.0
\[\leadsto \begin{array}{l}
\mathbf{if}\;b \le -1.2275576669103459 \cdot 10^{+128}:\\
\;\;\;\;\frac{c}{b} - \frac{b}{a}\\
\mathbf{elif}\;b \le -5.616574398330274 \cdot 10^{-296}:\\
\;\;\;\;\frac{\left(-b\right) + \sqrt{b \cdot b + a \cdot \left(-4 \cdot c\right)}}{a \cdot 2}\\
\mathbf{elif}\;b \le 5.1457556548524475 \cdot 10^{+64}:\\
\;\;\;\;\frac{c}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}} \cdot 2\\
\mathbf{else}:\\
\;\;\;\;-\frac{c}{b}\\
\end{array}\]