ABCF->ab-angle angle

Percentage Accurate: 54.0% → 87.8%
Time: 19.4s
Alternatives: 20
Speedup: 3.6×

Specification

?
\[\begin{array}{l} \\ 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (*
  180.0
  (/
   (atan (* (/ 1.0 B) (- (- C A) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0))))))
   PI)))
double code(double A, double B, double C) {
	return 180.0 * (atan(((1.0 / B) * ((C - A) - sqrt((pow((A - C), 2.0) + pow(B, 2.0)))))) / ((double) M_PI));
}
public static double code(double A, double B, double C) {
	return 180.0 * (Math.atan(((1.0 / B) * ((C - A) - Math.sqrt((Math.pow((A - C), 2.0) + Math.pow(B, 2.0)))))) / Math.PI);
}
def code(A, B, C):
	return 180.0 * (math.atan(((1.0 / B) * ((C - A) - math.sqrt((math.pow((A - C), 2.0) + math.pow(B, 2.0)))))) / math.pi)
function code(A, B, C)
	return Float64(180.0 * Float64(atan(Float64(Float64(1.0 / B) * Float64(Float64(C - A) - sqrt(Float64((Float64(A - C) ^ 2.0) + (B ^ 2.0)))))) / pi))
end
function tmp = code(A, B, C)
	tmp = 180.0 * (atan(((1.0 / B) * ((C - A) - sqrt((((A - C) ^ 2.0) + (B ^ 2.0)))))) / pi);
end
code[A_, B_, C_] := N[(180.0 * N[(N[ArcTan[N[(N[(1.0 / B), $MachinePrecision] * N[(N[(C - A), $MachinePrecision] - N[Sqrt[N[(N[Power[N[(A - C), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[B, 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi}
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 20 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 54.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (*
  180.0
  (/
   (atan (* (/ 1.0 B) (- (- C A) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0))))))
   PI)))
double code(double A, double B, double C) {
	return 180.0 * (atan(((1.0 / B) * ((C - A) - sqrt((pow((A - C), 2.0) + pow(B, 2.0)))))) / ((double) M_PI));
}
public static double code(double A, double B, double C) {
	return 180.0 * (Math.atan(((1.0 / B) * ((C - A) - Math.sqrt((Math.pow((A - C), 2.0) + Math.pow(B, 2.0)))))) / Math.PI);
}
def code(A, B, C):
	return 180.0 * (math.atan(((1.0 / B) * ((C - A) - math.sqrt((math.pow((A - C), 2.0) + math.pow(B, 2.0)))))) / math.pi)
function code(A, B, C)
	return Float64(180.0 * Float64(atan(Float64(Float64(1.0 / B) * Float64(Float64(C - A) - sqrt(Float64((Float64(A - C) ^ 2.0) + (B ^ 2.0)))))) / pi))
end
function tmp = code(A, B, C)
	tmp = 180.0 * (atan(((1.0 / B) * ((C - A) - sqrt((((A - C) ^ 2.0) + (B ^ 2.0)))))) / pi);
end
code[A_, B_, C_] := N[(180.0 * N[(N[ArcTan[N[(N[(1.0 / B), $MachinePrecision] * N[(N[(C - A), $MachinePrecision] - N[Sqrt[N[(N[Power[N[(A - C), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[B, 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi}
\end{array}

Alternative 1: 87.8% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\\ t_1 := \tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)\\ \mathbf{if}\;t\_0 \leq -0.5:\\ \;\;\;\;\frac{180 \cdot t\_1}{\pi}\\ \mathbf{elif}\;t\_0 \leq 0:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{\frac{B}{A}}{\mathsf{fma}\left(-2, \frac{C}{A}, 2\right)}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{t\_1}}\\ \end{array} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (let* ((t_0
         (* (/ 1.0 B) (- (- C A) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0))))))
        (t_1 (atan (/ (- (- C A) (hypot B (- A C))) B))))
   (if (<= t_0 -0.5)
     (/ (* 180.0 t_1) PI)
     (if (<= t_0 0.0)
       (* 180.0 (/ (atan (/ (/ B A) (fma -2.0 (/ C A) 2.0))) PI))
       (/ 180.0 (/ PI t_1))))))
double code(double A, double B, double C) {
	double t_0 = (1.0 / B) * ((C - A) - sqrt((pow((A - C), 2.0) + pow(B, 2.0))));
	double t_1 = atan((((C - A) - hypot(B, (A - C))) / B));
	double tmp;
	if (t_0 <= -0.5) {
		tmp = (180.0 * t_1) / ((double) M_PI);
	} else if (t_0 <= 0.0) {
		tmp = 180.0 * (atan(((B / A) / fma(-2.0, (C / A), 2.0))) / ((double) M_PI));
	} else {
		tmp = 180.0 / (((double) M_PI) / t_1);
	}
	return tmp;
}
function code(A, B, C)
	t_0 = Float64(Float64(1.0 / B) * Float64(Float64(C - A) - sqrt(Float64((Float64(A - C) ^ 2.0) + (B ^ 2.0)))))
	t_1 = atan(Float64(Float64(Float64(C - A) - hypot(B, Float64(A - C))) / B))
	tmp = 0.0
	if (t_0 <= -0.5)
		tmp = Float64(Float64(180.0 * t_1) / pi);
	elseif (t_0 <= 0.0)
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(B / A) / fma(-2.0, Float64(C / A), 2.0))) / pi));
	else
		tmp = Float64(180.0 / Float64(pi / t_1));
	end
	return tmp
end
code[A_, B_, C_] := Block[{t$95$0 = N[(N[(1.0 / B), $MachinePrecision] * N[(N[(C - A), $MachinePrecision] - N[Sqrt[N[(N[Power[N[(A - C), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[B, 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[ArcTan[N[(N[(N[(C - A), $MachinePrecision] - N[Sqrt[B ^ 2 + N[(A - C), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$0, -0.5], N[(N[(180.0 * t$95$1), $MachinePrecision] / Pi), $MachinePrecision], If[LessEqual[t$95$0, 0.0], N[(180.0 * N[(N[ArcTan[N[(N[(B / A), $MachinePrecision] / N[(-2.0 * N[(C / A), $MachinePrecision] + 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 / N[(Pi / t$95$1), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\\
t_1 := \tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)\\
\mathbf{if}\;t\_0 \leq -0.5:\\
\;\;\;\;\frac{180 \cdot t\_1}{\pi}\\

\mathbf{elif}\;t\_0 \leq 0:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{\frac{B}{A}}{\mathsf{fma}\left(-2, \frac{C}{A}, 2\right)}\right)}{\pi}\\

\mathbf{else}:\\
\;\;\;\;\frac{180}{\frac{\pi}{t\_1}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 (/.f64 #s(literal 1 binary64) B) (-.f64 (-.f64 C A) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) #s(literal 2 binary64)) (pow.f64 B #s(literal 2 binary64)))))) < -0.5

    1. Initial program 54.6%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. associate-*r/54.6%

        \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi}} \]
    4. Applied egg-rr91.0%

      \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}{\pi}} \]

    if -0.5 < (*.f64 (/.f64 #s(literal 1 binary64) B) (-.f64 (-.f64 C A) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) #s(literal 2 binary64)) (pow.f64 B #s(literal 2 binary64)))))) < -0.0

    1. Initial program 19.4%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. associate--l-12.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
      2. +-commutative12.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
      3. unpow212.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
      4. unpow212.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
      5. hypot-undefine12.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
      6. associate-/r/12.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
      7. associate--r+19.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
    4. Applied egg-rr19.4%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
    5. Taylor expanded in A around -inf 63.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
    6. Step-by-step derivation
      1. associate-*r*63.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
      2. mul-1-neg63.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
      3. associate-*r/63.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
      4. metadata-eval63.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
    7. Simplified63.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
    8. Taylor expanded in B around -inf 91.7%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{B}{A \cdot \left(2 + -2 \cdot \frac{C}{A}\right)}\right)}}{\pi} \]
    9. Step-by-step derivation
      1. associate-/r*91.8%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{\frac{B}{A}}{2 + -2 \cdot \frac{C}{A}}\right)}}{\pi} \]
      2. +-commutative91.8%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\frac{B}{A}}{\color{blue}{-2 \cdot \frac{C}{A} + 2}}\right)}{\pi} \]
      3. fma-define91.8%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\frac{B}{A}}{\color{blue}{\mathsf{fma}\left(-2, \frac{C}{A}, 2\right)}}\right)}{\pi} \]
    10. Simplified91.8%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{\frac{B}{A}}{\mathsf{fma}\left(-2, \frac{C}{A}, 2\right)}\right)}}{\pi} \]

    if -0.0 < (*.f64 (/.f64 #s(literal 1 binary64) B) (-.f64 (-.f64 C A) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) #s(literal 2 binary64)) (pow.f64 B #s(literal 2 binary64))))))

    1. Initial program 60.5%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutative60.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
      2. associate--l-60.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
      3. +-commutative60.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      4. unpow260.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      5. unpow260.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      6. hypot-undefine86.9%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      7. div-inv86.9%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
      8. clear-num86.9%

        \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      9. un-div-inv86.9%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
    4. Applied egg-rr90.4%

      \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 2: 78.0% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;A \leq -1.55 \cdot 10^{-38}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\ \mathbf{elif}\;A \leq 1.9 \cdot 10^{-124}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(A, B\right)}{-B}\right)}{\pi}\\ \end{array} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (if (<= A -1.55e-38)
   (/ (* 180.0 (atan (/ (/ -1.0 A) (- (/ (* C 2.0) (* B A)) (/ 2.0 B))))) PI)
   (if (<= A 1.9e-124)
     (* 180.0 (/ (atan (/ (- C (hypot C B)) B)) PI))
     (* 180.0 (/ (atan (/ (+ A (hypot A B)) (- B))) PI)))))
double code(double A, double B, double C) {
	double tmp;
	if (A <= -1.55e-38) {
		tmp = (180.0 * atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / ((double) M_PI);
	} else if (A <= 1.9e-124) {
		tmp = 180.0 * (atan(((C - hypot(C, B)) / B)) / ((double) M_PI));
	} else {
		tmp = 180.0 * (atan(((A + hypot(A, B)) / -B)) / ((double) M_PI));
	}
	return tmp;
}
public static double code(double A, double B, double C) {
	double tmp;
	if (A <= -1.55e-38) {
		tmp = (180.0 * Math.atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / Math.PI;
	} else if (A <= 1.9e-124) {
		tmp = 180.0 * (Math.atan(((C - Math.hypot(C, B)) / B)) / Math.PI);
	} else {
		tmp = 180.0 * (Math.atan(((A + Math.hypot(A, B)) / -B)) / Math.PI);
	}
	return tmp;
}
def code(A, B, C):
	tmp = 0
	if A <= -1.55e-38:
		tmp = (180.0 * math.atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / math.pi
	elif A <= 1.9e-124:
		tmp = 180.0 * (math.atan(((C - math.hypot(C, B)) / B)) / math.pi)
	else:
		tmp = 180.0 * (math.atan(((A + math.hypot(A, B)) / -B)) / math.pi)
	return tmp
function code(A, B, C)
	tmp = 0.0
	if (A <= -1.55e-38)
		tmp = Float64(Float64(180.0 * atan(Float64(Float64(-1.0 / A) / Float64(Float64(Float64(C * 2.0) / Float64(B * A)) - Float64(2.0 / B))))) / pi);
	elseif (A <= 1.9e-124)
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(C - hypot(C, B)) / B)) / pi));
	else
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(A + hypot(A, B)) / Float64(-B))) / pi));
	end
	return tmp
end
function tmp_2 = code(A, B, C)
	tmp = 0.0;
	if (A <= -1.55e-38)
		tmp = (180.0 * atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / pi;
	elseif (A <= 1.9e-124)
		tmp = 180.0 * (atan(((C - hypot(C, B)) / B)) / pi);
	else
		tmp = 180.0 * (atan(((A + hypot(A, B)) / -B)) / pi);
	end
	tmp_2 = tmp;
end
code[A_, B_, C_] := If[LessEqual[A, -1.55e-38], N[(N[(180.0 * N[ArcTan[N[(N[(-1.0 / A), $MachinePrecision] / N[(N[(N[(C * 2.0), $MachinePrecision] / N[(B * A), $MachinePrecision]), $MachinePrecision] - N[(2.0 / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], If[LessEqual[A, 1.9e-124], N[(180.0 * N[(N[ArcTan[N[(N[(C - N[Sqrt[C ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(A + N[Sqrt[A ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / (-B)), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;A \leq -1.55 \cdot 10^{-38}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\

\mathbf{elif}\;A \leq 1.9 \cdot 10^{-124}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}{\pi}\\

\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(A, B\right)}{-B}\right)}{\pi}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if A < -1.54999999999999991e-38

    1. Initial program 29.3%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. associate--l-24.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
      2. +-commutative24.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
      3. unpow224.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
      4. unpow224.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
      5. hypot-undefine36.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
      6. associate-/r/36.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
      7. associate--r+55.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
    4. Applied egg-rr55.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
    5. Taylor expanded in A around -inf 72.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
    6. Step-by-step derivation
      1. associate-*r*72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
      2. mul-1-neg72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
      3. associate-*r/72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
      4. metadata-eval72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
    7. Simplified72.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
    8. Step-by-step derivation
      1. associate-*r/72.6%

        \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}\right)}{\pi}} \]
      2. associate-/r*72.6%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\frac{\frac{1}{-A}}{2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}}\right)}}{\pi} \]
      3. associate-*r/72.6%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(\frac{\frac{1}{-A}}{\color{blue}{\frac{2 \cdot C}{A \cdot B}} - \frac{2}{B}}\right)}{\pi} \]
    9. Applied egg-rr72.6%

      \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\frac{1}{-A}}{\frac{2 \cdot C}{A \cdot B} - \frac{2}{B}}\right)}{\pi}} \]

    if -1.54999999999999991e-38 < A < 1.90000000000000006e-124

    1. Initial program 48.3%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Taylor expanded in A around 0 47.2%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \sqrt{{B}^{2} + {C}^{2}}}{B}\right)}}{\pi} \]
    4. Step-by-step derivation
      1. +-commutative47.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{C - \sqrt{\color{blue}{{C}^{2} + {B}^{2}}}}{B}\right)}{\pi} \]
      2. unpow247.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{C - \sqrt{\color{blue}{C \cdot C} + {B}^{2}}}{B}\right)}{\pi} \]
      3. unpow247.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{C - \sqrt{C \cdot C + \color{blue}{B \cdot B}}}{B}\right)}{\pi} \]
      4. hypot-define76.3%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{C - \color{blue}{\mathsf{hypot}\left(C, B\right)}}{B}\right)}{\pi} \]
    5. Simplified76.3%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}}{\pi} \]

    if 1.90000000000000006e-124 < A

    1. Initial program 69.9%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Taylor expanded in C around 0 68.0%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + \sqrt{{A}^{2} + {B}^{2}}}{B}\right)}}{\pi} \]
    4. Step-by-step derivation
      1. associate-*r/68.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{-1 \cdot \left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}{B}\right)}}{\pi} \]
      2. mul-1-neg68.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{-\left(A + \sqrt{{A}^{2} + {B}^{2}}\right)}}{B}\right)}{\pi} \]
      3. unpow268.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{-\left(A + \sqrt{\color{blue}{A \cdot A} + {B}^{2}}\right)}{B}\right)}{\pi} \]
      4. unpow268.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{-\left(A + \sqrt{A \cdot A + \color{blue}{B \cdot B}}\right)}{B}\right)}{\pi} \]
      5. hypot-define90.9%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{-\left(A + \color{blue}{\mathsf{hypot}\left(A, B\right)}\right)}{B}\right)}{\pi} \]
    5. Simplified90.9%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{-\left(A + \mathsf{hypot}\left(A, B\right)\right)}{B}\right)}}{\pi} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification80.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -1.55 \cdot 10^{-38}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\ \mathbf{elif}\;A \leq 1.9 \cdot 10^{-124}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(A, B\right)}{-B}\right)}{\pi}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 76.0% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;A \leq -1.2 \cdot 10^{-35}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\ \mathbf{elif}\;A \leq 1.02 \cdot 10^{+35}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \end{array} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (if (<= A -1.2e-35)
   (/ (* 180.0 (atan (/ (/ -1.0 A) (- (/ (* C 2.0) (* B A)) (/ 2.0 B))))) PI)
   (if (<= A 1.02e+35)
     (/ 180.0 (/ PI (atan (/ (- C (hypot C B)) B))))
     (* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI)))))
