- Split input into 4 regimes
if b < -2.3340664077678155e+153
Initial program 62.8
\[\frac{\left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Taylor expanded around -inf 1.0
\[\leadsto \color{blue}{-1 \cdot \frac{c}{b}}\]
Simplified1.0
\[\leadsto \color{blue}{-\frac{c}{b}}\]
if -2.3340664077678155e+153 < b < 1.3449388379146895e-122
Initial program 28.5
\[\frac{\left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
- Using strategy
rm Applied flip--29.5
\[\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/34.0
\[\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)}}\]
Simplified20.2
\[\leadsto \frac{\color{blue}{\left(a \cdot c\right) \cdot 4}}{\left(2 \cdot a\right) \cdot \left(\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}\right)}\]
- Using strategy
rm Applied times-frac14.7
\[\leadsto \color{blue}{\frac{a \cdot c}{2 \cdot a} \cdot \frac{4}{\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}}\]
Simplified10.0
\[\leadsto \color{blue}{\left(\frac{1}{2} \cdot c\right)} \cdot \frac{4}{\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}\]
Simplified10.0
\[\leadsto \left(\frac{1}{2} \cdot c\right) \cdot \color{blue}{\frac{4}{\sqrt{c \cdot \left(-4 \cdot a\right) + b \cdot b} - b}}\]
- Using strategy
rm Applied associate-*r/9.9
\[\leadsto \color{blue}{\frac{\left(\frac{1}{2} \cdot c\right) \cdot 4}{\sqrt{c \cdot \left(-4 \cdot a\right) + b \cdot b} - b}}\]
if 1.3449388379146895e-122 < b < 1.3977277462270081e+122
Initial program 5.3
\[\frac{\left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Taylor expanded around 0 5.3
\[\leadsto \frac{\left(-b\right) - \sqrt{\color{blue}{{b}^{2} - 4 \cdot \left(a \cdot c\right)}}}{2 \cdot a}\]
Simplified5.3
\[\leadsto \frac{\left(-b\right) - \sqrt{\color{blue}{b \cdot b + \left(c \cdot -4\right) \cdot a}}}{2 \cdot a}\]
if 1.3977277462270081e+122 < b
Initial program 50.6
\[\frac{\left(-b\right) - \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Taylor expanded around inf 3.7
\[\leadsto \color{blue}{\frac{c}{b} - \frac{b}{a}}\]
- Recombined 4 regimes into one program.
Final simplification6.6
\[\leadsto \begin{array}{l}
\mathbf{if}\;b \le -2.3340664077678155 \cdot 10^{+153}:\\
\;\;\;\;-\frac{c}{b}\\
\mathbf{elif}\;b \le 1.3449388379146895 \cdot 10^{-122}:\\
\;\;\;\;\frac{\left(\frac{1}{2} \cdot c\right) \cdot 4}{\sqrt{\left(a \cdot -4\right) \cdot c + b \cdot b} - b}\\
\mathbf{elif}\;b \le 1.3977277462270081 \cdot 10^{+122}:\\
\;\;\;\;\frac{\left(-b\right) - \sqrt{b \cdot b + a \cdot \left(-4 \cdot c\right)}}{2 \cdot a}\\
\mathbf{else}:\\
\;\;\;\;\frac{c}{b} - \frac{b}{a}\\
\end{array}\]