Average Error: 52.4 → 42.9
Time: 42.2s
Precision: binary64
\[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
\[\begin{array}{l} t_0 := \mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)\\ t_1 := \frac{-\sqrt{t_0 \cdot \left(2 \cdot \left(F \cdot \left(C \cdot 2 - 0.5 \cdot \frac{{B}^{2}}{A}\right)\right)\right)}}{t_0}\\ \mathbf{if}\;A \leq -1.547843111002865 \cdot 10^{+160}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\begin{array}{l} t_2 := -\sqrt{2} \cdot \sqrt{-0.5 \cdot \frac{F}{A}}\\ \mathbf{if}\;A \leq -6.715914155896905 \cdot 10^{+93}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;A \leq -1.0277110279859103 \cdot 10^{+73}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\begin{array}{l} t_3 := \left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\\ t_4 := 2 \cdot \left(F \cdot t_3\right)\\ t_5 := -\frac{\sqrt{t_4}}{B}\\ \mathbf{if}\;A \leq -13902718134128933000:\\ \;\;\;\;t_5\\ \mathbf{elif}\;A \leq -7.898288287255473 \cdot 10^{-59}:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;\begin{array}{l} t_6 := \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\\ t_7 := t_6 \cdot \left(t_6 \cdot t_6\right)\\ \mathbf{if}\;A \leq 1.461074009586978 \cdot 10^{-196}:\\ \;\;\;\;-\frac{\sqrt{2} \cdot \sqrt{F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)}}{t_7}\\ \mathbf{elif}\;A \leq 1.525172088274872 \cdot 10^{+28}:\\ \;\;\;\;\begin{array}{l} t_8 := \sqrt{t_3}\\ \frac{-\sqrt{t_0 \cdot \left(2 \cdot \left(F \cdot \left(t_8 \cdot t_8\right)\right)\right)}}{t_0} \end{array}\\ \mathbf{elif}\;A \leq 7.020914566277488 \cdot 10^{+115}:\\ \;\;\;\;-\frac{\sqrt{2} \cdot \sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}}{t_7}\\ \mathbf{elif}\;A \leq 1.8247188167373362 \cdot 10^{+153}:\\ \;\;\;\;\begin{array}{l} t_9 := \sqrt{\left(A \cdot A + \left(B \cdot B + C \cdot C\right)\right) - 2 \cdot \left(A \cdot C\right)}\\ \frac{-\sqrt{F \cdot \left(\mathsf{fma}\left(2, C \cdot \left(B \cdot B\right), 2 \cdot \left(\left(B \cdot B\right) \cdot t_9 + A \cdot \left(B \cdot B\right)\right)\right) - \mathsf{fma}\left(8, C \cdot \left(A \cdot A\right), 8 \cdot \left(A \cdot \left(C \cdot C\right) + \left(A \cdot C\right) \cdot t_9\right)\right)\right)}}{t_0} \end{array}\\ \mathbf{elif}\;A \leq 5.48701879697187 \cdot 10^{+159}:\\ \;\;\;\;t_5\\ \mathbf{elif}\;A \leq 9.070489695444037 \cdot 10^{+172}:\\ \;\;\;\;\begin{array}{l} t_10 := \sqrt{t_0}\\ \frac{-\sqrt{t_10 \cdot \left(t_4 \cdot t_10\right)}}{t_0} \end{array}\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{-0.5 \cdot \frac{F}{C}}\\ \end{array}\\ \end{array}\\ \end{array}\\ \end{array} \]
\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C}
\begin{array}{l}
t_0 := \mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)\\
t_1 := \frac{-\sqrt{t_0 \cdot \left(2 \cdot \left(F \cdot \left(C \cdot 2 - 0.5 \cdot \frac{{B}^{2}}{A}\right)\right)\right)}}{t_0}\\
\mathbf{if}\;A \leq -1.547843111002865 \cdot 10^{+160}:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;\begin{array}{l}
t_2 := -\sqrt{2} \cdot \sqrt{-0.5 \cdot \frac{F}{A}}\\
\mathbf{if}\;A \leq -6.715914155896905 \cdot 10^{+93}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;A \leq -1.0277110279859103 \cdot 10^{+73}:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;\begin{array}{l}
t_3 := \left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\\
t_4 := 2 \cdot \left(F \cdot t_3\right)\\
t_5 := -\frac{\sqrt{t_4}}{B}\\
\mathbf{if}\;A \leq -13902718134128933000:\\
\;\;\;\;t_5\\