double code(double A, double B, double C) {
	double tmp;
	if (A <= -1.2e-35) {
		tmp = (180.0 * atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / ((double) M_PI);
	} else if (A <= 1.02e+35) {
		tmp = 180.0 / (((double) M_PI) / atan(((C - hypot(C, B)) / B)));
	} else {
		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / ((double) M_PI));
	}
	return tmp;
}
public static double code(double A, double B, double C) {
	double tmp;
	if (A <= -1.2e-35) {
		tmp = (180.0 * Math.atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / Math.PI;
	} else if (A <= 1.02e+35) {
		tmp = 180.0 / (Math.PI / Math.atan(((C - Math.hypot(C, B)) / B)));
	} else {
		tmp = 180.0 * (Math.atan((1.0 + ((C - A) / B))) / Math.PI);
	}
	return tmp;
}
def code(A, B, C):
	tmp = 0
	if A <= -1.2e-35:
		tmp = (180.0 * math.atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / math.pi
	elif A <= 1.02e+35:
		tmp = 180.0 / (math.pi / math.atan(((C - math.hypot(C, B)) / B)))
	else:
		tmp = 180.0 * (math.atan((1.0 + ((C - A) / B))) / math.pi)
	return tmp
function code(A, B, C)
	tmp = 0.0
	if (A <= -1.2e-35)
		tmp = Float64(Float64(180.0 * atan(Float64(Float64(-1.0 / A) / Float64(Float64(Float64(C * 2.0) / Float64(B * A)) - Float64(2.0 / B))))) / pi);
	elseif (A <= 1.02e+35)
		tmp = Float64(180.0 / Float64(pi / atan(Float64(Float64(C - hypot(C, B)) / B))));
	else
		tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(Float64(C - A) / B))) / pi));
	end
	return tmp
end
function tmp_2 = code(A, B, C)
	tmp = 0.0;
	if (A <= -1.2e-35)
		tmp = (180.0 * atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / pi;
	elseif (A <= 1.02e+35)
		tmp = 180.0 / (pi / atan(((C - hypot(C, B)) / B)));
	else
		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / pi);
	end
	tmp_2 = tmp;
end
code[A_, B_, C_] := If[LessEqual[A, -1.2e-35], N[(N[(180.0 * N[ArcTan[N[(N[(-1.0 / A), $MachinePrecision] / N[(N[(N[(C * 2.0), $MachinePrecision] / N[(B * A), $MachinePrecision]), $MachinePrecision] - N[(2.0 / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], If[LessEqual[A, 1.02e+35], N[(180.0 / N[(Pi / N[ArcTan[N[(N[(C - N[Sqrt[C ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;A \leq -1.2 \cdot 10^{-35}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\

\mathbf{elif}\;A \leq 1.02 \cdot 10^{+35}:\\
\;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}}\\

\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if A < -1.2000000000000001e-35

    1. Initial program 29.3%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. associate--l-24.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
      2. +-commutative24.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
      3. unpow224.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
      4. unpow224.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
      5. hypot-undefine36.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
      6. associate-/r/36.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
      7. associate--r+55.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
    4. Applied egg-rr55.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
    5. Taylor expanded in A around -inf 72.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
    6. Step-by-step derivation
      1. associate-*r*72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
      2. mul-1-neg72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
      3. associate-*r/72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
      4. metadata-eval72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
    7. Simplified72.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
    8. Step-by-step derivation
      1. associate-*r/72.6%

        \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}\right)}{\pi}} \]
      2. associate-/r*72.6%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\frac{\frac{1}{-A}}{2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}}\right)}}{\pi} \]
      3. associate-*r/72.6%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(\frac{\frac{1}{-A}}{\color{blue}{\frac{2 \cdot C}{A \cdot B}} - \frac{2}{B}}\right)}{\pi} \]
    9. Applied egg-rr72.6%

      \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\frac{1}{-A}}{\frac{2 \cdot C}{A \cdot B} - \frac{2}{B}}\right)}{\pi}} \]

    if -1.2000000000000001e-35 < A < 1.02000000000000007e35

    1. Initial program 52.0%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutative52.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
      2. associate--l-52.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
      3. +-commutative52.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      4. unpow252.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      5. unpow252.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      6. hypot-undefine82.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      7. div-inv82.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
      8. clear-num82.5%

        \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      9. un-div-inv82.5%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
    4. Applied egg-rr82.5%

      \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
    5. Taylor expanded in A around 0 46.1%

      \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{C - \sqrt{{B}^{2} + {C}^{2}}}}{B}\right)}} \]
    6. Step-by-step derivation
      1. +-commutative46.1%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \sqrt{\color{blue}{{C}^{2} + {B}^{2}}}}{B}\right)}} \]
      2. unpow246.1%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \sqrt{\color{blue}{C \cdot C} + {B}^{2}}}{B}\right)}} \]
      3. unpow246.1%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \sqrt{C \cdot C + \color{blue}{B \cdot B}}}{B}\right)}} \]
      4. hypot-define76.2%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \color{blue}{\mathsf{hypot}\left(C, B\right)}}{B}\right)}} \]
    7. Simplified76.2%

      \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{C - \mathsf{hypot}\left(C, B\right)}}{B}\right)}} \]

    if 1.02000000000000007e35 < A

    1. Initial program 77.1%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Taylor expanded in B around -inf 85.7%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}}{\pi} \]
    4. Step-by-step derivation
      1. associate--l+85.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(1 + \left(\frac{C}{B} - \frac{A}{B}\right)\right)}}{\pi} \]
      2. div-sub89.6%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(1 + \color{blue}{\frac{C - A}{B}}\right)}{\pi} \]
    5. Simplified89.6%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(1 + \frac{C - A}{B}\right)}}{\pi} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification78.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -1.2 \cdot 10^{-35}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\ \mathbf{elif}\;A \leq 1.02 \cdot 10^{+35}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 75.9% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;A \leq -1.35 \cdot 10^{-36}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\ \mathbf{elif}\;A \leq 2.6 \cdot 10^{+34}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \end{array} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (if (<= A -1.35e-36)
   (/ (* 180.0 (atan (/ (/ -1.0 A) (- (/ (* C 2.0) (* B A)) (/ 2.0 B))))) PI)
   (if (<= A 2.6e+34)
     (* 180.0 (/ (atan (/ (- C (hypot C B)) B)) PI))
     (* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI)))))
double code(double A, double B, double C) {
	double tmp;
	if (A <= -1.35e-36) {
		tmp = (180.0 * atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / ((double) M_PI);
	} else if (A <= 2.6e+34) {
		tmp = 180.0 * (atan(((C - hypot(C, B)) / B)) / ((double) M_PI));
	} else {
		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / ((double) M_PI));
	}
	return tmp;
}
public static double code(double A, double B, double C) {
	double tmp;
	if (A <= -1.35e-36) {
		tmp = (180.0 * Math.atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / Math.PI;
	} else if (A <= 2.6e+34) {
		tmp = 180.0 * (Math.atan(((C - Math.hypot(C, B)) / B)) / Math.PI);
	} else {
		tmp = 180.0 * (Math.atan((1.0 + ((C - A) / B))) / Math.PI);
	}
	return tmp;
}
def code(A, B, C):
	tmp = 0
	if A <= -1.35e-36:
		tmp = (180.0 * math.atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / math.pi
	elif A <= 2.6e+34:
		tmp = 180.0 * (math.atan(((C - math.hypot(C, B)) / B)) / math.pi)
	else:
		tmp = 180.0 * (math.atan((1.0 + ((C - A) / B))) / math.pi)
	return tmp
function code(A, B, C)
	tmp = 0.0
	if (A <= -1.35e-36)
		tmp = Float64(Float64(180.0 * atan(Float64(Float64(-1.0 / A) / Float64(Float64(Float64(C * 2.0) / Float64(B * A)) - Float64(2.0 / B))))) / pi);
	elseif (A <= 2.6e+34)
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(C - hypot(C, B)) / B)) / pi));
	else
		tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(Float64(C - A) / B))) / pi));
	end
	return tmp
