- Split input into 3 regimes
if b < -3.4664721385143477e+118
Initial program 49.6
\[\frac{\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Simplified49.6
\[\leadsto \color{blue}{\frac{\frac{\sqrt{(b \cdot b + \left(\left(a \cdot c\right) \cdot -4\right))_*} - b}{2}}{a}}\]
Taylor expanded around -inf 3.1
\[\leadsto \color{blue}{\frac{c}{b} - \frac{b}{a}}\]
if -3.4664721385143477e+118 < b < 1.1017832314894703e-115
Initial program 11.1
\[\frac{\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Simplified11.1
\[\leadsto \color{blue}{\frac{\frac{\sqrt{(b \cdot b + \left(\left(a \cdot c\right) \cdot -4\right))_*} - b}{2}}{a}}\]
Taylor expanded around 0 11.1
\[\leadsto \frac{\frac{\sqrt{\color{blue}{{b}^{2} - 4 \cdot \left(a \cdot c\right)}} - b}{2}}{a}\]
Simplified11.1
\[\leadsto \frac{\frac{\sqrt{\color{blue}{(\left(a \cdot c\right) \cdot -4 + \left(b \cdot b\right))_*}} - b}{2}}{a}\]
- Using strategy
rm Applied clear-num11.2
\[\leadsto \color{blue}{\frac{1}{\frac{a}{\frac{\sqrt{(\left(a \cdot c\right) \cdot -4 + \left(b \cdot b\right))_*} - b}{2}}}}\]
- Using strategy
rm Applied associate-/r/11.2
\[\leadsto \color{blue}{\frac{1}{a} \cdot \frac{\sqrt{(\left(a \cdot c\right) \cdot -4 + \left(b \cdot b\right))_*} - b}{2}}\]
- Using strategy
rm Applied associate-*l/11.1
\[\leadsto \color{blue}{\frac{1 \cdot \frac{\sqrt{(\left(a \cdot c\right) \cdot -4 + \left(b \cdot b\right))_*} - b}{2}}{a}}\]
Simplified11.1
\[\leadsto \frac{\color{blue}{\left(\sqrt{(b \cdot b + \left(\left(-4 \cdot c\right) \cdot a\right))_*} - b\right) \cdot \frac{1}{2}}}{a}\]
if 1.1017832314894703e-115 < b
Initial program 51.8
\[\frac{\left(-b\right) + \sqrt{b \cdot b - 4 \cdot \left(a \cdot c\right)}}{2 \cdot a}\]
Simplified51.8
\[\leadsto \color{blue}{\frac{\frac{\sqrt{(b \cdot b + \left(\left(a \cdot c\right) \cdot -4\right))_*} - b}{2}}{a}}\]
Taylor expanded around inf 10.8
\[\leadsto \color{blue}{-1 \cdot \frac{c}{b}}\]
Simplified10.8
\[\leadsto \color{blue}{-\frac{c}{b}}\]
- Recombined 3 regimes into one program.
Final simplification9.9
\[\leadsto \begin{array}{l}
\mathbf{if}\;b \le -3.4664721385143477 \cdot 10^{+118}:\\
\;\;\;\;\frac{c}{b} - \frac{b}{a}\\
\mathbf{elif}\;b \le 1.1017832314894703 \cdot 10^{-115}:\\
\;\;\;\;\frac{\left(\sqrt{(b \cdot b + \left(a \cdot \left(-4 \cdot c\right)\right))_*} - b\right) \cdot \frac{1}{2}}{a}\\
\mathbf{else}:\\
\;\;\;\;\frac{-c}{b}\\
\end{array}\]