\mathbf{elif}\;A \leq -7.898288287255473 \cdot 10^{-59}:\\
\;\;\;\;t_2\\

\mathbf{else}:\\
\;\;\;\;\begin{array}{l}
t_6 := \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\\
t_7 := t_6 \cdot \left(t_6 \cdot t_6\right)\\
\mathbf{if}\;A \leq 1.461074009586978 \cdot 10^{-196}:\\
\;\;\;\;-\frac{\sqrt{2} \cdot \sqrt{F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)}}{t_7}\\

\mathbf{elif}\;A \leq 1.525172088274872 \cdot 10^{+28}:\\
\;\;\;\;\begin{array}{l}
t_8 := \sqrt{t_3}\\
\frac{-\sqrt{t_0 \cdot \left(2 \cdot \left(F \cdot \left(t_8 \cdot t_8\right)\right)\right)}}{t_0}
\end{array}\\

\mathbf{elif}\;A \leq 7.020914566277488 \cdot 10^{+115}:\\
\;\;\;\;-\frac{\sqrt{2} \cdot \sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}}{t_7}\\

\mathbf{elif}\;A \leq 1.8247188167373362 \cdot 10^{+153}:\\
\;\;\;\;\begin{array}{l}
t_9 := \sqrt{\left(A \cdot A + \left(B \cdot B + C \cdot C\right)\right) - 2 \cdot \left(A \cdot C\right)}\\
\frac{-\sqrt{F \cdot \left(\mathsf{fma}\left(2, C \cdot \left(B \cdot B\right), 2 \cdot \left(\left(B \cdot B\right) \cdot t_9 + A \cdot \left(B \cdot B\right)\right)\right) - \mathsf{fma}\left(8, C \cdot \left(A \cdot A\right), 8 \cdot \left(A \cdot \left(C \cdot C\right) + \left(A \cdot C\right) \cdot t_9\right)\right)\right)}}{t_0}
\end{array}\\

\mathbf{elif}\;A \leq 5.48701879697187 \cdot 10^{+159}:\\
\;\;\;\;t_5\\

\mathbf{elif}\;A \leq 9.070489695444037 \cdot 10^{+172}:\\
\;\;\;\;\begin{array}{l}
t_10 := \sqrt{t_0}\\
\frac{-\sqrt{t_10 \cdot \left(t_4 \cdot t_10\right)}}{t_0}
\end{array}\\

\mathbf{else}:\\
\;\;\;\;-\sqrt{2} \cdot \sqrt{-0.5 \cdot \frac{F}{C}}\\


\end{array}\\


\end{array}\\


\end{array}\\


\end{array}
(FPCore (A B C F)
 :precision binary64
 (/
  (-
   (sqrt
    (*
     (* 2.0 (* (- (pow B 2.0) (* (* 4.0 A) C)) F))
     (+ (+ A C) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0)))))))
  (- (pow B 2.0) (* (* 4.0 A) C))))