end
function tmp_2 = code(A, B, C)
	tmp = 0.0;
	if (A <= -1.35e-36)
		tmp = (180.0 * atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / pi;
	elseif (A <= 2.6e+34)
		tmp = 180.0 * (atan(((C - hypot(C, B)) / B)) / pi);
	else
		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / pi);
	end
	tmp_2 = tmp;
end
code[A_, B_, C_] := If[LessEqual[A, -1.35e-36], N[(N[(180.0 * N[ArcTan[N[(N[(-1.0 / A), $MachinePrecision] / N[(N[(N[(C * 2.0), $MachinePrecision] / N[(B * A), $MachinePrecision]), $MachinePrecision] - N[(2.0 / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], If[LessEqual[A, 2.6e+34], N[(180.0 * N[(N[ArcTan[N[(N[(C - N[Sqrt[C ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;A \leq -1.35 \cdot 10^{-36}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\

\mathbf{elif}\;A \leq 2.6 \cdot 10^{+34}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}{\pi}\\

\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if A < -1.35000000000000004e-36

    1. Initial program 29.3%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. associate--l-24.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
      2. +-commutative24.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
      3. unpow224.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
      4. unpow224.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
      5. hypot-undefine36.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
      6. associate-/r/36.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
      7. associate--r+55.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
    4. Applied egg-rr55.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
    5. Taylor expanded in A around -inf 72.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
    6. Step-by-step derivation
      1. associate-*r*72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
      2. mul-1-neg72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
      3. associate-*r/72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
      4. metadata-eval72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
    7. Simplified72.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
    8. Step-by-step derivation
      1. associate-*r/72.6%

        \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}\right)}{\pi}} \]
      2. associate-/r*72.6%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\frac{\frac{1}{-A}}{2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}}\right)}}{\pi} \]
      3. associate-*r/72.6%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(\frac{\frac{1}{-A}}{\color{blue}{\frac{2 \cdot C}{A \cdot B}} - \frac{2}{B}}\right)}{\pi} \]
    9. Applied egg-rr72.6%

      \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\frac{1}{-A}}{\frac{2 \cdot C}{A \cdot B} - \frac{2}{B}}\right)}{\pi}} \]

    if -1.35000000000000004e-36 < A < 2.59999999999999997e34

    1. Initial program 52.0%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Taylor expanded in A around 0 46.1%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \sqrt{{B}^{2} + {C}^{2}}}{B}\right)}}{\pi} \]
    4. Step-by-step derivation
      1. +-commutative46.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{C - \sqrt{\color{blue}{{C}^{2} + {B}^{2}}}}{B}\right)}{\pi} \]
      2. unpow246.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{C - \sqrt{\color{blue}{C \cdot C} + {B}^{2}}}{B}\right)}{\pi} \]
      3. unpow246.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{C - \sqrt{C \cdot C + \color{blue}{B \cdot B}}}{B}\right)}{\pi} \]
      4. hypot-define76.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{C - \color{blue}{\mathsf{hypot}\left(C, B\right)}}{B}\right)}{\pi} \]
    5. Simplified76.2%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}}{\pi} \]

    if 2.59999999999999997e34 < A

    1. Initial program 77.1%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Taylor expanded in B around -inf 85.7%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}}{\pi} \]
    4. Step-by-step derivation
      1. associate--l+85.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(1 + \left(\frac{C}{B} - \frac{A}{B}\right)\right)}}{\pi} \]
      2. div-sub89.6%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(1 + \color{blue}{\frac{C - A}{B}}\right)}{\pi} \]
    5. Simplified89.6%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(1 + \frac{C - A}{B}\right)}}{\pi} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification78.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -1.35 \cdot 10^{-36}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\ \mathbf{elif}\;A \leq 2.6 \cdot 10^{+34}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 81.2% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;A \leq -1.35 \cdot 10^{-36}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}\\ \end{array} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (if (<= A -1.35e-36)
   (/ (* 180.0 (atan (/ (/ -1.0 A) (- (/ (* C 2.0) (* B A)) (/ 2.0 B))))) PI)
   (/ 180.0 (/ PI (atan (/ (- (- C A) (hypot B (- A C))) B))))))
