- Split input into 3 regimes
if b < -1.5869302652106472e+66
Initial program 37.1
\[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\]
Taylor expanded around -inf 5.6
\[\leadsto \color{blue}{-1 \cdot \frac{b}{a}}\]
Simplified5.6
\[\leadsto \color{blue}{\frac{-b}{a}}\]
if -1.5869302652106472e+66 < b < 3.983337014248878e-109
Initial program 12.7
\[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\]
- Using strategy
rm Applied div-inv12.8
\[\leadsto \color{blue}{\left(\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}\right) \cdot \frac{1}{2 \cdot a}}\]
if 3.983337014248878e-109 < b
Initial program 51.6
\[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\]
- Using strategy
rm Applied flip-+51.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/52.7
\[\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)}}\]
Simplified25.2
\[\leadsto \frac{\color{blue}{4 \cdot \left(c \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 associate-/r*23.2
\[\leadsto \color{blue}{\frac{\frac{4 \cdot \left(c \cdot a\right)}{2 \cdot a}}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}}\]
- Using strategy
rm Applied times-frac23.2
\[\leadsto \frac{\color{blue}{\frac{4}{2} \cdot \frac{c \cdot a}{a}}}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}\]
Simplified19.1
\[\leadsto \frac{\frac{4}{2} \cdot \color{blue}{c}}{\left(-b\right) - \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}\]
Taylor expanded around inf 12.6
\[\leadsto \frac{\frac{4}{2} \cdot c}{\left(-b\right) - \color{blue}{\left(b - 2 \cdot \frac{a \cdot c}{b}\right)}}\]
- Recombined 3 regimes into one program.
Final simplification11.5
\[\leadsto \begin{array}{l}
\mathbf{if}\;b \le -1.5869302652106472 \cdot 10^{+66}:\\
\;\;\;\;-\frac{b}{a}\\
\mathbf{elif}\;b \le 3.983337014248878 \cdot 10^{-109}:\\
\;\;\;\;\left(\sqrt{b \cdot b - \left(a \cdot 4\right) \cdot c} + \left(-b\right)\right) \cdot \frac{1}{a \cdot 2}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{4}{2} \cdot c}{\left(-b\right) - \left(b - 2 \cdot \frac{c \cdot a}{b}\right)}\\
\end{array}\]