(FPCore (A B C F)
 :precision binary64
 (let* ((t_0 (fma A (* C -4.0) (* B B)))
        (t_1
         (/
          (-
           (sqrt
            (* t_0 (* 2.0 (* F (- (* C 2.0) (* 0.5 (/ (pow B 2.0) A))))))))
          t_0)))
   (if (<= A -1.547843111002865e+160)
     t_1
     (let* ((t_2 (- (* (sqrt 2.0) (sqrt (* -0.5 (/ F A)))))))
       (if (<= A -6.715914155896905e+93)
         t_2
         (if (<= A -1.0277110279859103e+73)
           t_1
           (let* ((t_3 (+ (+ A C) (hypot B (- A C))))
                  (t_4 (* 2.0 (* F t_3)))
                  (t_5 (- (/ (sqrt t_4) B))))
             (if (<= A -13902718134128933000.0)
               t_5
               (if (<= A -7.898288287255473e-59)
                 t_2
                 (let* ((t_6 (cbrt (hypot (sqrt (* A (* C -4.0))) B)))
                        (t_7 (* t_6 (* t_6 t_6))))
                   (if (<= A 1.461074009586978e-196)
                     (- (/ (* (sqrt 2.0) (sqrt (* F (+ C (hypot B C))))) t_7))
                     (if (<= A 1.525172088274872e+28)
                       (let* ((t_8 (sqrt t_3)))
                         (/ (- (sqrt (* t_0 (* 2.0 (* F (* t_8 t_8)))))) t_0))
                       (if (<= A 7.020914566277488e+115)
                         (-
                          (/
                           (* (sqrt 2.0) (sqrt (* F (+ A (hypot B A)))))
                           t_7))
                         (if (<= A 1.8247188167373362e+153)
                           (let* ((t_9
                                   (sqrt
                                    (-
                                     (+ (* A A) (+ (* B B) (* C C)))
                                     (* 2.0 (* A C))))))
                             (/
                              (-
                               (sqrt
                                (*
                                 F
                                 (-
                                  (fma
                                   2.0
                                   (* C (* B B))
                                   (* 2.0 (+ (* (* B B) t_9) (* A (* B B)))))
                                  (fma
                                   8.0
                                   (* C (* A A))
                                   (*
                                    8.0
                                    (+ (* A (* C C)) (* (* A C) t_9))))))))
                              t_0))
                           (if (<= A 5.48701879697187e+159)
                             t_5
                             (if (<= A 9.070489695444037e+172)
                               (let* ((t_10 (sqrt t_0)))
                                 (/ (- (sqrt (* t_10 (* t_4 t_10)))) t_0))
                               (-
                                (*
                                 (sqrt 2.0)
                                 (sqrt (* -0.5 (/ F C)))))))))))))))))))))
double code(double A, double B, double C, double F) {
	return -sqrt((2.0 * ((pow(B, 2.0) - ((4.0 * A) * C)) * F)) * ((A + C) + sqrt(pow((A - C), 2.0) + pow(B, 2.0)))) / (pow(B, 2.0) - ((4.0 * A) * C));
}
double code(double A, double B, double C, double F) {
	double t_0 = fma(A, (C * -4.0), (B * B));
	double t_1 = -sqrt(t_0 * (2.0 * (F * ((C * 2.0) - (0.5 * (pow(B, 2.0) / A)))))) / t_0;
	double tmp;
	if (A <= -1.547843111002865e+160) {
		tmp = t_1;
	} else {
		double t_2 = -(sqrt(2.0) * sqrt(-0.5 * (F / A)));
		double tmp_1;
		if (A <= -6.715914155896905e+93) {
			tmp_1 = t_2;
		} else if (A <= -1.0277110279859103e+73) {
			tmp_1 = t_1;
		} else {
			double t_3 = (A + C) + hypot(B, (A - C));
			double t_4 = 2.0 * (F * t_3);
			double t_5 = -(sqrt(t_4) / B);
			double tmp_2;
			if (A <= -13902718134128933000.0) {
				tmp_2 = t_5;
			} else if (A <= -7.898288287255473e-59) {
				tmp_2 = t_2;
			} else {
				double t_6 = cbrt(hypot(sqrt(A * (C * -4.0)), B));
				double t_7 = t_6 * (t_6 * t_6);
				double tmp_3;
				if (A <= 1.461074009586978e-196) {
					tmp_3 = -((sqrt(2.0) * sqrt(F * (C + hypot(B, C)))) / t_7);
				} else if (A <= 1.525172088274872e+28) {
					double t_8 = sqrt(t_3);
					tmp_3 = -sqrt(t_0 * (2.0 * (F * (t_8 * t_8)))) / t_0;
				} else if (A <= 7.020914566277488e+115) {
					tmp_3 = -((sqrt(2.0) * sqrt(F * (A + hypot(B, A)))) / t_7);
				} else if (A <= 1.8247188167373362e+153) {
					double t_9 = sqrt(((A * A) + ((B * B) + (C * C))) - (2.0 * (A * C)));
					tmp_3 = -sqrt(F * (fma(2.0, (C * (B * B)), (2.0 * (((B * B) * t_9) + (A * (B * B))))) - fma(8.0, (C * (A * A)), (8.0 * ((A * (C * C)) + ((A * C) * t_9)))))) / t_0;
				} else if (A <= 5.48701879697187e+159) {
					tmp_3 = t_5;
				} else if (A <= 9.070489695444037e+172) {
					double t_10 = sqrt(t_0);
					tmp_3 = -sqrt(t_10 * (t_4 * t_10)) / t_0;
				} else {
					tmp_3 = -(sqrt(2.0) * sqrt(-0.5 * (F / C)));
				}
				tmp_2 = tmp_3;
			}
			tmp_1 = tmp_2;
		}
		tmp = tmp_1;
	}
	return tmp;
}

