- Split input into 3 regimes
if b < -1.3388597840143048e+154
Initial program 60.9
\[\frac{\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Initial simplification60.9
\[\leadsto \frac{\sqrt{(\left(a \cdot c\right) \cdot -4 + \left(b \cdot b\right))_*} - b}{2 \cdot a}\]
Taylor expanded around -inf 52.2
\[\leadsto \color{blue}{\frac{-1}{2} \cdot \frac{b}{a}}\]
if -1.3388597840143048e+154 < b < 1.922455145018763e-57
Initial program 13.4
\[\frac{\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Initial simplification13.4
\[\leadsto \frac{\sqrt{(\left(a \cdot c\right) \cdot -4 + \left(b \cdot b\right))_*} - b}{2 \cdot a}\]
Taylor expanded around 0 13.4
\[\leadsto \frac{\sqrt{\color{blue}{{b}^{2} - 4 \cdot \left(a \cdot c\right)}} - b}{2 \cdot a}\]
Simplified13.4
\[\leadsto \frac{\sqrt{\color{blue}{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*}} - b}{2 \cdot a}\]
if 1.922455145018763e-57 < b
Initial program 53.4
\[\frac{\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Initial simplification53.4
\[\leadsto \frac{\sqrt{(\left(a \cdot c\right) \cdot -4 + \left(b \cdot b\right))_*} - b}{2 \cdot a}\]
Taylor expanded around 0 53.4
\[\leadsto \frac{\sqrt{\color{blue}{{b}^{2} - 4 \cdot \left(a \cdot c\right)}} - b}{2 \cdot a}\]
Simplified53.4
\[\leadsto \frac{\sqrt{\color{blue}{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*}} - b}{2 \cdot a}\]
- Using strategy
rm Applied flip--53.5
\[\leadsto \frac{\color{blue}{\frac{\sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*} \cdot \sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*} - b \cdot b}{\sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*} + b}}}{2 \cdot a}\]
Applied associate-/l/54.3
\[\leadsto \color{blue}{\frac{\sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*} \cdot \sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*} - b \cdot b}{\left(2 \cdot a\right) \cdot \left(\sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*} + b\right)}}\]
Simplified25.8
\[\leadsto \frac{\color{blue}{\left(a \cdot -4\right) \cdot c}}{\left(2 \cdot a\right) \cdot \left(\sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*} + b\right)}\]
- Recombined 3 regimes into one program.
Final simplification22.6
\[\leadsto \begin{array}{l}
\mathbf{if}\;b \le -1.3388597840143048 \cdot 10^{+154}:\\
\;\;\;\;\frac{-1}{2} \cdot \frac{b}{a}\\
\mathbf{elif}\;b \le 1.922455145018763 \cdot 10^{-57}:\\
\;\;\;\;\frac{\sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*} - b}{2 \cdot a}\\
\mathbf{else}:\\
\;\;\;\;\frac{\left(a \cdot -4\right) \cdot c}{\left(\sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*} + b\right) \cdot \left(2 \cdot a\right)}\\
\end{array}\]