- Split input into 4 regimes
if b < -1.7555105886550257e+22
Initial program 55.4
\[\frac{\left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Taylor expanded around -inf 4.5
\[\leadsto \color{blue}{-1 \cdot \frac{c}{b}}\]
Simplified4.5
\[\leadsto \color{blue}{\frac{-c}{b}}\]
if -1.7555105886550257e+22 < b < -3.9496534374670056e-159
Initial program 31.9
\[\frac{\left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
- Using strategy
rm Applied flip--32.0
\[\leadsto \frac{\color{blue}{\frac{\left(-b\right) \cdot \left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)} \cdot \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}}}{2 \cdot a}\]
Applied associate-/l/36.5
\[\leadsto \color{blue}{\frac{\left(-b\right) \cdot \left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)} \cdot \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{\left(2 \cdot a\right) \cdot \left(\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}\right)}}\]
Simplified21.3
\[\leadsto \frac{\color{blue}{\left(c \cdot 4\right) \cdot a}}{\left(2 \cdot a\right) \cdot \left(\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}\right)}\]
Taylor expanded around inf 21.3
\[\leadsto \frac{\left(c \cdot 4\right) \cdot a}{\left(2 \cdot a\right) \cdot \left(\left(-b\right) + \sqrt{\color{blue}{{b}^{2} - 4 \cdot \left(a \cdot c\right)}}\right)}\]
Simplified21.3
\[\leadsto \frac{\left(c \cdot 4\right) \cdot a}{\left(2 \cdot a\right) \cdot \left(\left(-b\right) + \sqrt{\color{blue}{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*}}\right)}\]
- Using strategy
rm Applied times-frac20.0
\[\leadsto \color{blue}{\frac{c \cdot 4}{2 \cdot a} \cdot \frac{a}{\left(-b\right) + \sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*}}}\]
Simplified20.0
\[\leadsto \color{blue}{\frac{\frac{c}{\frac{1}{2}}}{a}} \cdot \frac{a}{\left(-b\right) + \sqrt{(\left(a \cdot -4\right) \cdot c + \left(b \cdot b\right))_*}}\]
Simplified20.0
\[\leadsto \frac{\frac{c}{\frac{1}{2}}}{a} \cdot \color{blue}{\frac{a}{\sqrt{(-4 \cdot \left(c \cdot a\right) + \left(b \cdot b\right))_*} - b}}\]
if -3.9496534374670056e-159 < b < 7.393033154911188e+137
Initial program 11.3
\[\frac{\left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
- Using strategy
rm Applied *-un-lft-identity11.3
\[\leadsto \frac{\left(-b\right) - \color{blue}{1 \cdot \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}}{2 \cdot a}\]
Applied *-un-lft-identity11.3
\[\leadsto \frac{\color{blue}{1 \cdot \left(-b\right)} - 1 \cdot \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Applied distribute-lft-out--11.3
\[\leadsto \frac{\color{blue}{1 \cdot \left(\left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}\right)}}{2 \cdot a}\]
Applied associate-/l*11.5
\[\leadsto \color{blue}{\frac{1}{\frac{2 \cdot a}{\left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}}}\]
if 7.393033154911188e+137 < b
Initial program 55.9
\[\frac{\left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Taylor expanded around inf 2.8
\[\leadsto \color{blue}{\frac{c}{b} - \frac{b}{a}}\]
- Recombined 4 regimes into one program.
Final simplification9.4
\[\leadsto \begin{array}{l}
\mathbf{if}\;b \le -1.7555105886550257 \cdot 10^{+22}:\\
\;\;\;\;\frac{-c}{b}\\
\mathbf{elif}\;b \le -3.9496534374670056 \cdot 10^{-159}:\\
\;\;\;\;\frac{\frac{c}{\frac{1}{2}}}{a} \cdot \frac{a}{\sqrt{(-4 \cdot \left(a \cdot c\right) + \left(b \cdot b\right))_*} - b}\\
\mathbf{elif}\;b \le 7.393033154911188 \cdot 10^{+137}:\\
\;\;\;\;\frac{1}{\frac{a \cdot 2}{\left(-b\right) - \sqrt{b \cdot b - \left(a \cdot c\right) \cdot 4}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{c}{b} - \frac{b}{a}\\
\end{array}\]