Error

Bits error versus A

Bits error versus B

Bits error versus C

Bits error versus F

Derivation

  1. Split input into 9 regimes
  2. if A < -1.5478431110028651e160 or -6.71591415589690537e93 < A < -1.0277110279859103e73

    1. Initial program 63.3

      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    2. Simplified61.9

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    3. Taylor expanded in A around -inf 44.5

      \[\leadsto \frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \color{blue}{\left(2 \cdot C - 0.5 \cdot \frac{{B}^{2}}{A}\right)}\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \]

    if -1.5478431110028651e160 < A < -6.71591415589690537e93 or -13902718134128932900 < A < -7.898288287255473e-59

    1. Initial program 55.7

      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    2. Simplified54.2

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    3. Taylor expanded in C around inf 41.1

      \[\leadsto \color{blue}{-1 \cdot \left(\sqrt{2} \cdot \sqrt{-0.5 \cdot \frac{F}{A}}\right)} \]
    4. Simplified41.1

      \[\leadsto \color{blue}{-\sqrt{2} \cdot \sqrt{-0.5 \cdot \frac{F}{A}}} \]

    if -1.0277110279859103e73 < A < -13902718134128932900 or 1.82471881673734e153 < A < 5.4870187969718703e159

    1. Initial program 57.7

      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    2. Simplified54.6

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    3. Applied add-sqr-sqrt_binary6456.6

      \[\leadsto \frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\color{blue}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}} \]
    4. Applied sqrt-prod_binary6451.9

      \[\leadsto \frac{-\color{blue}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    5. Applied distribute-lft-neg-in_binary6451.9

      \[\leadsto \frac{\color{blue}{\left(-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}\right) \cdot \sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    6. Applied times-frac_binary6451.9

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}} \]
    7. Simplified51.2

      \[\leadsto \color{blue}{-1} \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    8. Taylor expanded in A around 0 55.6

      \[\leadsto -1 \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\color{blue}{B}} \]

    if -7.898288287255473e-59 < A < 1.4610740095869779e-196

    1. Initial program 48.9

      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    2. Simplified45.7

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    3. Applied add-sqr-sqrt_binary6447.7

      \[\leadsto \frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\color{blue}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}} \]
    4. Applied sqrt-prod_binary6441.7

      \[\leadsto \frac{-\color{blue}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    5. Applied distribute-lft-neg-in_binary6441.7

      \[\leadsto \frac{\color{blue}{\left(-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}\right) \cdot \sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    6. Applied times-frac_binary6441.7

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}} \]
    7. Simplified41.2

      \[\leadsto \color{blue}{-1} \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    8. Applied add-cube-cbrt_binary6441.5

      \[\leadsto -1 \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\color{blue}{\left(\sqrt[3]{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \cdot \sqrt[3]{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}\right) \cdot \sqrt[3]{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}}} \]
    9. Simplified46.1

      \[\leadsto -1 \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\color{blue}{\left(\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\right)} \cdot \sqrt[3]{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}} \]
    10. Simplified39.4

      \[\leadsto -1 \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\left(\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\right) \cdot \color{blue}{\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}}} \]
    11. Taylor expanded in A around 0 48.7

      \[\leadsto -1 \cdot \frac{\color{blue}{\sqrt{\left(\sqrt{{B}^{2} + {C}^{2}} + C\right) \cdot F} \cdot \sqrt{2}}}{\left(\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\right) \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}} \]
    12. Simplified39.3

      \[\leadsto -1 \cdot \frac{\color{blue}{\sqrt{\left(C + \mathsf{hypot}\left(B, C\right)\right) \cdot F} \cdot \sqrt{2}}}{\left(\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\right) \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}} \]

    if 1.4610740095869779e-196 < A < 1.5251720882748719e28

    1. Initial program 45.7

      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    2. Simplified43.3

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    3. Applied add-sqr-sqrt_binary6443.3

      \[\leadsto \frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \color{blue}{\left(\sqrt{\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)} \cdot \sqrt{\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)}\right)}\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \]

    if 1.5251720882748719e28 < A < 7.02091456627748789e115

    1. Initial program 40.3

      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    2. Simplified39.5

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    3. Applied add-sqr-sqrt_binary6448.6

      \[\leadsto \frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\color{blue}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}} \]
    4. Applied sqrt-prod_binary6445.1

      \[\leadsto \frac{-\color{blue}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    5. Applied distribute-lft-neg-in_binary6445.1

      \[\leadsto \frac{\color{blue}{\left(-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}\right) \cdot \sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    6. Applied times-frac_binary6445.0

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}} \]
    7. Simplified44.2

      \[\leadsto \color{blue}{-1} \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    8. Applied add-cube-cbrt_binary6444.5

      \[\leadsto -1 \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\color{blue}{\left(\sqrt[3]{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \cdot \sqrt[3]{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}\right) \cdot \sqrt[3]{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}}} \]
    9. Simplified49.3

      \[\leadsto -1 \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\color{blue}{\left(\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\right)} \cdot \sqrt[3]{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}}} \]
    10. Simplified44.2

      \[\leadsto -1 \cdot \frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{\left(\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\right) \cdot \color{blue}{\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}}} \]
    11. Taylor expanded in C around 0 45.6

      \[\leadsto -1 \cdot \frac{\color{blue}{\sqrt{F \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)} \cdot \sqrt{2}}}{\left(\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\right) \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}} \]
    12. Simplified40.4

      \[\leadsto -1 \cdot \frac{\color{blue}{\sqrt{2} \cdot \sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}}}{\left(\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\right) \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}} \]

    if 7.02091456627748789e115 < A < 1.82471881673734e153

    1. Initial program 40.3

      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    2. Simplified41.3

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    3. Taylor expanded in F around 0 45.1

      \[\leadsto \frac{-\sqrt{\color{blue}{F \cdot \left(\left(2 \cdot \left(C \cdot {B}^{2}\right) + \left(2 \cdot \left(\sqrt{\left({A}^{2} + \left({B}^{2} + {C}^{2}\right)\right) - 2 \cdot \left(A \cdot C\right)} \cdot {B}^{2}\right) + 2 \cdot \left(A \cdot {B}^{2}\right)\right)\right) - \left(8 \cdot \left({A}^{2} \cdot C\right) + \left(8 \cdot \left(A \cdot {C}^{2}\right) + 8 \cdot \left(\left(A \cdot C\right) \cdot \sqrt{\left({A}^{2} + \left({B}^{2} + {C}^{2}\right)\right) - 2 \cdot \left(A \cdot C\right)}\right)\right)\right)\right)}}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \]
    4. Simplified45.1

      \[\leadsto \frac{-\sqrt{\color{blue}{F \cdot \left(\mathsf{fma}\left(2, C \cdot \left(B \cdot B\right), 2 \cdot \left(\sqrt{\left(A \cdot A + \left(B \cdot B + C \cdot C\right)\right) - 2 \cdot \left(A \cdot C\right)} \cdot \left(B \cdot B\right) + A \cdot \left(B \cdot B\right)\right)\right) - \mathsf{fma}\left(8, \left(A \cdot A\right) \cdot C, 8 \cdot \left(A \cdot \left(C \cdot C\right) + \left(A \cdot C\right) \cdot \sqrt{\left(A \cdot A + \left(B \cdot B + C \cdot C\right)\right) - 2 \cdot \left(A \cdot C\right)}\right)\right)\right)}}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \]

    if 5.4870187969718703e159 < A < 9.0704896954440372e172

    1. Initial program 64.0

      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    2. Simplified46.3

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    3. Applied add-sqr-sqrt_binary6452.8

      \[\leadsto \frac{-\sqrt{\color{blue}{\left(\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}\right)} \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \]
    4. Applied associate-*l*_binary6452.8

      \[\leadsto \frac{-\sqrt{\color{blue}{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \left(\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)\right)}}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \]

    if 9.0704896954440372e172 < A

    1. Initial program 64.0

      \[\frac{-\sqrt{\left(2 \cdot \left(\left({B}^{2} - \left(4 \cdot A\right) \cdot C\right) \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{{B}^{2} - \left(4 \cdot A\right) \cdot C} \]
    2. Simplified54.5

      \[\leadsto \color{blue}{\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}} \]
    3. Taylor expanded in A around inf 45.4

      \[\leadsto \color{blue}{-1 \cdot \left(\sqrt{-0.5 \cdot \frac{F}{C}} \cdot \sqrt{2}\right)} \]
    4. Simplified45.4

      \[\leadsto \color{blue}{-\sqrt{-0.5 \cdot \frac{F}{C}} \cdot \sqrt{2}} \]
  3. Recombined 9 regimes into one program.
  4. Final simplification42.9

    \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -1.547843111002865 \cdot 10^{+160}:\\ \;\;\;\;\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(C \cdot 2 - 0.5 \cdot \frac{{B}^{2}}{A}\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}\\ \mathbf{elif}\;A \leq -6.715914155896905 \cdot 10^{+93}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{-0.5 \cdot \frac{F}{A}}\\ \mathbf{elif}\;A \leq -1.0277110279859103 \cdot 10^{+73}:\\ \;\;\;\;\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(C \cdot 2 - 0.5 \cdot \frac{{B}^{2}}{A}\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}\\ \mathbf{elif}\;A \leq -13902718134128933000:\\ \;\;\;\;-\frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{B}\\ \mathbf{elif}\;A \leq -7.898288287255473 \cdot 10^{-59}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{-0.5 \cdot \frac{F}{A}}\\ \mathbf{elif}\;A \leq 1.461074009586978 \cdot 10^{-196}:\\ \;\;\;\;-\frac{\sqrt{2} \cdot \sqrt{F \cdot \left(C + \mathsf{hypot}\left(B, C\right)\right)}}{\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \left(\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\right)}\\ \mathbf{elif}\;A \leq 1.525172088274872 \cdot 10^{+28}:\\ \;\;\;\;\frac{-\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right) \cdot \left(2 \cdot \left(F \cdot \left(\sqrt{\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)} \cdot \sqrt{\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}\\ \mathbf{elif}\;A \leq 7.020914566277488 \cdot 10^{+115}:\\ \;\;\;\;-\frac{\sqrt{2} \cdot \sqrt{F \cdot \left(A + \mathsf{hypot}\left(B, A\right)\right)}}{\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \left(\sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)} \cdot \sqrt[3]{\mathsf{hypot}\left(\sqrt{A \cdot \left(C \cdot -4\right)}, B\right)}\right)}\\ \mathbf{elif}\;A \leq 1.8247188167373362 \cdot 10^{+153}:\\ \;\;\;\;\frac{-\sqrt{F \cdot \left(\mathsf{fma}\left(2, C \cdot \left(B \cdot B\right), 2 \cdot \left(\left(B \cdot B\right) \cdot \sqrt{\left(A \cdot A + \left(B \cdot B + C \cdot C\right)\right) - 2 \cdot \left(A \cdot C\right)} + A \cdot \left(B \cdot B\right)\right)\right) - \mathsf{fma}\left(8, C \cdot \left(A \cdot A\right), 8 \cdot \left(A \cdot \left(C \cdot C\right) + \left(A \cdot C\right) \cdot \sqrt{\left(A \cdot A + \left(B \cdot B + C \cdot C\right)\right) - 2 \cdot \left(A \cdot C\right)}\right)\right)\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}\\ \mathbf{elif}\;A \leq 5.48701879697187 \cdot 10^{+159}:\\ \;\;\;\;-\frac{\sqrt{2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)}}{B}\\ \mathbf{elif}\;A \leq 9.070489695444037 \cdot 10^{+172}:\\ \;\;\;\;\frac{-\sqrt{\sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)} \cdot \left(\left(2 \cdot \left(F \cdot \left(\left(A + C\right) + \mathsf{hypot}\left(B, A - C\right)\right)\right)\right) \cdot \sqrt{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}\right)}}{\mathsf{fma}\left(A, C \cdot -4, B \cdot B\right)}\\ \mathbf{else}:\\ \;\;\;\;-\sqrt{2} \cdot \sqrt{-0.5 \cdot \frac{F}{C}}\\ \end{array} \]

Reproduce

herbie shell --seed 2022103 
(FPCore (A B C F)
  :name "ABCF->ab-angle a"
  :precision binary64
  (/ (- (sqrt (* (* 2.0 (* (- (pow B 2.0) (* (* 4.0 A) C)) F)) (+ (+ A C) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0))))))) (- (pow B 2.0) (* (* 4.0 A) C))))