double code(double A, double B, double C) {
	double tmp;
	if (A <= -1.35e-36) {
		tmp = (180.0 * atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / ((double) M_PI);
	} else {
		tmp = 180.0 / (((double) M_PI) / atan((((C - A) - hypot(B, (A - C))) / B)));
	}
	return tmp;
}
public static double code(double A, double B, double C) {
	double tmp;
	if (A <= -1.35e-36) {
		tmp = (180.0 * Math.atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / Math.PI;
	} else {
		tmp = 180.0 / (Math.PI / Math.atan((((C - A) - Math.hypot(B, (A - C))) / B)));
	}
	return tmp;
}
def code(A, B, C):
	tmp = 0
	if A <= -1.35e-36:
		tmp = (180.0 * math.atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / math.pi
	else:
		tmp = 180.0 / (math.pi / math.atan((((C - A) - math.hypot(B, (A - C))) / B)))
	return tmp
function code(A, B, C)
	tmp = 0.0
	if (A <= -1.35e-36)
		tmp = Float64(Float64(180.0 * atan(Float64(Float64(-1.0 / A) / Float64(Float64(Float64(C * 2.0) / Float64(B * A)) - Float64(2.0 / B))))) / pi);
	else
		tmp = Float64(180.0 / Float64(pi / atan(Float64(Float64(Float64(C - A) - hypot(B, Float64(A - C))) / B))));
	end
	return tmp
end
function tmp_2 = code(A, B, C)
	tmp = 0.0;
	if (A <= -1.35e-36)
		tmp = (180.0 * atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / pi;
	else
		tmp = 180.0 / (pi / atan((((C - A) - hypot(B, (A - C))) / B)));
	end
	tmp_2 = tmp;
end
code[A_, B_, C_] := If[LessEqual[A, -1.35e-36], N[(N[(180.0 * N[ArcTan[N[(N[(-1.0 / A), $MachinePrecision] / N[(N[(N[(C * 2.0), $MachinePrecision] / N[(B * A), $MachinePrecision]), $MachinePrecision] - N[(2.0 / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], N[(180.0 / N[(Pi / N[ArcTan[N[(N[(N[(C - A), $MachinePrecision] - N[Sqrt[B ^ 2 + N[(A - C), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;A \leq -1.35 \cdot 10^{-36}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\

\mathbf{else}:\\
\;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if A < -1.35000000000000004e-36

    1. Initial program 29.3%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. associate--l-24.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
      2. +-commutative24.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
      3. unpow224.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
      4. unpow224.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
      5. hypot-undefine36.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
      6. associate-/r/36.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
      7. associate--r+55.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
    4. Applied egg-rr55.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
    5. Taylor expanded in A around -inf 72.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
    6. Step-by-step derivation
      1. associate-*r*72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
      2. mul-1-neg72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
      3. associate-*r/72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
      4. metadata-eval72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
    7. Simplified72.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
    8. Step-by-step derivation
      1. associate-*r/72.6%

        \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}\right)}{\pi}} \]
      2. associate-/r*72.6%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\frac{\frac{1}{-A}}{2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}}\right)}}{\pi} \]
      3. associate-*r/72.6%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(\frac{\frac{1}{-A}}{\color{blue}{\frac{2 \cdot C}{A \cdot B}} - \frac{2}{B}}\right)}{\pi} \]
    9. Applied egg-rr72.6%

      \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\frac{1}{-A}}{\frac{2 \cdot C}{A \cdot B} - \frac{2}{B}}\right)}{\pi}} \]

    if -1.35000000000000004e-36 < A

    1. Initial program 58.7%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutative58.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
      2. associate--l-58.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
      3. +-commutative58.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      4. unpow258.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      5. unpow258.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      6. hypot-undefine86.6%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
      7. div-inv86.6%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
      8. clear-num86.6%

        \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      9. un-div-inv86.6%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
    4. Applied egg-rr86.6%

      \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification83.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -1.35 \cdot 10^{-36}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 81.2% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;A \leq -1.2 \cdot 10^{-35}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}{\pi}\\ \end{array} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (if (<= A -1.2e-35)
   (/ (* 180.0 (atan (/ (/ -1.0 A) (- (/ (* C 2.0) (* B A)) (/ 2.0 B))))) PI)
   (* 180.0 (/ (atan (/ (- C (+ A (hypot B (- A C)))) B)) PI))))
double code(double A, double B, double C) {
	double tmp;
	if (A <= -1.2e-35) {
		tmp = (180.0 * atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / ((double) M_PI);
	} else {
		tmp = 180.0 * (atan(((C - (A + hypot(B, (A - C)))) / B)) / ((double) M_PI));
	}
	return tmp;
}
public static double code(double A, double B, double C) {
	double tmp;
	if (A <= -1.2e-35) {
		tmp = (180.0 * Math.atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / Math.PI;
	} else {
		tmp = 180.0 * (Math.atan(((C - (A + Math.hypot(B, (A - C)))) / B)) / Math.PI);
	}
	return tmp;
}
def code(A, B, C):
	tmp = 0
	if A <= -1.2e-35:
		tmp = (180.0 * math.atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / math.pi
	else:
		tmp = 180.0 * (math.atan(((C - (A + math.hypot(B, (A - C)))) / B)) / math.pi)
	return tmp
function code(A, B, C)
	tmp = 0.0
	if (A <= -1.2e-35)
		tmp = Float64(Float64(180.0 * atan(Float64(Float64(-1.0 / A) / Float64(Float64(Float64(C * 2.0) / Float64(B * A)) - Float64(2.0 / B))))) / pi);
	else
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(C - Float64(A + hypot(B, Float64(A - C)))) / B)) / pi));
	end
	return tmp
end
function tmp_2 = code(A, B, C)
	tmp = 0.0;
	if (A <= -1.2e-35)
		tmp = (180.0 * atan(((-1.0 / A) / (((C * 2.0) / (B * A)) - (2.0 / B))))) / pi;
	else
		tmp = 180.0 * (atan(((C - (A + hypot(B, (A - C)))) / B)) / pi);
	end
	tmp_2 = tmp;
end
code[A_, B_, C_] := If[LessEqual[A, -1.2e-35], N[(N[(180.0 * N[ArcTan[N[(N[(-1.0 / A), $MachinePrecision] / N[(N[(N[(C * 2.0), $MachinePrecision] / N[(B * A), $MachinePrecision]), $MachinePrecision] - N[(2.0 / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(C - N[(A + N[Sqrt[B ^ 2 + N[(A - C), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;A \leq -1.2 \cdot 10^{-35}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\

\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}{\pi}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if A < -1.2000000000000001e-35

    1. Initial program 29.3%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. associate--l-24.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
      2. +-commutative24.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
      3. unpow224.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
      4. unpow224.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
      5. hypot-undefine36.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
      6. associate-/r/36.0%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
      7. associate--r+55.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
    4. Applied egg-rr55.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
    5. Taylor expanded in A around -inf 72.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
    6. Step-by-step derivation
      1. associate-*r*72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
      2. mul-1-neg72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
      3. associate-*r/72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
      4. metadata-eval72.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
    7. Simplified72.5%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
    8. Step-by-step derivation
      1. associate-*r/72.6%

        \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}\right)}{\pi}} \]
      2. associate-/r*72.6%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\frac{\frac{1}{-A}}{2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}}\right)}}{\pi} \]
      3. associate-*r/72.6%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(\frac{\frac{1}{-A}}{\color{blue}{\frac{2 \cdot C}{A \cdot B}} - \frac{2}{B}}\right)}{\pi} \]
    9. Applied egg-rr72.6%

      \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\frac{1}{-A}}{\frac{2 \cdot C}{A \cdot B} - \frac{2}{B}}\right)}{\pi}} \]

    if -1.2000000000000001e-35 < A

    1. Initial program 58.7%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Step-by-step derivation
      1. Simplified86.6%

        \[\leadsto \color{blue}{180 \cdot \frac{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}{\pi}} \]
      2. Add Preprocessing
    3. Recombined 2 regimes into one program.
    4. Final simplification83.1%

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -1.2 \cdot 10^{-35}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\frac{-1}{A}}{\frac{C \cdot 2}{B \cdot A} - \frac{2}{B}}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}{\pi}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 7: 64.9% accurate, 3.3× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -1.72 \cdot 10^{-301}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B \cdot \left(\frac{C - A}{B} - -1\right)}{B}\right)}}\\ \mathbf{elif}\;B \leq 6.5 \cdot 10^{-185}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \frac{C \cdot -2}{A}\right)}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B \cdot \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{B}\right)}}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B -1.72e-301)
       (/ 180.0 (/ PI (atan (/ (* B (- (/ (- C A) B) -1.0)) B))))
       (if (<= B 6.5e-185)
         (* 180.0 (/ (atan (/ B (* A (+ 2.0 (/ (* C -2.0) A))))) PI))
         (/ 180.0 (/ PI (atan (/ (* B (+ (/ C B) (- -1.0 (/ A B)))) B)))))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -1.72e-301) {
    		tmp = 180.0 / (((double) M_PI) / atan(((B * (((C - A) / B) - -1.0)) / B)));
    	} else if (B <= 6.5e-185) {
    		tmp = 180.0 * (atan((B / (A * (2.0 + ((C * -2.0) / A))))) / ((double) M_PI));
    	} else {
    		tmp = 180.0 / (((double) M_PI) / atan(((B * ((C / B) + (-1.0 - (A / B)))) / B)));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -1.72e-301) {
    		tmp = 180.0 / (Math.PI / Math.atan(((B * (((C - A) / B) - -1.0)) / B)));
    	} else if (B <= 6.5e-185) {
    		tmp = 180.0 * (Math.atan((B / (A * (2.0 + ((C * -2.0) / A))))) / Math.PI);
    	} else {
    		tmp = 180.0 / (Math.PI / Math.atan(((B * ((C / B) + (-1.0 - (A / B)))) / B)));
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= -1.72e-301:
    		tmp = 180.0 / (math.pi / math.atan(((B * (((C - A) / B) - -1.0)) / B)))
    	elif B <= 6.5e-185:
    		tmp = 180.0 * (math.atan((B / (A * (2.0 + ((C * -2.0) / A))))) / math.pi)
    	else:
    		tmp = 180.0 / (math.pi / math.atan(((B * ((C / B) + (-1.0 - (A / B)))) / B)))
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= -1.72e-301)
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(Float64(B * Float64(Float64(Float64(C - A) / B) - -1.0)) / B))));
    	elseif (B <= 6.5e-185)
    		tmp = Float64(180.0 * Float64(atan(Float64(B / Float64(A * Float64(2.0 + Float64(Float64(C * -2.0) / A))))) / pi));
    	else
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(Float64(B * Float64(Float64(C / B) + Float64(-1.0 - Float64(A / B)))) / B))));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= -1.72e-301)
    		tmp = 180.0 / (pi / atan(((B * (((C - A) / B) - -1.0)) / B)));
    	elseif (B <= 6.5e-185)
    		tmp = 180.0 * (atan((B / (A * (2.0 + ((C * -2.0) / A))))) / pi);
    	else
    		tmp = 180.0 / (pi / atan(((B * ((C / B) + (-1.0 - (A / B)))) / B)));
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, -1.72e-301], N[(180.0 / N[(Pi / N[ArcTan[N[(N[(B * N[(N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision] - -1.0), $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 6.5e-185], N[(180.0 * N[(N[ArcTan[N[(B / N[(A * N[(2.0 + N[(N[(C * -2.0), $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 / N[(Pi / N[ArcTan[N[(N[(B * N[(N[(C / B), $MachinePrecision] + N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq -1.72 \cdot 10^{-301}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B \cdot \left(\frac{C - A}{B} - -1\right)}{B}\right)}}\\
    
    \mathbf{elif}\;B \leq 6.5 \cdot 10^{-185}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \frac{C \cdot -2}{A}\right)}\right)}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B \cdot \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{B}\right)}}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if B < -1.72000000000000008e-301

      1. Initial program 52.4%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative52.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-52.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative52.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow252.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow252.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine73.6%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv73.6%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num73.6%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv73.6%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr76.7%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around -inf 70.0%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{-1 \cdot \left(B \cdot \left(-1 \cdot \frac{C - A}{B} - 1\right)\right)}}{B}\right)}} \]
      6. Step-by-step derivation
        1. mul-1-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{-B \cdot \left(-1 \cdot \frac{C - A}{B} - 1\right)}}{B}\right)}} \]
        2. *-commutative70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{-\color{blue}{\left(-1 \cdot \frac{C - A}{B} - 1\right) \cdot B}}{B}\right)}} \]
        3. distribute-rgt-neg-in70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{\left(-1 \cdot \frac{C - A}{B} - 1\right) \cdot \left(-B\right)}}{B}\right)}} \]
        4. sub-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{\left(-1 \cdot \frac{C - A}{B} + \left(-1\right)\right)} \cdot \left(-B\right)}{B}\right)}} \]
        5. associate-*r/70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\color{blue}{\frac{-1 \cdot \left(C - A\right)}{B}} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        6. mul-1-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{\color{blue}{-\left(C - A\right)}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        7. sub-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{-\color{blue}{\left(C + \left(-A\right)\right)}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        8. distribute-neg-in70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{\color{blue}{\left(-C\right) + \left(-\left(-A\right)\right)}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        9. remove-double-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{\left(-C\right) + \color{blue}{A}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        10. +-commutative70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{\color{blue}{A + \left(-C\right)}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        11. sub-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{\color{blue}{A - C}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        12. metadata-eval70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{A - C}{B} + \color{blue}{-1}\right) \cdot \left(-B\right)}{B}\right)}} \]
      7. Simplified70.0%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{\left(\frac{A - C}{B} + -1\right) \cdot \left(-B\right)}}{B}\right)}} \]

      if -1.72000000000000008e-301 < B < 6.49999999999999946e-185

      1. Initial program 60.1%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. associate--l-47.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
        2. +-commutative47.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
        3. unpow247.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
        4. unpow247.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
        5. hypot-undefine55.0%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
        6. associate-/r/55.0%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
        7. associate--r+79.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
      4. Applied egg-rr79.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
      5. Taylor expanded in A around -inf 47.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
      6. Step-by-step derivation
        1. associate-*r*47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
        2. mul-1-neg47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
        3. associate-*r/47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
        4. metadata-eval47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
      7. Simplified47.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
      8. Taylor expanded in B around -inf 61.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{B}{A \cdot \left(2 + -2 \cdot \frac{C}{A}\right)}\right)}}{\pi} \]
      9. Step-by-step derivation
        1. associate-*r/61.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \color{blue}{\frac{-2 \cdot C}{A}}\right)}\right)}{\pi} \]
      10. Simplified61.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{B}{A \cdot \left(2 + \frac{-2 \cdot C}{A}\right)}\right)}}{\pi} \]

      if 6.49999999999999946e-185 < B

      1. Initial program 47.6%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative47.6%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-47.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative47.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow247.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow247.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine78.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv78.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num78.4%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv78.4%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr81.2%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around inf 72.3%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{B \cdot \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{B}\right)}} \]
    3. Recombined 3 regimes into one program.
    4. Final simplification70.0%

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -1.72 \cdot 10^{-301}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B \cdot \left(\frac{C - A}{B} - -1\right)}{B}\right)}}\\ \mathbf{elif}\;B \leq 6.5 \cdot 10^{-185}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \frac{C \cdot -2}{A}\right)}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B \cdot \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{B}\right)}}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 8: 64.9% accurate, 3.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -6.4 \cdot 10^{-304}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B \cdot \left(\frac{C - A}{B} - -1\right)}{B}\right)}}\\ \mathbf{elif}\;B \leq 8 \cdot 10^{-187}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \frac{C \cdot -2}{A}\right)}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B -6.4e-304)
       (/ 180.0 (/ PI (atan (/ (* B (- (/ (- C A) B) -1.0)) B))))
       (if (<= B 8e-187)
         (* 180.0 (/ (atan (/ B (* A (+ 2.0 (/ (* C -2.0) A))))) PI))
         (* 180.0 (/ (atan (+ (/ C B) (- -1.0 (/ A B)))) PI)))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -6.4e-304) {
    		tmp = 180.0 / (((double) M_PI) / atan(((B * (((C - A) / B) - -1.0)) / B)));
    	} else if (B <= 8e-187) {
    		tmp = 180.0 * (atan((B / (A * (2.0 + ((C * -2.0) / A))))) / ((double) M_PI));
    	} else {
    		tmp = 180.0 * (atan(((C / B) + (-1.0 - (A / B)))) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -6.4e-304) {
    		tmp = 180.0 / (Math.PI / Math.atan(((B * (((C - A) / B) - -1.0)) / B)));
    	} else if (B <= 8e-187) {
    		tmp = 180.0 * (Math.atan((B / (A * (2.0 + ((C * -2.0) / A))))) / Math.PI);
    	} else {
    		tmp = 180.0 * (Math.atan(((C / B) + (-1.0 - (A / B)))) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= -6.4e-304:
    		tmp = 180.0 / (math.pi / math.atan(((B * (((C - A) / B) - -1.0)) / B)))
    	elif B <= 8e-187:
    		tmp = 180.0 * (math.atan((B / (A * (2.0 + ((C * -2.0) / A))))) / math.pi)
    	else:
    		tmp = 180.0 * (math.atan(((C / B) + (-1.0 - (A / B)))) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= -6.4e-304)
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(Float64(B * Float64(Float64(Float64(C - A) / B) - -1.0)) / B))));
    	elseif (B <= 8e-187)
    		tmp = Float64(180.0 * Float64(atan(Float64(B / Float64(A * Float64(2.0 + Float64(Float64(C * -2.0) / A))))) / pi));
    	else
    		tmp = Float64(180.0 * Float64(atan(Float64(Float64(C / B) + Float64(-1.0 - Float64(A / B)))) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= -6.4e-304)
    		tmp = 180.0 / (pi / atan(((B * (((C - A) / B) - -1.0)) / B)));
    	elseif (B <= 8e-187)
    		tmp = 180.0 * (atan((B / (A * (2.0 + ((C * -2.0) / A))))) / pi);
    	else
    		tmp = 180.0 * (atan(((C / B) + (-1.0 - (A / B)))) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, -6.4e-304], N[(180.0 / N[(Pi / N[ArcTan[N[(N[(B * N[(N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision] - -1.0), $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 8e-187], N[(180.0 * N[(N[ArcTan[N[(B / N[(A * N[(2.0 + N[(N[(C * -2.0), $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(C / B), $MachinePrecision] + N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq -6.4 \cdot 10^{-304}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B \cdot \left(\frac{C - A}{B} - -1\right)}{B}\right)}}\\
    
    \mathbf{elif}\;B \leq 8 \cdot 10^{-187}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \frac{C \cdot -2}{A}\right)}\right)}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if B < -6.39999999999999998e-304

      1. Initial program 52.4%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative52.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-52.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative52.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow252.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow252.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine73.6%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv73.6%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num73.6%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv73.6%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr76.7%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around -inf 70.0%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{-1 \cdot \left(B \cdot \left(-1 \cdot \frac{C - A}{B} - 1\right)\right)}}{B}\right)}} \]
      6. Step-by-step derivation
        1. mul-1-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{-B \cdot \left(-1 \cdot \frac{C - A}{B} - 1\right)}}{B}\right)}} \]
        2. *-commutative70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{-\color{blue}{\left(-1 \cdot \frac{C - A}{B} - 1\right) \cdot B}}{B}\right)}} \]
        3. distribute-rgt-neg-in70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{\left(-1 \cdot \frac{C - A}{B} - 1\right) \cdot \left(-B\right)}}{B}\right)}} \]
        4. sub-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{\left(-1 \cdot \frac{C - A}{B} + \left(-1\right)\right)} \cdot \left(-B\right)}{B}\right)}} \]
        5. associate-*r/70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\color{blue}{\frac{-1 \cdot \left(C - A\right)}{B}} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        6. mul-1-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{\color{blue}{-\left(C - A\right)}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        7. sub-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{-\color{blue}{\left(C + \left(-A\right)\right)}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        8. distribute-neg-in70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{\color{blue}{\left(-C\right) + \left(-\left(-A\right)\right)}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        9. remove-double-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{\left(-C\right) + \color{blue}{A}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        10. +-commutative70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{\color{blue}{A + \left(-C\right)}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        11. sub-neg70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{\color{blue}{A - C}}{B} + \left(-1\right)\right) \cdot \left(-B\right)}{B}\right)}} \]
        12. metadata-eval70.0%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(\frac{A - C}{B} + \color{blue}{-1}\right) \cdot \left(-B\right)}{B}\right)}} \]
      7. Simplified70.0%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{\left(\frac{A - C}{B} + -1\right) \cdot \left(-B\right)}}{B}\right)}} \]

      if -6.39999999999999998e-304 < B < 8.0000000000000001e-187

      1. Initial program 60.1%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. associate--l-47.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
        2. +-commutative47.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
        3. unpow247.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
        4. unpow247.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
        5. hypot-undefine55.0%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
        6. associate-/r/55.0%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
        7. associate--r+79.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
      4. Applied egg-rr79.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
      5. Taylor expanded in A around -inf 47.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
      6. Step-by-step derivation
        1. associate-*r*47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
        2. mul-1-neg47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
        3. associate-*r/47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
        4. metadata-eval47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
      7. Simplified47.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
      8. Taylor expanded in B around -inf 61.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{B}{A \cdot \left(2 + -2 \cdot \frac{C}{A}\right)}\right)}}{\pi} \]
      9. Step-by-step derivation
        1. associate-*r/61.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \color{blue}{\frac{-2 \cdot C}{A}}\right)}\right)}{\pi} \]
      10. Simplified61.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{B}{A \cdot \left(2 + \frac{-2 \cdot C}{A}\right)}\right)}}{\pi} \]

      if 8.0000000000000001e-187 < B

      1. Initial program 47.6%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around inf 72.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{\pi} \]
    3. Recombined 3 regimes into one program.
    4. Final simplification70.0%

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -6.4 \cdot 10^{-304}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B \cdot \left(\frac{C - A}{B} - -1\right)}{B}\right)}}\\ \mathbf{elif}\;B \leq 8 \cdot 10^{-187}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \frac{C \cdot -2}{A}\right)}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 9: 65.0% accurate, 3.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -1.5 \cdot 10^{-302}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 3.6 \cdot 10^{-187}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \frac{C \cdot -2}{A}\right)}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B -1.5e-302)
       (* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI))
       (if (<= B 3.6e-187)
         (* 180.0 (/ (atan (/ B (* A (+ 2.0 (/ (* C -2.0) A))))) PI))
         (* 180.0 (/ (atan (+ (/ C B) (- -1.0 (/ A B)))) PI)))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -1.5e-302) {
    		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / ((double) M_PI));
    	} else if (B <= 3.6e-187) {
    		tmp = 180.0 * (atan((B / (A * (2.0 + ((C * -2.0) / A))))) / ((double) M_PI));
    	} else {
    		tmp = 180.0 * (atan(((C / B) + (-1.0 - (A / B)))) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -1.5e-302) {
    		tmp = 180.0 * (Math.atan((1.0 + ((C - A) / B))) / Math.PI);
    	} else if (B <= 3.6e-187) {
    		tmp = 180.0 * (Math.atan((B / (A * (2.0 + ((C * -2.0) / A))))) / Math.PI);
    	} else {
    		tmp = 180.0 * (Math.atan(((C / B) + (-1.0 - (A / B)))) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= -1.5e-302:
    		tmp = 180.0 * (math.atan((1.0 + ((C - A) / B))) / math.pi)
    	elif B <= 3.6e-187:
    		tmp = 180.0 * (math.atan((B / (A * (2.0 + ((C * -2.0) / A))))) / math.pi)
    	else:
    		tmp = 180.0 * (math.atan(((C / B) + (-1.0 - (A / B)))) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= -1.5e-302)
    		tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(Float64(C - A) / B))) / pi));
    	elseif (B <= 3.6e-187)
    		tmp = Float64(180.0 * Float64(atan(Float64(B / Float64(A * Float64(2.0 + Float64(Float64(C * -2.0) / A))))) / pi));
    	else
    		tmp = Float64(180.0 * Float64(atan(Float64(Float64(C / B) + Float64(-1.0 - Float64(A / B)))) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= -1.5e-302)
    		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / pi);
    	elseif (B <= 3.6e-187)
    		tmp = 180.0 * (atan((B / (A * (2.0 + ((C * -2.0) / A))))) / pi);
    	else
    		tmp = 180.0 * (atan(((C / B) + (-1.0 - (A / B)))) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, -1.5e-302], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 3.6e-187], N[(180.0 * N[(N[ArcTan[N[(B / N[(A * N[(2.0 + N[(N[(C * -2.0), $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(C / B), $MachinePrecision] + N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq -1.5 \cdot 10^{-302}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
    
    \mathbf{elif}\;B \leq 3.6 \cdot 10^{-187}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \frac{C \cdot -2}{A}\right)}\right)}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if B < -1.49999999999999994e-302

      1. Initial program 52.4%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around -inf 68.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}}{\pi} \]
      4. Step-by-step derivation
        1. associate--l+68.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(1 + \left(\frac{C}{B} - \frac{A}{B}\right)\right)}}{\pi} \]
        2. div-sub69.9%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(1 + \color{blue}{\frac{C - A}{B}}\right)}{\pi} \]
      5. Simplified69.9%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(1 + \frac{C - A}{B}\right)}}{\pi} \]

      if -1.49999999999999994e-302 < B < 3.59999999999999994e-187

      1. Initial program 60.1%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. associate--l-47.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
        2. +-commutative47.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
        3. unpow247.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
        4. unpow247.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
        5. hypot-undefine55.0%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
        6. associate-/r/55.0%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
        7. associate--r+79.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
      4. Applied egg-rr79.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
      5. Taylor expanded in A around -inf 47.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
      6. Step-by-step derivation
        1. associate-*r*47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
        2. mul-1-neg47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
        3. associate-*r/47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
        4. metadata-eval47.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
      7. Simplified47.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
      8. Taylor expanded in B around -inf 61.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{B}{A \cdot \left(2 + -2 \cdot \frac{C}{A}\right)}\right)}}{\pi} \]
      9. Step-by-step derivation
        1. associate-*r/61.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \color{blue}{\frac{-2 \cdot C}{A}}\right)}\right)}{\pi} \]
      10. Simplified61.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{B}{A \cdot \left(2 + \frac{-2 \cdot C}{A}\right)}\right)}}{\pi} \]

      if 3.59999999999999994e-187 < B

      1. Initial program 47.6%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around inf 72.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{\pi} \]
    3. Recombined 3 regimes into one program.
    4. Final simplification70.0%

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -1.5 \cdot 10^{-302}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 3.6 \cdot 10^{-187}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A \cdot \left(2 + \frac{C \cdot -2}{A}\right)}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 10: 46.4% accurate, 3.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -9.2 \cdot 10^{+21}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq -7.2 \cdot 10^{-166}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\ \mathbf{elif}\;B \leq 3.5 \cdot 10^{+44}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{-A}{B}\right)}}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B -9.2e+21)
       (* 180.0 (/ (atan 1.0) PI))
       (if (<= B -7.2e-166)
         (* 180.0 (/ (atan (/ (* B 0.5) A)) PI))
         (if (<= B 3.5e+44)
           (/ 180.0 (/ PI (atan (/ (- A) B))))
           (* 180.0 (/ (atan -1.0) PI))))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -9.2e+21) {
    		tmp = 180.0 * (atan(1.0) / ((double) M_PI));
    	} else if (B <= -7.2e-166) {
    		tmp = 180.0 * (atan(((B * 0.5) / A)) / ((double) M_PI));
    	} else if (B <= 3.5e+44) {
    		tmp = 180.0 / (((double) M_PI) / atan((-A / B)));
    	} else {
    		tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -9.2e+21) {
    		tmp = 180.0 * (Math.atan(1.0) / Math.PI);
    	} else if (B <= -7.2e-166) {
    		tmp = 180.0 * (Math.atan(((B * 0.5) / A)) / Math.PI);
    	} else if (B <= 3.5e+44) {
    		tmp = 180.0 / (Math.PI / Math.atan((-A / B)));
    	} else {
    		tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= -9.2e+21:
    		tmp = 180.0 * (math.atan(1.0) / math.pi)
    	elif B <= -7.2e-166:
    		tmp = 180.0 * (math.atan(((B * 0.5) / A)) / math.pi)
    	elif B <= 3.5e+44:
    		tmp = 180.0 / (math.pi / math.atan((-A / B)))
    	else:
    		tmp = 180.0 * (math.atan(-1.0) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= -9.2e+21)
    		tmp = Float64(180.0 * Float64(atan(1.0) / pi));
    	elseif (B <= -7.2e-166)
    		tmp = Float64(180.0 * Float64(atan(Float64(Float64(B * 0.5) / A)) / pi));
    	elseif (B <= 3.5e+44)
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(Float64(-A) / B))));
    	else
    		tmp = Float64(180.0 * Float64(atan(-1.0) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= -9.2e+21)
    		tmp = 180.0 * (atan(1.0) / pi);
    	elseif (B <= -7.2e-166)
    		tmp = 180.0 * (atan(((B * 0.5) / A)) / pi);
    	elseif (B <= 3.5e+44)
    		tmp = 180.0 / (pi / atan((-A / B)));
    	else
    		tmp = 180.0 * (atan(-1.0) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, -9.2e+21], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, -7.2e-166], N[(180.0 * N[(N[ArcTan[N[(N[(B * 0.5), $MachinePrecision] / A), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 3.5e+44], N[(180.0 / N[(Pi / N[ArcTan[N[((-A) / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq -9.2 \cdot 10^{+21}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
    
    \mathbf{elif}\;B \leq -7.2 \cdot 10^{-166}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\
    
    \mathbf{elif}\;B \leq 3.5 \cdot 10^{+44}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{-A}{B}\right)}}\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 4 regimes
    2. if B < -9.2e21

      1. Initial program 49.9%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around -inf 68.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{1}}{\pi} \]

      if -9.2e21 < B < -7.2000000000000002e-166

      1. Initial program 46.9%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in A around -inf 48.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(0.5 \cdot \frac{B}{A}\right)}}{\pi} \]
      4. Step-by-step derivation
        1. associate-*r/48.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{0.5 \cdot B}{A}\right)}}{\pi} \]
      5. Simplified48.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{0.5 \cdot B}{A}\right)}}{\pi} \]

      if -7.2000000000000002e-166 < B < 3.4999999999999999e44

      1. Initial program 60.4%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative60.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-57.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative57.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow257.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow257.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine65.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv65.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num65.7%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv65.7%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr75.1%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around inf 53.1%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{B \cdot \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{B}\right)}} \]
      6. Taylor expanded in A around inf 41.3%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-1 \cdot \frac{A}{B}\right)}}} \]
      7. Step-by-step derivation
        1. associate-*r/41.3%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\frac{-1 \cdot A}{B}\right)}}} \]
        2. mul-1-neg41.3%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{-A}}{B}\right)}} \]
      8. Simplified41.3%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\frac{-A}{B}\right)}}} \]

      if 3.4999999999999999e44 < B

      1. Initial program 38.1%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around inf 73.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{-1}}{\pi} \]
    3. Recombined 4 regimes into one program.
    4. Final simplification56.1%

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -9.2 \cdot 10^{+21}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq -7.2 \cdot 10^{-166}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\ \mathbf{elif}\;B \leq 3.5 \cdot 10^{+44}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{-A}{B}\right)}}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 11: 46.5% accurate, 3.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -1.55 \cdot 10^{+22}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq -3.4 \cdot 10^{-166}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(B \cdot \frac{0.5}{A}\right)}{\pi}\\ \mathbf{elif}\;B \leq 1.32 \cdot 10^{+39}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{-A}{B}\right)}}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B -1.55e+22)
       (* 180.0 (/ (atan 1.0) PI))
       (if (<= B -3.4e-166)
         (* 180.0 (/ (atan (* B (/ 0.5 A))) PI))
         (if (<= B 1.32e+39)
           (/ 180.0 (/ PI (atan (/ (- A) B))))
           (* 180.0 (/ (atan -1.0) PI))))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -1.55e+22) {
    		tmp = 180.0 * (atan(1.0) / ((double) M_PI));
    	} else if (B <= -3.4e-166) {
    		tmp = 180.0 * (atan((B * (0.5 / A))) / ((double) M_PI));
    	} else if (B <= 1.32e+39) {
    		tmp = 180.0 / (((double) M_PI) / atan((-A / B)));
    	} else {
    		tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -1.55e+22) {
    		tmp = 180.0 * (Math.atan(1.0) / Math.PI);
    	} else if (B <= -3.4e-166) {
    		tmp = 180.0 * (Math.atan((B * (0.5 / A))) / Math.PI);
    	} else if (B <= 1.32e+39) {
    		tmp = 180.0 / (Math.PI / Math.atan((-A / B)));
    	} else {
    		tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= -1.55e+22:
    		tmp = 180.0 * (math.atan(1.0) / math.pi)
    	elif B <= -3.4e-166:
    		tmp = 180.0 * (math.atan((B * (0.5 / A))) / math.pi)
    	elif B <= 1.32e+39:
    		tmp = 180.0 / (math.pi / math.atan((-A / B)))
    	else:
    		tmp = 180.0 * (math.atan(-1.0) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= -1.55e+22)
    		tmp = Float64(180.0 * Float64(atan(1.0) / pi));
    	elseif (B <= -3.4e-166)
    		tmp = Float64(180.0 * Float64(atan(Float64(B * Float64(0.5 / A))) / pi));
    	elseif (B <= 1.32e+39)
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(Float64(-A) / B))));
    	else
    		tmp = Float64(180.0 * Float64(atan(-1.0) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= -1.55e+22)
    		tmp = 180.0 * (atan(1.0) / pi);
    	elseif (B <= -3.4e-166)
    		tmp = 180.0 * (atan((B * (0.5 / A))) / pi);
    	elseif (B <= 1.32e+39)
    		tmp = 180.0 / (pi / atan((-A / B)));
    	else
    		tmp = 180.0 * (atan(-1.0) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, -1.55e+22], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, -3.4e-166], N[(180.0 * N[(N[ArcTan[N[(B * N[(0.5 / A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 1.32e+39], N[(180.0 / N[(Pi / N[ArcTan[N[((-A) / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq -1.55 \cdot 10^{+22}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
    
    \mathbf{elif}\;B \leq -3.4 \cdot 10^{-166}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(B \cdot \frac{0.5}{A}\right)}{\pi}\\
    
    \mathbf{elif}\;B \leq 1.32 \cdot 10^{+39}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{-A}{B}\right)}}\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 4 regimes
    2. if B < -1.5500000000000001e22

      1. Initial program 49.9%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around -inf 68.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{1}}{\pi} \]

      if -1.5500000000000001e22 < B < -3.3999999999999997e-166

      1. Initial program 46.9%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. associate--l-46.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
        2. +-commutative46.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
        3. unpow246.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
        4. unpow246.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
        5. hypot-undefine46.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
        6. associate-/r/46.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
        7. associate--r+57.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
      4. Applied egg-rr57.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
      5. Taylor expanded in A around -inf 46.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
      6. Step-by-step derivation
        1. associate-*r*46.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
        2. mul-1-neg46.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
        3. associate-*r/46.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
        4. metadata-eval46.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
      7. Simplified46.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
      8. Taylor expanded in A around inf 48.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(0.5 \cdot \frac{B}{A}\right)}}{\pi} \]
      9. Step-by-step derivation
        1. associate-*r/48.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{0.5 \cdot B}{A}\right)}}{\pi} \]
        2. *-commutative48.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{B \cdot 0.5}}{A}\right)}{\pi} \]
        3. associate-/l*48.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(B \cdot \frac{0.5}{A}\right)}}{\pi} \]
      10. Simplified48.3%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(B \cdot \frac{0.5}{A}\right)}}{\pi} \]

      if -3.3999999999999997e-166 < B < 1.32e39

      1. Initial program 60.4%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative60.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-57.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative57.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow257.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow257.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine65.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv65.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num65.7%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv65.7%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr75.1%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around inf 53.1%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{B \cdot \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{B}\right)}} \]
      6. Taylor expanded in A around inf 41.3%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-1 \cdot \frac{A}{B}\right)}}} \]
      7. Step-by-step derivation
        1. associate-*r/41.3%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\frac{-1 \cdot A}{B}\right)}}} \]
        2. mul-1-neg41.3%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{-A}}{B}\right)}} \]
      8. Simplified41.3%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\frac{-A}{B}\right)}}} \]

      if 1.32e39 < B

      1. Initial program 38.1%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around inf 73.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{-1}}{\pi} \]
    3. Recombined 4 regimes into one program.
    4. Add Preprocessing

    Alternative 12: 65.1% accurate, 3.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq 8 \cdot 10^{-302}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 1.7 \cdot 10^{-274}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{1}{2 \cdot \frac{A}{B}}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B 8e-302)
       (* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI))
       (if (<= B 1.7e-274)
         (* 180.0 (/ (atan (/ 1.0 (* 2.0 (/ A B)))) PI))
         (* 180.0 (/ (atan (+ (/ C B) (- -1.0 (/ A B)))) PI)))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= 8e-302) {
    		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / ((double) M_PI));
    	} else if (B <= 1.7e-274) {
    		tmp = 180.0 * (atan((1.0 / (2.0 * (A / B)))) / ((double) M_PI));
    	} else {
    		tmp = 180.0 * (atan(((C / B) + (-1.0 - (A / B)))) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= 8e-302) {
    		tmp = 180.0 * (Math.atan((1.0 + ((C - A) / B))) / Math.PI);
    	} else if (B <= 1.7e-274) {
    		tmp = 180.0 * (Math.atan((1.0 / (2.0 * (A / B)))) / Math.PI);
    	} else {
    		tmp = 180.0 * (Math.atan(((C / B) + (-1.0 - (A / B)))) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= 8e-302:
    		tmp = 180.0 * (math.atan((1.0 + ((C - A) / B))) / math.pi)
    	elif B <= 1.7e-274:
    		tmp = 180.0 * (math.atan((1.0 / (2.0 * (A / B)))) / math.pi)
    	else:
    		tmp = 180.0 * (math.atan(((C / B) + (-1.0 - (A / B)))) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= 8e-302)
    		tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(Float64(C - A) / B))) / pi));
    	elseif (B <= 1.7e-274)
    		tmp = Float64(180.0 * Float64(atan(Float64(1.0 / Float64(2.0 * Float64(A / B)))) / pi));
    	else
    		tmp = Float64(180.0 * Float64(atan(Float64(Float64(C / B) + Float64(-1.0 - Float64(A / B)))) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= 8e-302)
    		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / pi);
    	elseif (B <= 1.7e-274)
    		tmp = 180.0 * (atan((1.0 / (2.0 * (A / B)))) / pi);
    	else
    		tmp = 180.0 * (atan(((C / B) + (-1.0 - (A / B)))) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, 8e-302], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 1.7e-274], N[(180.0 * N[(N[ArcTan[N[(1.0 / N[(2.0 * N[(A / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(C / B), $MachinePrecision] + N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq 8 \cdot 10^{-302}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
    
    \mathbf{elif}\;B \leq 1.7 \cdot 10^{-274}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{1}{2 \cdot \frac{A}{B}}\right)}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if B < 7.9999999999999997e-302

      1. Initial program 53.1%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around -inf 67.9%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}}{\pi} \]
      4. Step-by-step derivation
        1. associate--l+67.9%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(1 + \left(\frac{C}{B} - \frac{A}{B}\right)\right)}}{\pi} \]
        2. div-sub69.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(1 + \color{blue}{\frac{C - A}{B}}\right)}{\pi} \]
      5. Simplified69.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(1 + \frac{C - A}{B}\right)}}{\pi} \]

      if 7.9999999999999997e-302 < B < 1.6999999999999999e-274

      1. Initial program 36.5%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. associate--l-19.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
        2. +-commutative19.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
        3. unpow219.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
        4. unpow219.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
        5. hypot-undefine31.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
        6. associate-/r/31.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
        7. associate--r+65.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
      4. Applied egg-rr65.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
      5. Taylor expanded in A around -inf 90.6%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{2 \cdot \frac{A}{B}}}\right)}{\pi} \]

      if 1.6999999999999999e-274 < B

      1. Initial program 49.8%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around inf 69.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{\pi} \]
    3. Recombined 3 regimes into one program.
    4. Final simplification70.0%

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq 8 \cdot 10^{-302}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 1.7 \cdot 10^{-274}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{1}{2 \cdot \frac{A}{B}}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} + \left(-1 - \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 13: 59.8% accurate, 3.5× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;A \leq -2.9 \cdot 10^{-94}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(B \cdot \frac{0.5}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 8.4 \cdot 10^{-153}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 + \frac{C}{B}\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 - \frac{A}{B}\right)}}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= A -2.9e-94)
       (* 180.0 (/ (atan (* B (/ 0.5 A))) PI))
       (if (<= A 8.4e-153)
         (/ 180.0 (/ PI (atan (+ -1.0 (/ C B)))))
         (/ 180.0 (/ PI (atan (- -1.0 (/ A B))))))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (A <= -2.9e-94) {
    		tmp = 180.0 * (atan((B * (0.5 / A))) / ((double) M_PI));
    	} else if (A <= 8.4e-153) {
    		tmp = 180.0 / (((double) M_PI) / atan((-1.0 + (C / B))));
    	} else {
    		tmp = 180.0 / (((double) M_PI) / atan((-1.0 - (A / B))));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (A <= -2.9e-94) {
    		tmp = 180.0 * (Math.atan((B * (0.5 / A))) / Math.PI);
    	} else if (A <= 8.4e-153) {
    		tmp = 180.0 / (Math.PI / Math.atan((-1.0 + (C / B))));
    	} else {
    		tmp = 180.0 / (Math.PI / Math.atan((-1.0 - (A / B))));
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if A <= -2.9e-94:
    		tmp = 180.0 * (math.atan((B * (0.5 / A))) / math.pi)
    	elif A <= 8.4e-153:
    		tmp = 180.0 / (math.pi / math.atan((-1.0 + (C / B))))
    	else:
    		tmp = 180.0 / (math.pi / math.atan((-1.0 - (A / B))))
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (A <= -2.9e-94)
    		tmp = Float64(180.0 * Float64(atan(Float64(B * Float64(0.5 / A))) / pi));
    	elseif (A <= 8.4e-153)
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(-1.0 + Float64(C / B)))));
    	else
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(-1.0 - Float64(A / B)))));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (A <= -2.9e-94)
    		tmp = 180.0 * (atan((B * (0.5 / A))) / pi);
    	elseif (A <= 8.4e-153)
    		tmp = 180.0 / (pi / atan((-1.0 + (C / B))));
    	else
    		tmp = 180.0 / (pi / atan((-1.0 - (A / B))));
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[A, -2.9e-94], N[(180.0 * N[(N[ArcTan[N[(B * N[(0.5 / A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, 8.4e-153], N[(180.0 / N[(Pi / N[ArcTan[N[(-1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(180.0 / N[(Pi / N[ArcTan[N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;A \leq -2.9 \cdot 10^{-94}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(B \cdot \frac{0.5}{A}\right)}{\pi}\\
    
    \mathbf{elif}\;A \leq 8.4 \cdot 10^{-153}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 + \frac{C}{B}\right)}}\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 - \frac{A}{B}\right)}}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if A < -2.89999999999999995e-94

      1. Initial program 30.4%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. associate--l-26.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}\right)}{\pi} \]
        2. +-commutative26.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right)\right)}{\pi} \]
        3. unpow226.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right)\right)}{\pi} \]
        4. unpow226.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right)\right)}{\pi} \]
        5. hypot-undefine39.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right)\right)}{\pi} \]
        6. associate-/r/39.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}}\right)}}{\pi} \]
        7. associate--r+56.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\frac{B}{\color{blue}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}}\right)}{\pi} \]
      4. Applied egg-rr56.3%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{1}{\frac{B}{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}}\right)}}{\pi} \]
      5. Taylor expanded in A around -inf 66.8%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{-1 \cdot \left(A \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)\right)}}\right)}{\pi} \]
      6. Step-by-step derivation
        1. associate-*r*66.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-1 \cdot A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}}\right)}{\pi} \]
        2. mul-1-neg66.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right)} \cdot \left(2 \cdot \frac{C}{A \cdot B} - 2 \cdot \frac{1}{B}\right)}\right)}{\pi} \]
        3. associate-*r/66.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \color{blue}{\frac{2 \cdot 1}{B}}\right)}\right)}{\pi} \]
        4. metadata-eval66.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{\color{blue}{2}}{B}\right)}\right)}{\pi} \]
      7. Simplified66.8%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{1}{\color{blue}{\left(-A\right) \cdot \left(2 \cdot \frac{C}{A \cdot B} - \frac{2}{B}\right)}}\right)}{\pi} \]
      8. Taylor expanded in A around inf 67.8%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(0.5 \cdot \frac{B}{A}\right)}}{\pi} \]
      9. Step-by-step derivation
        1. associate-*r/67.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{0.5 \cdot B}{A}\right)}}{\pi} \]
        2. *-commutative67.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{B \cdot 0.5}}{A}\right)}{\pi} \]
        3. associate-/l*67.8%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(B \cdot \frac{0.5}{A}\right)}}{\pi} \]
      10. Simplified67.8%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(B \cdot \frac{0.5}{A}\right)}}{\pi} \]

      if -2.89999999999999995e-94 < A < 8.40000000000000017e-153

      1. Initial program 51.7%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative51.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-51.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative51.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow251.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow251.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine80.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv80.5%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num80.5%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv80.5%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr80.5%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around inf 53.4%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{B \cdot \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{B}\right)}} \]
      6. Taylor expanded in A around 0 53.5%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\frac{C}{B} - 1\right)}}} \]

      if 8.40000000000000017e-153 < A

      1. Initial program 66.7%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative66.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-66.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative66.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow266.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow266.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine94.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv94.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num94.2%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv94.2%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr94.2%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around inf 65.1%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{B \cdot \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{B}\right)}} \]
      6. Taylor expanded in C around 0 66.5%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-1 \cdot \left(1 + \frac{A}{B}\right)\right)}}} \]
      7. Step-by-step derivation
        1. neg-mul-166.5%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-\left(1 + \frac{A}{B}\right)\right)}}} \]
        2. distribute-neg-in66.5%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\left(-1\right) + \left(-\frac{A}{B}\right)\right)}}} \]
        3. metadata-eval66.5%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\color{blue}{-1} + \left(-\frac{A}{B}\right)\right)}} \]
        4. unsub-neg66.5%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-1 - \frac{A}{B}\right)}}} \]
      8. Simplified66.5%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-1 - \frac{A}{B}\right)}}} \]
    3. Recombined 3 regimes into one program.
    4. Final simplification62.7%

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -2.9 \cdot 10^{-94}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(B \cdot \frac{0.5}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 8.4 \cdot 10^{-153}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 + \frac{C}{B}\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 - \frac{A}{B}\right)}}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 14: 51.0% accurate, 3.5× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -1.75 \cdot 10^{+21}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq -5.6 \cdot 10^{-168}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 - \frac{A}{B}\right)}}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B -1.75e+21)
       (* 180.0 (/ (atan 1.0) PI))
       (if (<= B -5.6e-168)
         (* 180.0 (/ (atan (/ (* B 0.5) A)) PI))
         (/ 180.0 (/ PI (atan (- -1.0 (/ A B))))))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -1.75e+21) {
    		tmp = 180.0 * (atan(1.0) / ((double) M_PI));
    	} else if (B <= -5.6e-168) {
    		tmp = 180.0 * (atan(((B * 0.5) / A)) / ((double) M_PI));
    	} else {
    		tmp = 180.0 / (((double) M_PI) / atan((-1.0 - (A / B))));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -1.75e+21) {
    		tmp = 180.0 * (Math.atan(1.0) / Math.PI);
    	} else if (B <= -5.6e-168) {
    		tmp = 180.0 * (Math.atan(((B * 0.5) / A)) / Math.PI);
    	} else {
    		tmp = 180.0 / (Math.PI / Math.atan((-1.0 - (A / B))));
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= -1.75e+21:
    		tmp = 180.0 * (math.atan(1.0) / math.pi)
    	elif B <= -5.6e-168:
    		tmp = 180.0 * (math.atan(((B * 0.5) / A)) / math.pi)
    	else:
    		tmp = 180.0 / (math.pi / math.atan((-1.0 - (A / B))))
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= -1.75e+21)
    		tmp = Float64(180.0 * Float64(atan(1.0) / pi));
    	elseif (B <= -5.6e-168)
    		tmp = Float64(180.0 * Float64(atan(Float64(Float64(B * 0.5) / A)) / pi));
    	else
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(-1.0 - Float64(A / B)))));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= -1.75e+21)
    		tmp = 180.0 * (atan(1.0) / pi);
    	elseif (B <= -5.6e-168)
    		tmp = 180.0 * (atan(((B * 0.5) / A)) / pi);
    	else
    		tmp = 180.0 / (pi / atan((-1.0 - (A / B))));
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, -1.75e+21], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, -5.6e-168], N[(180.0 * N[(N[ArcTan[N[(N[(B * 0.5), $MachinePrecision] / A), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 / N[(Pi / N[ArcTan[N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq -1.75 \cdot 10^{+21}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
    
    \mathbf{elif}\;B \leq -5.6 \cdot 10^{-168}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 - \frac{A}{B}\right)}}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if B < -1.75e21

      1. Initial program 49.9%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around -inf 68.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{1}}{\pi} \]

      if -1.75e21 < B < -5.6000000000000005e-168

      1. Initial program 46.9%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in A around -inf 48.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(0.5 \cdot \frac{B}{A}\right)}}{\pi} \]
      4. Step-by-step derivation
        1. associate-*r/48.4%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{0.5 \cdot B}{A}\right)}}{\pi} \]
      5. Simplified48.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{0.5 \cdot B}{A}\right)}}{\pi} \]

      if -5.6000000000000005e-168 < B

      1. Initial program 52.6%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative52.6%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-50.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative50.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow250.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow250.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine73.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv73.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num73.1%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv73.1%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr79.1%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around inf 63.6%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{B \cdot \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{B}\right)}} \]
      6. Taylor expanded in C around 0 56.6%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-1 \cdot \left(1 + \frac{A}{B}\right)\right)}}} \]
      7. Step-by-step derivation
        1. neg-mul-156.6%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-\left(1 + \frac{A}{B}\right)\right)}}} \]
        2. distribute-neg-in56.6%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\left(-1\right) + \left(-\frac{A}{B}\right)\right)}}} \]
        3. metadata-eval56.6%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\color{blue}{-1} + \left(-\frac{A}{B}\right)\right)}} \]
        4. unsub-neg56.6%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-1 - \frac{A}{B}\right)}}} \]
      8. Simplified56.6%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-1 - \frac{A}{B}\right)}}} \]
    3. Recombined 3 regimes into one program.
    4. Final simplification58.7%

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -1.75 \cdot 10^{+21}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq -5.6 \cdot 10^{-168}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 - \frac{A}{B}\right)}}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 15: 45.8% accurate, 3.5× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -4.5 \cdot 10^{-142}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq 8.5 \cdot 10^{+40}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{-A}{B}\right)}}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B -4.5e-142)
       (* 180.0 (/ (atan 1.0) PI))
       (if (<= B 8.5e+40)
         (/ 180.0 (/ PI (atan (/ (- A) B))))
         (* 180.0 (/ (atan -1.0) PI)))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -4.5e-142) {
    		tmp = 180.0 * (atan(1.0) / ((double) M_PI));
    	} else if (B <= 8.5e+40) {
    		tmp = 180.0 / (((double) M_PI) / atan((-A / B)));
    	} else {
    		tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -4.5e-142) {
    		tmp = 180.0 * (Math.atan(1.0) / Math.PI);
    	} else if (B <= 8.5e+40) {
    		tmp = 180.0 / (Math.PI / Math.atan((-A / B)));
    	} else {
    		tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= -4.5e-142:
    		tmp = 180.0 * (math.atan(1.0) / math.pi)
    	elif B <= 8.5e+40:
    		tmp = 180.0 / (math.pi / math.atan((-A / B)))
    	else:
    		tmp = 180.0 * (math.atan(-1.0) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= -4.5e-142)
    		tmp = Float64(180.0 * Float64(atan(1.0) / pi));
    	elseif (B <= 8.5e+40)
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(Float64(-A) / B))));
    	else
    		tmp = Float64(180.0 * Float64(atan(-1.0) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= -4.5e-142)
    		tmp = 180.0 * (atan(1.0) / pi);
    	elseif (B <= 8.5e+40)
    		tmp = 180.0 / (pi / atan((-A / B)));
    	else
    		tmp = 180.0 * (atan(-1.0) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, -4.5e-142], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 8.5e+40], N[(180.0 / N[(Pi / N[ArcTan[N[((-A) / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq -4.5 \cdot 10^{-142}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
    
    \mathbf{elif}\;B \leq 8.5 \cdot 10^{+40}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{-A}{B}\right)}}\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if B < -4.50000000000000019e-142

      1. Initial program 47.8%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around -inf 55.9%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{1}}{\pi} \]

      if -4.50000000000000019e-142 < B < 8.49999999999999996e40

      1. Initial program 61.0%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative61.0%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-58.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative58.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow258.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow258.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine66.0%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv66.0%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num66.1%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv66.1%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr76.0%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around inf 53.0%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{B \cdot \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{B}\right)}} \]
      6. Taylor expanded in A around inf 40.8%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(-1 \cdot \frac{A}{B}\right)}}} \]
      7. Step-by-step derivation
        1. associate-*r/40.8%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\frac{-1 \cdot A}{B}\right)}}} \]
        2. mul-1-neg40.8%

          \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{-A}}{B}\right)}} \]
      8. Simplified40.8%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\frac{-A}{B}\right)}}} \]

      if 8.49999999999999996e40 < B

      1. Initial program 38.1%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around inf 73.5%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{-1}}{\pi} \]
    3. Recombined 3 regimes into one program.
    4. Add Preprocessing

    Alternative 16: 45.8% accurate, 3.6× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -2.8 \cdot 10^{-8}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq 1.15 \cdot 10^{+65}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C}{B}\right)}}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B -2.8e-8)
       (* 180.0 (/ (atan 1.0) PI))
       (if (<= B 1.15e+65)
         (/ 180.0 (/ PI (atan (/ C B))))
         (* 180.0 (/ (atan -1.0) PI)))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -2.8e-8) {
    		tmp = 180.0 * (atan(1.0) / ((double) M_PI));
    	} else if (B <= 1.15e+65) {
    		tmp = 180.0 / (((double) M_PI) / atan((C / B)));
    	} else {
    		tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -2.8e-8) {
    		tmp = 180.0 * (Math.atan(1.0) / Math.PI);
    	} else if (B <= 1.15e+65) {
    		tmp = 180.0 / (Math.PI / Math.atan((C / B)));
    	} else {
    		tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= -2.8e-8:
    		tmp = 180.0 * (math.atan(1.0) / math.pi)
    	elif B <= 1.15e+65:
    		tmp = 180.0 / (math.pi / math.atan((C / B)))
    	else:
    		tmp = 180.0 * (math.atan(-1.0) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= -2.8e-8)
    		tmp = Float64(180.0 * Float64(atan(1.0) / pi));
    	elseif (B <= 1.15e+65)
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(C / B))));
    	else
    		tmp = Float64(180.0 * Float64(atan(-1.0) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= -2.8e-8)
    		tmp = 180.0 * (atan(1.0) / pi);
    	elseif (B <= 1.15e+65)
    		tmp = 180.0 / (pi / atan((C / B)));
    	else
    		tmp = 180.0 * (atan(-1.0) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, -2.8e-8], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 1.15e+65], N[(180.0 / N[(Pi / N[ArcTan[N[(C / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq -2.8 \cdot 10^{-8}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
    
    \mathbf{elif}\;B \leq 1.15 \cdot 10^{+65}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C}{B}\right)}}\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if B < -2.7999999999999999e-8

      1. Initial program 47.4%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around -inf 64.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{1}}{\pi} \]

      if -2.7999999999999999e-8 < B < 1.15e65

      1. Initial program 59.1%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative59.1%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-56.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative56.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow256.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow256.7%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine63.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv63.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num63.2%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv63.2%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr72.9%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around inf 50.0%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{B \cdot \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{B}\right)}} \]
      6. Taylor expanded in C around inf 33.6%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\frac{C}{B}\right)}}} \]

      if 1.15e65 < B

      1. Initial program 37.0%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around inf 78.2%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{-1}}{\pi} \]
    3. Recombined 3 regimes into one program.
    4. Add Preprocessing

    Alternative 17: 62.7% accurate, 3.6× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq 1.55 \cdot 10^{-96}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 + \frac{C}{B}\right)}}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B 1.55e-96)
       (* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI))
       (/ 180.0 (/ PI (atan (+ -1.0 (/ C B)))))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= 1.55e-96) {
    		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / ((double) M_PI));
    	} else {
    		tmp = 180.0 / (((double) M_PI) / atan((-1.0 + (C / B))));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= 1.55e-96) {
    		tmp = 180.0 * (Math.atan((1.0 + ((C - A) / B))) / Math.PI);
    	} else {
    		tmp = 180.0 / (Math.PI / Math.atan((-1.0 + (C / B))));
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= 1.55e-96:
    		tmp = 180.0 * (math.atan((1.0 + ((C - A) / B))) / math.pi)
    	else:
    		tmp = 180.0 / (math.pi / math.atan((-1.0 + (C / B))))
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= 1.55e-96)
    		tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(Float64(C - A) / B))) / pi));
    	else
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(-1.0 + Float64(C / B)))));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= 1.55e-96)
    		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / pi);
    	else
    		tmp = 180.0 / (pi / atan((-1.0 + (C / B))));
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, 1.55e-96], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 / N[(Pi / N[ArcTan[N[(-1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq 1.55 \cdot 10^{-96}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 + \frac{C}{B}\right)}}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if B < 1.55e-96

      1. Initial program 54.7%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around -inf 62.9%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}}{\pi} \]
      4. Step-by-step derivation
        1. associate--l+62.9%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(1 + \left(\frac{C}{B} - \frac{A}{B}\right)\right)}}{\pi} \]
        2. div-sub64.6%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(1 + \color{blue}{\frac{C - A}{B}}\right)}{\pi} \]
      5. Simplified64.6%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(1 + \frac{C - A}{B}\right)}}{\pi} \]

      if 1.55e-96 < B

      1. Initial program 43.0%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutative43.0%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right) \cdot \frac{1}{B}\right)}}{\pi} \]
        2. associate--l-42.9%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\color{blue}{\left(C - \left(A + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)} \cdot \frac{1}{B}\right)}{\pi} \]
        3. +-commutative42.9%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{{B}^{2} + {\left(A - C\right)}^{2}}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        4. unpow242.9%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{\color{blue}{B \cdot B} + {\left(A - C\right)}^{2}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        5. unpow242.9%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \sqrt{B \cdot B + \color{blue}{\left(A - C\right) \cdot \left(A - C\right)}}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        6. hypot-undefine80.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\left(C - \left(A + \color{blue}{\mathsf{hypot}\left(B, A - C\right)}\right)\right) \cdot \frac{1}{B}\right)}{\pi} \]
        7. div-inv80.2%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}{\pi} \]
        8. clear-num80.2%

          \[\leadsto 180 \cdot \color{blue}{\frac{1}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
        9. un-div-inv80.2%

          \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)}}} \]
      4. Applied egg-rr80.1%

        \[\leadsto \color{blue}{\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}} \]
      5. Taylor expanded in B around inf 76.0%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\color{blue}{B \cdot \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}}{B}\right)}} \]
      6. Taylor expanded in A around 0 71.6%

        \[\leadsto \frac{180}{\frac{\pi}{\tan^{-1} \color{blue}{\left(\frac{C}{B} - 1\right)}}} \]
    3. Recombined 2 regimes into one program.
    4. Final simplification66.7%

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq 1.55 \cdot 10^{-96}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(-1 + \frac{C}{B}\right)}}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 18: 44.2% accurate, 3.6× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -2.7 \cdot 10^{-154}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq 4.9 \cdot 10^{-104}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 0}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B -2.7e-154)
       (* 180.0 (/ (atan 1.0) PI))
       (if (<= B 4.9e-104)
         (* 180.0 (/ (atan 0.0) PI))
         (* 180.0 (/ (atan -1.0) PI)))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -2.7e-154) {
    		tmp = 180.0 * (atan(1.0) / ((double) M_PI));
    	} else if (B <= 4.9e-104) {
    		tmp = 180.0 * (atan(0.0) / ((double) M_PI));
    	} else {
    		tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -2.7e-154) {
    		tmp = 180.0 * (Math.atan(1.0) / Math.PI);
    	} else if (B <= 4.9e-104) {
    		tmp = 180.0 * (Math.atan(0.0) / Math.PI);
    	} else {
    		tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= -2.7e-154:
    		tmp = 180.0 * (math.atan(1.0) / math.pi)
    	elif B <= 4.9e-104:
    		tmp = 180.0 * (math.atan(0.0) / math.pi)
    	else:
    		tmp = 180.0 * (math.atan(-1.0) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= -2.7e-154)
    		tmp = Float64(180.0 * Float64(atan(1.0) / pi));
    	elseif (B <= 4.9e-104)
    		tmp = Float64(180.0 * Float64(atan(0.0) / pi));
    	else
    		tmp = Float64(180.0 * Float64(atan(-1.0) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= -2.7e-154)
    		tmp = 180.0 * (atan(1.0) / pi);
    	elseif (B <= 4.9e-104)
    		tmp = 180.0 * (atan(0.0) / pi);
    	else
    		tmp = 180.0 * (atan(-1.0) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, -2.7e-154], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 4.9e-104], N[(180.0 * N[(N[ArcTan[0.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq -2.7 \cdot 10^{-154}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
    
    \mathbf{elif}\;B \leq 4.9 \cdot 10^{-104}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} 0}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if B < -2.69999999999999989e-154

      1. Initial program 48.9%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around -inf 55.1%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{1}}{\pi} \]

      if -2.69999999999999989e-154 < B < 4.9000000000000003e-104

      1. Initial program 60.6%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in C around inf 30.4%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + -1 \cdot A}{B} + -0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
      4. Taylor expanded in B around 0 26.3%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + -1 \cdot A}{B}\right)}}{\pi} \]
      5. Step-by-step derivation
        1. associate-*r/26.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{-1 \cdot \left(A + -1 \cdot A\right)}{B}\right)}}{\pi} \]
        2. *-commutative26.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{\left(A + -1 \cdot A\right) \cdot -1}}{B}\right)}{\pi} \]
        3. distribute-rgt1-in26.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{\left(\left(-1 + 1\right) \cdot A\right)} \cdot -1}{B}\right)}{\pi} \]
        4. metadata-eval26.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\left(\color{blue}{0} \cdot A\right) \cdot -1}{B}\right)}{\pi} \]
        5. mul0-lft26.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{0} \cdot -1}{B}\right)}{\pi} \]
        6. metadata-eval26.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{0}}{B}\right)}{\pi} \]
        7. div026.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{0}}{\pi} \]
      6. Simplified26.3%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{0}}{\pi} \]

      if 4.9000000000000003e-104 < B

      1. Initial program 43.7%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around inf 60.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{-1}}{\pi} \]
    3. Recombined 3 regimes into one program.
    4. Add Preprocessing

    Alternative 19: 28.7% accurate, 3.8× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq 2.05 \cdot 10^{-108}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 0}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B 2.05e-108)
       (* 180.0 (/ (atan 0.0) PI))
       (* 180.0 (/ (atan -1.0) PI))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= 2.05e-108) {
    		tmp = 180.0 * (atan(0.0) / ((double) M_PI));
    	} else {
    		tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double tmp;
    	if (B <= 2.05e-108) {
    		tmp = 180.0 * (Math.atan(0.0) / Math.PI);
    	} else {
    		tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= 2.05e-108:
    		tmp = 180.0 * (math.atan(0.0) / math.pi)
    	else:
    		tmp = 180.0 * (math.atan(-1.0) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= 2.05e-108)
    		tmp = Float64(180.0 * Float64(atan(0.0) / pi));
    	else
    		tmp = Float64(180.0 * Float64(atan(-1.0) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (B <= 2.05e-108)
    		tmp = 180.0 * (atan(0.0) / pi);
    	else
    		tmp = 180.0 * (atan(-1.0) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, 2.05e-108], N[(180.0 * N[(N[ArcTan[0.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;B \leq 2.05 \cdot 10^{-108}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} 0}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if B < 2.05000000000000018e-108

      1. Initial program 54.5%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in C around inf 24.3%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + -1 \cdot A}{B} + -0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
      4. Taylor expanded in B around 0 15.3%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + -1 \cdot A}{B}\right)}}{\pi} \]
      5. Step-by-step derivation
        1. associate-*r/15.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{-1 \cdot \left(A + -1 \cdot A\right)}{B}\right)}}{\pi} \]
        2. *-commutative15.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{\left(A + -1 \cdot A\right) \cdot -1}}{B}\right)}{\pi} \]
        3. distribute-rgt1-in15.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{\left(\left(-1 + 1\right) \cdot A\right)} \cdot -1}{B}\right)}{\pi} \]
        4. metadata-eval15.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\left(\color{blue}{0} \cdot A\right) \cdot -1}{B}\right)}{\pi} \]
        5. mul0-lft15.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{0} \cdot -1}{B}\right)}{\pi} \]
        6. metadata-eval15.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \left(\frac{\color{blue}{0}}{B}\right)}{\pi} \]
        7. div015.3%

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{0}}{\pi} \]
      6. Simplified15.3%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{0}}{\pi} \]

      if 2.05000000000000018e-108 < B

      1. Initial program 43.7%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Taylor expanded in B around inf 60.7%

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{-1}}{\pi} \]
    3. Recombined 2 regimes into one program.
    4. Add Preprocessing

    Alternative 20: 20.3% accurate, 4.0× speedup?

    \[\begin{array}{l} \\ 180 \cdot \frac{\tan^{-1} -1}{\pi} \end{array} \]
    (FPCore (A B C) :precision binary64 (* 180.0 (/ (atan -1.0) PI)))
    double code(double A, double B, double C) {
    	return 180.0 * (atan(-1.0) / ((double) M_PI));
    }
    
    public static double code(double A, double B, double C) {
    	return 180.0 * (Math.atan(-1.0) / Math.PI);
    }
    
    def code(A, B, C):
    	return 180.0 * (math.atan(-1.0) / math.pi)
    
    function code(A, B, C)
    	return Float64(180.0 * Float64(atan(-1.0) / pi))
    end
    
    function tmp = code(A, B, C)
    	tmp = 180.0 * (atan(-1.0) / pi);
    end
    
    code[A_, B_, C_] := N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    
    \\
    180 \cdot \frac{\tan^{-1} -1}{\pi}
    \end{array}
    
    Derivation
    1. Initial program 51.3%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Taylor expanded in B around inf 21.6%

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{-1}}{\pi} \]
    4. Add Preprocessing

    Reproduce

    ?
    herbie shell --seed 2024146 
    (FPCore (A B C)
      :name "ABCF->ab-angle angle"
      :precision binary64
      (* 180.0 (/ (atan (* (/ 1.0 B) (- (- C A) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0)))))) PI)))