ABCF->ab-angle angle

Percentage Accurate: 52.8% → 79.9%
Time: 21.8s
Alternatives: 20
Speedup: 2.4×

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: 52.8% 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: 79.9% accurate, 1.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)\\ \mathbf{if}\;A \leq -5.8 \cdot 10^{+133}:\\ \;\;\;\;180 \cdot \frac{t_0}{\pi}\\ \mathbf{elif}\;A \leq -2.7 \cdot 10^{+76}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(B, C\right)}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq -450000:\\ \;\;\;\;\frac{1}{\frac{\frac{\pi}{180}}{t_0}}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)\\ \end{array} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (let* ((t_0 (atan (* 0.5 (/ B A)))))
   (if (<= A -5.8e+133)
     (* 180.0 (/ t_0 PI))
     (if (<= A -2.7e+76)
       (* 180.0 (/ (atan (/ (- C (hypot B C)) B)) PI))
       (if (<= A -450000.0)
         (/ 1.0 (/ (/ PI 180.0) t_0))
         (* (/ 180.0 PI) (atan (/ (- C (+ A (hypot B (- A C)))) B))))))))
double code(double A, double B, double C) {
	double t_0 = atan((0.5 * (B / A)));
	double tmp;
	if (A <= -5.8e+133) {
		tmp = 180.0 * (t_0 / ((double) M_PI));
	} else if (A <= -2.7e+76) {
		tmp = 180.0 * (atan(((C - hypot(B, C)) / B)) / ((double) M_PI));
	} else if (A <= -450000.0) {
		tmp = 1.0 / ((((double) M_PI) / 180.0) / t_0);
	} 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 t_0 = Math.atan((0.5 * (B / A)));
	double tmp;
	if (A <= -5.8e+133) {
		tmp = 180.0 * (t_0 / Math.PI);
	} else if (A <= -2.7e+76) {
		tmp = 180.0 * (Math.atan(((C - Math.hypot(B, C)) / B)) / Math.PI);
	} else if (A <= -450000.0) {
		tmp = 1.0 / ((Math.PI / 180.0) / t_0);
	} else {
		tmp = (180.0 / Math.PI) * Math.atan(((C - (A + Math.hypot(B, (A - C)))) / B));
	}
	return tmp;
}
def code(A, B, C):
	t_0 = math.atan((0.5 * (B / A)))
	tmp = 0
	if A <= -5.8e+133:
		tmp = 180.0 * (t_0 / math.pi)
	elif A <= -2.7e+76:
		tmp = 180.0 * (math.atan(((C - math.hypot(B, C)) / B)) / math.pi)
	elif A <= -450000.0:
		tmp = 1.0 / ((math.pi / 180.0) / t_0)
	else:
		tmp = (180.0 / math.pi) * math.atan(((C - (A + math.hypot(B, (A - C)))) / B))
	return tmp
function code(A, B, C)
	t_0 = atan(Float64(0.5 * Float64(B / A)))
	tmp = 0.0
	if (A <= -5.8e+133)
		tmp = Float64(180.0 * Float64(t_0 / pi));
	elseif (A <= -2.7e+76)
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(C - hypot(B, C)) / B)) / pi));
	elseif (A <= -450000.0)
		tmp = Float64(1.0 / Float64(Float64(pi / 180.0) / t_0));
	else
		tmp = Float64(Float64(180.0 / pi) * atan(Float64(Float64(C - Float64(A + hypot(B, Float64(A - C)))) / B)));
	end
	return tmp
end
function tmp_2 = code(A, B, C)
	t_0 = atan((0.5 * (B / A)));
	tmp = 0.0;
	if (A <= -5.8e+133)
		tmp = 180.0 * (t_0 / pi);
	elseif (A <= -2.7e+76)
		tmp = 180.0 * (atan(((C - hypot(B, C)) / B)) / pi);
	elseif (A <= -450000.0)
		tmp = 1.0 / ((pi / 180.0) / t_0);
	else
		tmp = (180.0 / pi) * atan(((C - (A + hypot(B, (A - C)))) / B));
	end
	tmp_2 = tmp;
end
code[A_, B_, C_] := Block[{t$95$0 = N[ArcTan[N[(0.5 * N[(B / A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[A, -5.8e+133], N[(180.0 * N[(t$95$0 / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -2.7e+76], N[(180.0 * N[(N[ArcTan[N[(N[(C - N[Sqrt[B ^ 2 + C ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -450000.0], N[(1.0 / N[(N[(Pi / 180.0), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision], N[(N[(180.0 / Pi), $MachinePrecision] * N[ArcTan[N[(N[(C - N[(A + N[Sqrt[B ^ 2 + N[(A - C), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)\\
\mathbf{if}\;A \leq -5.8 \cdot 10^{+133}:\\
\;\;\;\;180 \cdot \frac{t_0}{\pi}\\

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

\mathbf{elif}\;A \leq -450000:\\
\;\;\;\;\frac{1}{\frac{\frac{\pi}{180}}{t_0}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if A < -5.8000000000000002e133

    1. Initial program 15.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. Taylor expanded in A around -inf 82.6%

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

    if -5.8000000000000002e133 < A < -2.6999999999999999e76

    1. Initial program 37.2%

      \[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. Taylor expanded in A around 0 37.4%

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

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

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

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

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

    if -2.6999999999999999e76 < A < -4.5e5

    1. Initial program 21.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. Applied egg-rr41.6%

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

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

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

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

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

    if -4.5e5 < A

    1. Initial program 64.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. Taylor expanded in B around 0 64.6%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -5.8 \cdot 10^{+133}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq -2.7 \cdot 10^{+76}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(B, C\right)}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq -450000:\\ \;\;\;\;\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - \left(A + \mathsf{hypot}\left(B, A - C\right)\right)}{B}\right)\\ \end{array} \]

Alternative 2: 80.0% accurate, 1.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)\\ \mathbf{if}\;A \leq -2.2 \cdot 10^{+137}:\\ \;\;\;\;180 \cdot \frac{t_0}{\pi}\\ \mathbf{elif}\;A \leq -6.6 \cdot 10^{+76}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(B, C\right)}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq -450000:\\ \;\;\;\;\frac{1}{\frac{\frac{\pi}{180}}{t_0}}\\ \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
 (let* ((t_0 (atan (* 0.5 (/ B A)))))
   (if (<= A -2.2e+137)
     (* 180.0 (/ t_0 PI))
     (if (<= A -6.6e+76)
       (* 180.0 (/ (atan (/ (- C (hypot B C)) B)) PI))
       (if (<= A -450000.0)
         (/ 1.0 (/ (/ PI 180.0) t_0))
         (* 180.0 (/ (atan (/ (- C (+ A (hypot B (- A C)))) B)) PI)))))))
double code(double A, double B, double C) {
	double t_0 = atan((0.5 * (B / A)));
	double tmp;
	if (A <= -2.2e+137) {
		tmp = 180.0 * (t_0 / ((double) M_PI));
	} else if (A <= -6.6e+76) {
		tmp = 180.0 * (atan(((C - hypot(B, C)) / B)) / ((double) M_PI));
	} else if (A <= -450000.0) {
		tmp = 1.0 / ((((double) M_PI) / 180.0) / t_0);
	} 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 t_0 = Math.atan((0.5 * (B / A)));
	double tmp;
	if (A <= -2.2e+137) {
		tmp = 180.0 * (t_0 / Math.PI);
	} else if (A <= -6.6e+76) {
		tmp = 180.0 * (Math.atan(((C - Math.hypot(B, C)) / B)) / Math.PI);
	} else if (A <= -450000.0) {
		tmp = 1.0 / ((Math.PI / 180.0) / t_0);
	} else {
		tmp = 180.0 * (Math.atan(((C - (A + Math.hypot(B, (A - C)))) / B)) / Math.PI);
	}
	return tmp;
}
def code(A, B, C):
	t_0 = math.atan((0.5 * (B / A)))
	tmp = 0
	if A <= -2.2e+137:
		tmp = 180.0 * (t_0 / math.pi)
	elif A <= -6.6e+76:
		tmp = 180.0 * (math.atan(((C - math.hypot(B, C)) / B)) / math.pi)
	elif A <= -450000.0:
		tmp = 1.0 / ((math.pi / 180.0) / t_0)
	else:
		tmp = 180.0 * (math.atan(((C - (A + math.hypot(B, (A - C)))) / B)) / math.pi)
	return tmp
function code(A, B, C)
	t_0 = atan(Float64(0.5 * Float64(B / A)))
	tmp = 0.0
	if (A <= -2.2e+137)
		tmp = Float64(180.0 * Float64(t_0 / pi));
	elseif (A <= -6.6e+76)
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(C - hypot(B, C)) / B)) / pi));
	elseif (A <= -450000.0)
		tmp = Float64(1.0 / Float64(Float64(pi / 180.0) / t_0));
	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)
	t_0 = atan((0.5 * (B / A)));
	tmp = 0.0;
	if (A <= -2.2e+137)
		tmp = 180.0 * (t_0 / pi);
	elseif (A <= -6.6e+76)
		tmp = 180.0 * (atan(((C - hypot(B, C)) / B)) / pi);
	elseif (A <= -450000.0)
		tmp = 1.0 / ((pi / 180.0) / t_0);
	else
		tmp = 180.0 * (atan(((C - (A + hypot(B, (A - C)))) / B)) / pi);
	end
	tmp_2 = tmp;
end
code[A_, B_, C_] := Block[{t$95$0 = N[ArcTan[N[(0.5 * N[(B / A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[A, -2.2e+137], N[(180.0 * N[(t$95$0 / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -6.6e+76], N[(180.0 * N[(N[ArcTan[N[(N[(C - N[Sqrt[B ^ 2 + C ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -450000.0], N[(1.0 / N[(N[(Pi / 180.0), $MachinePrecision] / t$95$0), $MachinePrecision]), $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}
t_0 := \tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)\\
\mathbf{if}\;A \leq -2.2 \cdot 10^{+137}:\\
\;\;\;\;180 \cdot \frac{t_0}{\pi}\\

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

\mathbf{elif}\;A \leq -450000:\\
\;\;\;\;\frac{1}{\frac{\frac{\pi}{180}}{t_0}}\\

\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 4 regimes
  2. if A < -2.20000000000000015e137

    1. Initial program 15.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. Taylor expanded in A around -inf 82.6%

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

    if -2.20000000000000015e137 < A < -6.6000000000000001e76

    1. Initial program 37.2%

      \[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. Taylor expanded in A around 0 37.4%

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

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

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

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

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

    if -6.6000000000000001e76 < A < -4.5e5

    1. Initial program 21.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. Applied egg-rr41.6%

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

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

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

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

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

    if -4.5e5 < A

    1. Initial program 64.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. Step-by-step derivation
      1. Simplified86.5%

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -2.2 \cdot 10^{+137}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq -6.6 \cdot 10^{+76}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(B, C\right)}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq -450000:\\ \;\;\;\;\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}}\\ \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} \]

    Alternative 3: 77.8% accurate, 1.6× speedup?

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

      1. Initial program 15.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. Taylor expanded in A around -inf 82.6%

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

      if -1.3e138 < A < 1.4e-66

      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. Taylor expanded in A around 0 50.8%

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

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

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

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

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

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

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

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

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

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

      if 1.4e-66 < A

      1. Initial program 74.2%

        \[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. Applied egg-rr92.0%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -1.3 \cdot 10^{+138}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 1.4 \cdot 10^{-66}:\\ \;\;\;\;\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(B, C\right)}{B}\right) \cdot \frac{180}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{\left(-A\right) - \mathsf{hypot}\left(B, A\right)}{B}\right)}}\\ \end{array} \]

    Alternative 4: 81.0% accurate, 1.6× speedup?

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

      1. Initial program 61.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. Step-by-step derivation
        1. associate-*r/61.5%

          \[\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}} \]
        2. associate-*l/61.5%

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

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

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

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

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

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

      if 3.9000000000000002e93 < C

      1. Initial program 17.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. Taylor expanded in A around 0 20.0%

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

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

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

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

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

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;C \leq 3.9 \cdot 10^{+93}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(A - C, B\right)}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\ \end{array} \]

    Alternative 5: 75.6% accurate, 1.7× speedup?

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

      1. Initial program 82.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. Taylor expanded in B around -inf 88.7%

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

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

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

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

      if -4.0000000000000002e96 < C < 7.0000000000000001e85

      1. Initial program 57.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. Applied egg-rr83.2%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{\color{blue}{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}}{B}\right)}} \]
      8. Step-by-step derivation
        1. expm1-log1p-u37.3%

          \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}{B}\right)}}\right)\right)} \]
        2. expm1-udef37.3%

          \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}{B}\right)}}\right)} - 1} \]
        3. associate-/r/37.3%

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

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

          \[\leadsto e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot \color{blue}{0.005555555555555556}} \cdot \tan^{-1} \left(\frac{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}{B}\right)\right)} - 1 \]
        6. distribute-frac-neg37.3%

          \[\leadsto e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \tan^{-1} \color{blue}{\left(-\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)}\right)} - 1 \]
        7. atan-neg37.3%

          \[\leadsto e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \color{blue}{\left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)}\right)} - 1 \]
      9. Applied egg-rr37.3%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)\right)} - 1} \]
      10. Step-by-step derivation
        1. expm1-def37.3%

          \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)\right)\right)} \]
        2. expm1-log1p79.0%

          \[\leadsto \color{blue}{\frac{1}{\pi \cdot 0.005555555555555556} \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)} \]
        3. associate-*l/79.0%

          \[\leadsto \color{blue}{\frac{1 \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)}{\pi \cdot 0.005555555555555556}} \]
        4. *-lft-identity79.0%

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

          \[\leadsto \frac{\color{blue}{-1 \cdot \tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)}}{\pi \cdot 0.005555555555555556} \]
        6. *-commutative79.0%

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

          \[\leadsto \color{blue}{\frac{-1}{0.005555555555555556} \cdot \frac{\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)}{\pi}} \]
        8. metadata-eval79.0%

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

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

      if 7.0000000000000001e85 < C

      1. Initial program 17.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. Taylor expanded in A around 0 20.0%

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

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

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

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

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

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;C \leq -4 \cdot 10^{+96}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{elif}\;C \leq 7 \cdot 10^{+85}:\\ \;\;\;\;-180 \cdot \frac{\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\ \end{array} \]

    Alternative 6: 77.8% accurate, 1.7× speedup?

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

      1. Initial program 15.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. Taylor expanded in A around -inf 82.6%

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

      if -7.79999999999999949e140 < A < 5.00000000000000033e-64

      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. Taylor expanded in A around 0 50.8%

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

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

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

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

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

      if 5.00000000000000033e-64 < A

      1. Initial program 74.2%

        \[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. Applied egg-rr92.0%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{\color{blue}{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}}{B}\right)}} \]
      8. Step-by-step derivation
        1. expm1-log1p-u42.5%

          \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}{B}\right)}}\right)\right)} \]
        2. expm1-udef42.6%

          \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}{B}\right)}}\right)} - 1} \]
        3. associate-/r/42.6%

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

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

          \[\leadsto e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot \color{blue}{0.005555555555555556}} \cdot \tan^{-1} \left(\frac{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}{B}\right)\right)} - 1 \]
        6. distribute-frac-neg42.6%

          \[\leadsto e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \tan^{-1} \color{blue}{\left(-\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)}\right)} - 1 \]
        7. atan-neg42.6%

          \[\leadsto e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \color{blue}{\left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)}\right)} - 1 \]
      9. Applied egg-rr42.6%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)\right)} - 1} \]
      10. Step-by-step derivation
        1. expm1-def42.5%

          \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)\right)\right)} \]
        2. expm1-log1p89.5%

          \[\leadsto \color{blue}{\frac{1}{\pi \cdot 0.005555555555555556} \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)} \]
        3. associate-*l/89.5%

          \[\leadsto \color{blue}{\frac{1 \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)}{\pi \cdot 0.005555555555555556}} \]
        4. *-lft-identity89.5%

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

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

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

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

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

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -7.8 \cdot 10^{+140}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 5 \cdot 10^{-64}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(B, C\right)}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;-180 \cdot \frac{\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)}{\pi}\\ \end{array} \]

    Alternative 7: 77.8% accurate, 1.7× speedup?

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

      1. Initial program 15.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. Taylor expanded in A around -inf 82.6%

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

      if -3.8000000000000001e135 < A < 4.6000000000000003e-64

      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. Taylor expanded in A around 0 50.8%

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

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

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

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

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

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

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

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

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

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

      if 4.6000000000000003e-64 < A

      1. Initial program 74.2%

        \[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. Applied egg-rr92.0%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{\color{blue}{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}}{B}\right)}} \]
      8. Step-by-step derivation
        1. expm1-log1p-u42.5%

          \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}{B}\right)}}\right)\right)} \]
        2. expm1-udef42.6%

          \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}{B}\right)}}\right)} - 1} \]
        3. associate-/r/42.6%

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

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

          \[\leadsto e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot \color{blue}{0.005555555555555556}} \cdot \tan^{-1} \left(\frac{-\left(A + \mathsf{hypot}\left(B, A\right)\right)}{B}\right)\right)} - 1 \]
        6. distribute-frac-neg42.6%

          \[\leadsto e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \tan^{-1} \color{blue}{\left(-\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)}\right)} - 1 \]
        7. atan-neg42.6%

          \[\leadsto e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \color{blue}{\left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)}\right)} - 1 \]
      9. Applied egg-rr42.6%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)\right)} - 1} \]
      10. Step-by-step derivation
        1. expm1-def42.5%

          \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{1}{\pi \cdot 0.005555555555555556} \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)\right)\right)} \]
        2. expm1-log1p89.5%

          \[\leadsto \color{blue}{\frac{1}{\pi \cdot 0.005555555555555556} \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)} \]
        3. associate-*l/89.5%

          \[\leadsto \color{blue}{\frac{1 \cdot \left(-\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)\right)}{\pi \cdot 0.005555555555555556}} \]
        4. *-lft-identity89.5%

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

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

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

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

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

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -3.8 \cdot 10^{+135}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 4.6 \cdot 10^{-64}:\\ \;\;\;\;\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(B, C\right)}{B}\right) \cdot \frac{180}{\pi}\\ \mathbf{else}:\\ \;\;\;\;-180 \cdot \frac{\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{B}\right)}{\pi}\\ \end{array} \]

    Alternative 8: 70.0% accurate, 1.7× speedup?

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

      1. Initial program 53.2%

        \[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. add-exp-log53.2%

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

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

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

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

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

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

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

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

      if -8.79999999999999979e-308 < B < 3.8000000000000001e-221

      1. Initial program 63.2%

        \[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. associate-*r/63.2%

          \[\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}} \]
        2. associate-*l/63.2%

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(A - C, B\right)}{B}\right)}{\pi}} \]
      4. Step-by-step derivation
        1. div-sub33.6%

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

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

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

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

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

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{0}}{\pi} \]
      8. Simplified63.2%

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

      if 3.8000000000000001e-221 < B

      1. Initial program 53.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. Applied egg-rr79.6%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -8.8 \cdot 10^{-308}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(e^{\frac{C - A}{B}}\right)}{\pi}\\ \mathbf{elif}\;B \leq 3.8 \cdot 10^{-221}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 0}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{C - A}{B} + -1\right)}}\\ \end{array} \]

    Alternative 9: 56.4% accurate, 2.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{if}\;A \leq -5.2 \cdot 10^{-6}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq -2.1 \cdot 10^{-182}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;A \leq -3.9 \cdot 10^{-264}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq 8.2 \cdot 10^{-238} \lor \neg \left(A \leq 0.8\right) \land A \leq 1.6 \cdot 10^{+121}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(1 - \frac{A}{B}\right)}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (let* ((t_0 (* 180.0 (/ (atan (+ -1.0 (/ C B))) PI))))
       (if (<= A -5.2e-6)
         (* 180.0 (/ (atan (* 0.5 (/ B A))) PI))
         (if (<= A -2.1e-182)
           t_0
           (if (<= A -3.9e-264)
             (* 180.0 (/ (atan (+ 1.0 (/ C B))) PI))
             (if (or (<= A 8.2e-238) (and (not (<= A 0.8)) (<= A 1.6e+121)))
               t_0
               (/ (* 180.0 (atan (- 1.0 (/ A B)))) PI)))))))
    double code(double A, double B, double C) {
    	double t_0 = 180.0 * (atan((-1.0 + (C / B))) / ((double) M_PI));
    	double tmp;
    	if (A <= -5.2e-6) {
    		tmp = 180.0 * (atan((0.5 * (B / A))) / ((double) M_PI));
    	} else if (A <= -2.1e-182) {
    		tmp = t_0;
    	} else if (A <= -3.9e-264) {
    		tmp = 180.0 * (atan((1.0 + (C / B))) / ((double) M_PI));
    	} else if ((A <= 8.2e-238) || (!(A <= 0.8) && (A <= 1.6e+121))) {
    		tmp = t_0;
    	} else {
    		tmp = (180.0 * atan((1.0 - (A / B)))) / ((double) M_PI);
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double t_0 = 180.0 * (Math.atan((-1.0 + (C / B))) / Math.PI);
    	double tmp;
    	if (A <= -5.2e-6) {
    		tmp = 180.0 * (Math.atan((0.5 * (B / A))) / Math.PI);
    	} else if (A <= -2.1e-182) {
    		tmp = t_0;
    	} else if (A <= -3.9e-264) {
    		tmp = 180.0 * (Math.atan((1.0 + (C / B))) / Math.PI);
    	} else if ((A <= 8.2e-238) || (!(A <= 0.8) && (A <= 1.6e+121))) {
    		tmp = t_0;
    	} else {
    		tmp = (180.0 * Math.atan((1.0 - (A / B)))) / Math.PI;
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	t_0 = 180.0 * (math.atan((-1.0 + (C / B))) / math.pi)
    	tmp = 0
    	if A <= -5.2e-6:
    		tmp = 180.0 * (math.atan((0.5 * (B / A))) / math.pi)
    	elif A <= -2.1e-182:
    		tmp = t_0
    	elif A <= -3.9e-264:
    		tmp = 180.0 * (math.atan((1.0 + (C / B))) / math.pi)
    	elif (A <= 8.2e-238) or (not (A <= 0.8) and (A <= 1.6e+121)):
    		tmp = t_0
    	else:
    		tmp = (180.0 * math.atan((1.0 - (A / B)))) / math.pi
    	return tmp
    
    function code(A, B, C)
    	t_0 = Float64(180.0 * Float64(atan(Float64(-1.0 + Float64(C / B))) / pi))
    	tmp = 0.0
    	if (A <= -5.2e-6)
    		tmp = Float64(180.0 * Float64(atan(Float64(0.5 * Float64(B / A))) / pi));
    	elseif (A <= -2.1e-182)
    		tmp = t_0;
    	elseif (A <= -3.9e-264)
    		tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(C / B))) / pi));
    	elseif ((A <= 8.2e-238) || (!(A <= 0.8) && (A <= 1.6e+121)))
    		tmp = t_0;
    	else
    		tmp = Float64(Float64(180.0 * atan(Float64(1.0 - Float64(A / B)))) / pi);
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	t_0 = 180.0 * (atan((-1.0 + (C / B))) / pi);
    	tmp = 0.0;
    	if (A <= -5.2e-6)
    		tmp = 180.0 * (atan((0.5 * (B / A))) / pi);
    	elseif (A <= -2.1e-182)
    		tmp = t_0;
    	elseif (A <= -3.9e-264)
    		tmp = 180.0 * (atan((1.0 + (C / B))) / pi);
    	elseif ((A <= 8.2e-238) || (~((A <= 0.8)) && (A <= 1.6e+121)))
    		tmp = t_0;
    	else
    		tmp = (180.0 * atan((1.0 - (A / B)))) / pi;
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := Block[{t$95$0 = N[(180.0 * N[(N[ArcTan[N[(-1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[A, -5.2e-6], N[(180.0 * N[(N[ArcTan[N[(0.5 * N[(B / A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -2.1e-182], t$95$0, If[LessEqual[A, -3.9e-264], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[A, 8.2e-238], And[N[Not[LessEqual[A, 0.8]], $MachinePrecision], LessEqual[A, 1.6e+121]]], t$95$0, N[(N[(180.0 * N[ArcTan[N[(1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]]]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_0 := 180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\
    \mathbf{if}\;A \leq -5.2 \cdot 10^{-6}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\
    
    \mathbf{elif}\;A \leq -2.1 \cdot 10^{-182}:\\
    \;\;\;\;t_0\\
    
    \mathbf{elif}\;A \leq -3.9 \cdot 10^{-264}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\
    
    \mathbf{elif}\;A \leq 8.2 \cdot 10^{-238} \lor \neg \left(A \leq 0.8\right) \land A \leq 1.6 \cdot 10^{+121}:\\
    \;\;\;\;t_0\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{180 \cdot \tan^{-1} \left(1 - \frac{A}{B}\right)}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 4 regimes
    2. if A < -5.20000000000000019e-6

      1. Initial program 19.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. Taylor expanded in A around -inf 70.4%

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

      if -5.20000000000000019e-6 < A < -2.1e-182 or -3.8999999999999999e-264 < A < 8.2000000000000002e-238 or 0.80000000000000004 < A < 1.6e121

      1. Initial program 58.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. Taylor expanded in A around 0 50.6%

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

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

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

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

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

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

      if -2.1e-182 < A < -3.8999999999999999e-264

      1. Initial program 45.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. Taylor expanded in A around 0 46.2%

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

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

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

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

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

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

      if 8.2000000000000002e-238 < A < 0.80000000000000004 or 1.6e121 < A

      1. Initial program 75.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. Step-by-step derivation
        1. associate-*r/75.9%

          \[\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}} \]
        2. associate-*l/75.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -5.2 \cdot 10^{-6}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq -2.1 \cdot 10^{-182}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq -3.9 \cdot 10^{-264}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq 8.2 \cdot 10^{-238} \lor \neg \left(A \leq 0.8\right) \land A \leq 1.6 \cdot 10^{+121}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(1 - \frac{A}{B}\right)}{\pi}\\ \end{array} \]

    Alternative 10: 56.4% accurate, 2.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\ t_1 := 180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{if}\;A \leq -5.2 \cdot 10^{-6}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq -5.4 \cdot 10^{-182}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;A \leq -3.5 \cdot 10^{-264}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;A \leq 1.8 \cdot 10^{-241}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;A \leq 5.8 \cdot 10^{-6}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;A \leq 1.6 \cdot 10^{+121}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (let* ((t_0 (* 180.0 (/ (atan (+ -1.0 (/ C B))) PI)))
            (t_1 (* 180.0 (/ (atan (+ 1.0 (/ C B))) PI))))
       (if (<= A -5.2e-6)
         (* 180.0 (/ (atan (* 0.5 (/ B A))) PI))
         (if (<= A -5.4e-182)
           t_0
           (if (<= A -3.5e-264)
             t_1
             (if (<= A 1.8e-241)
               t_0
               (if (<= A 5.8e-6)
                 t_1
                 (if (<= A 1.6e+121)
                   t_0
                   (* 180.0 (/ (atan (* -2.0 (/ A B))) PI))))))))))
    double code(double A, double B, double C) {
    	double t_0 = 180.0 * (atan((-1.0 + (C / B))) / ((double) M_PI));
    	double t_1 = 180.0 * (atan((1.0 + (C / B))) / ((double) M_PI));
    	double tmp;
    	if (A <= -5.2e-6) {
    		tmp = 180.0 * (atan((0.5 * (B / A))) / ((double) M_PI));
    	} else if (A <= -5.4e-182) {
    		tmp = t_0;
    	} else if (A <= -3.5e-264) {
    		tmp = t_1;
    	} else if (A <= 1.8e-241) {
    		tmp = t_0;
    	} else if (A <= 5.8e-6) {
    		tmp = t_1;
    	} else if (A <= 1.6e+121) {
    		tmp = t_0;
    	} else {
    		tmp = 180.0 * (atan((-2.0 * (A / B))) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double t_0 = 180.0 * (Math.atan((-1.0 + (C / B))) / Math.PI);
    	double t_1 = 180.0 * (Math.atan((1.0 + (C / B))) / Math.PI);
    	double tmp;
    	if (A <= -5.2e-6) {
    		tmp = 180.0 * (Math.atan((0.5 * (B / A))) / Math.PI);
    	} else if (A <= -5.4e-182) {
    		tmp = t_0;
    	} else if (A <= -3.5e-264) {
    		tmp = t_1;
    	} else if (A <= 1.8e-241) {
    		tmp = t_0;
    	} else if (A <= 5.8e-6) {
    		tmp = t_1;
    	} else if (A <= 1.6e+121) {
    		tmp = t_0;
    	} else {
    		tmp = 180.0 * (Math.atan((-2.0 * (A / B))) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	t_0 = 180.0 * (math.atan((-1.0 + (C / B))) / math.pi)
    	t_1 = 180.0 * (math.atan((1.0 + (C / B))) / math.pi)
    	tmp = 0
    	if A <= -5.2e-6:
    		tmp = 180.0 * (math.atan((0.5 * (B / A))) / math.pi)
    	elif A <= -5.4e-182:
    		tmp = t_0
    	elif A <= -3.5e-264:
    		tmp = t_1
    	elif A <= 1.8e-241:
    		tmp = t_0
    	elif A <= 5.8e-6:
    		tmp = t_1
    	elif A <= 1.6e+121:
    		tmp = t_0
    	else:
    		tmp = 180.0 * (math.atan((-2.0 * (A / B))) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	t_0 = Float64(180.0 * Float64(atan(Float64(-1.0 + Float64(C / B))) / pi))
    	t_1 = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(C / B))) / pi))
    	tmp = 0.0
    	if (A <= -5.2e-6)
    		tmp = Float64(180.0 * Float64(atan(Float64(0.5 * Float64(B / A))) / pi));
    	elseif (A <= -5.4e-182)
    		tmp = t_0;
    	elseif (A <= -3.5e-264)
    		tmp = t_1;
    	elseif (A <= 1.8e-241)
    		tmp = t_0;
    	elseif (A <= 5.8e-6)
    		tmp = t_1;
    	elseif (A <= 1.6e+121)
    		tmp = t_0;
    	else
    		tmp = Float64(180.0 * Float64(atan(Float64(-2.0 * Float64(A / B))) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	t_0 = 180.0 * (atan((-1.0 + (C / B))) / pi);
    	t_1 = 180.0 * (atan((1.0 + (C / B))) / pi);
    	tmp = 0.0;
    	if (A <= -5.2e-6)
    		tmp = 180.0 * (atan((0.5 * (B / A))) / pi);
    	elseif (A <= -5.4e-182)
    		tmp = t_0;
    	elseif (A <= -3.5e-264)
    		tmp = t_1;
    	elseif (A <= 1.8e-241)
    		tmp = t_0;
    	elseif (A <= 5.8e-6)
    		tmp = t_1;
    	elseif (A <= 1.6e+121)
    		tmp = t_0;
    	else
    		tmp = 180.0 * (atan((-2.0 * (A / B))) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := Block[{t$95$0 = N[(180.0 * N[(N[ArcTan[N[(-1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[A, -5.2e-6], N[(180.0 * N[(N[ArcTan[N[(0.5 * N[(B / A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -5.4e-182], t$95$0, If[LessEqual[A, -3.5e-264], t$95$1, If[LessEqual[A, 1.8e-241], t$95$0, If[LessEqual[A, 5.8e-6], t$95$1, If[LessEqual[A, 1.6e+121], t$95$0, N[(180.0 * N[(N[ArcTan[N[(-2.0 * N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]]]]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_0 := 180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\
    t_1 := 180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\
    \mathbf{if}\;A \leq -5.2 \cdot 10^{-6}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\
    
    \mathbf{elif}\;A \leq -5.4 \cdot 10^{-182}:\\
    \;\;\;\;t_0\\
    
    \mathbf{elif}\;A \leq -3.5 \cdot 10^{-264}:\\
    \;\;\;\;t_1\\
    
    \mathbf{elif}\;A \leq 1.8 \cdot 10^{-241}:\\
    \;\;\;\;t_0\\
    
    \mathbf{elif}\;A \leq 5.8 \cdot 10^{-6}:\\
    \;\;\;\;t_1\\
    
    \mathbf{elif}\;A \leq 1.6 \cdot 10^{+121}:\\
    \;\;\;\;t_0\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 4 regimes
    2. if A < -5.20000000000000019e-6

      1. Initial program 19.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. Taylor expanded in A around -inf 70.4%

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

      if -5.20000000000000019e-6 < A < -5.39999999999999999e-182 or -3.5e-264 < A < 1.7999999999999999e-241 or 5.8000000000000004e-6 < A < 1.6e121

      1. Initial program 59.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. Taylor expanded in A around 0 50.5%

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

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

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

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

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

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

      if -5.39999999999999999e-182 < A < -3.5e-264 or 1.7999999999999999e-241 < A < 5.8000000000000004e-6

      1. Initial program 58.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. Taylor expanded in A around 0 51.5%

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

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

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

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

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

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

      if 1.6e121 < A

      1. Initial program 88.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. Taylor expanded in A around inf 88.6%

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -5.2 \cdot 10^{-6}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq -5.4 \cdot 10^{-182}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq -3.5 \cdot 10^{-264}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq 1.8 \cdot 10^{-241}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq 5.8 \cdot 10^{-6}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq 1.6 \cdot 10^{+121}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\ \end{array} \]

    Alternative 11: 61.0% accurate, 2.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{if}\;A \leq -3.4 \cdot 10^{-5}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq -1.05 \cdot 10^{-181}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;A \leq -4.5 \cdot 10^{-264}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq 5 \cdot 10^{-243}:\\ \;\;\;\;t_0\\ \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
     (let* ((t_0 (* 180.0 (/ (atan (+ -1.0 (/ C B))) PI))))
       (if (<= A -3.4e-5)
         (* 180.0 (/ (atan (* 0.5 (/ B A))) PI))
         (if (<= A -1.05e-181)
           t_0
           (if (<= A -4.5e-264)
             (* 180.0 (/ (atan (+ 1.0 (/ C B))) PI))
             (if (<= A 5e-243)
               t_0
               (* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI))))))))
    double code(double A, double B, double C) {
    	double t_0 = 180.0 * (atan((-1.0 + (C / B))) / ((double) M_PI));
    	double tmp;
    	if (A <= -3.4e-5) {
    		tmp = 180.0 * (atan((0.5 * (B / A))) / ((double) M_PI));
    	} else if (A <= -1.05e-181) {
    		tmp = t_0;
    	} else if (A <= -4.5e-264) {
    		tmp = 180.0 * (atan((1.0 + (C / B))) / ((double) M_PI));
    	} else if (A <= 5e-243) {
    		tmp = t_0;
    	} 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 t_0 = 180.0 * (Math.atan((-1.0 + (C / B))) / Math.PI);
    	double tmp;
    	if (A <= -3.4e-5) {
    		tmp = 180.0 * (Math.atan((0.5 * (B / A))) / Math.PI);
    	} else if (A <= -1.05e-181) {
    		tmp = t_0;
    	} else if (A <= -4.5e-264) {
    		tmp = 180.0 * (Math.atan((1.0 + (C / B))) / Math.PI);
    	} else if (A <= 5e-243) {
    		tmp = t_0;
    	} else {
    		tmp = 180.0 * (Math.atan((1.0 + ((C - A) / B))) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	t_0 = 180.0 * (math.atan((-1.0 + (C / B))) / math.pi)
    	tmp = 0
    	if A <= -3.4e-5:
    		tmp = 180.0 * (math.atan((0.5 * (B / A))) / math.pi)
    	elif A <= -1.05e-181:
    		tmp = t_0
    	elif A <= -4.5e-264:
    		tmp = 180.0 * (math.atan((1.0 + (C / B))) / math.pi)
    	elif A <= 5e-243:
    		tmp = t_0
    	else:
    		tmp = 180.0 * (math.atan((1.0 + ((C - A) / B))) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	t_0 = Float64(180.0 * Float64(atan(Float64(-1.0 + Float64(C / B))) / pi))
    	tmp = 0.0
    	if (A <= -3.4e-5)
    		tmp = Float64(180.0 * Float64(atan(Float64(0.5 * Float64(B / A))) / pi));
    	elseif (A <= -1.05e-181)
    		tmp = t_0;
    	elseif (A <= -4.5e-264)
    		tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(C / B))) / pi));
    	elseif (A <= 5e-243)
    		tmp = t_0;
    	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)
    	t_0 = 180.0 * (atan((-1.0 + (C / B))) / pi);
    	tmp = 0.0;
    	if (A <= -3.4e-5)
    		tmp = 180.0 * (atan((0.5 * (B / A))) / pi);
    	elseif (A <= -1.05e-181)
    		tmp = t_0;
    	elseif (A <= -4.5e-264)
    		tmp = 180.0 * (atan((1.0 + (C / B))) / pi);
    	elseif (A <= 5e-243)
    		tmp = t_0;
    	else
    		tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := Block[{t$95$0 = N[(180.0 * N[(N[ArcTan[N[(-1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[A, -3.4e-5], N[(180.0 * N[(N[ArcTan[N[(0.5 * N[(B / A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -1.05e-181], t$95$0, If[LessEqual[A, -4.5e-264], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, 5e-243], t$95$0, 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}
    t_0 := 180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\
    \mathbf{if}\;A \leq -3.4 \cdot 10^{-5}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\
    
    \mathbf{elif}\;A \leq -1.05 \cdot 10^{-181}:\\
    \;\;\;\;t_0\\
    
    \mathbf{elif}\;A \leq -4.5 \cdot 10^{-264}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\
    
    \mathbf{elif}\;A \leq 5 \cdot 10^{-243}:\\
    \;\;\;\;t_0\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 4 regimes
    2. if A < -3.4e-5

      1. Initial program 19.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. Taylor expanded in A around -inf 70.4%

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

      if -3.4e-5 < A < -1.05000000000000002e-181 or -4.5000000000000001e-264 < A < 5e-243

      1. Initial program 55.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. Taylor expanded in A around 0 54.5%

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

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

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

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

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

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

      if -1.05000000000000002e-181 < A < -4.5000000000000001e-264

      1. Initial program 45.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. Taylor expanded in A around 0 46.2%

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

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

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

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

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

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

      if 5e-243 < A

      1. Initial program 72.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. Taylor expanded in B around -inf 67.2%

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

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

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

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -3.4 \cdot 10^{-5}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq -1.05 \cdot 10^{-181}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq -4.5 \cdot 10^{-264}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq 5 \cdot 10^{-243}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \end{array} \]

    Alternative 12: 46.9% accurate, 2.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\ \mathbf{if}\;B \leq -1550000:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq -4.7 \cdot 10^{-287}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq 5.5 \cdot 10^{-219}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 0}{\pi}\\ \mathbf{elif}\;B \leq 3.2 \cdot 10^{-26}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (let* ((t_0 (* 180.0 (/ (atan (* -2.0 (/ A B))) PI))))
       (if (<= B -1550000.0)
         (* 180.0 (/ (atan 1.0) PI))
         (if (<= B -4.7e-287)
           t_0
           (if (<= B 5.5e-219)
             (/ (* 180.0 (atan 0.0)) PI)
             (if (<= B 3.2e-26) t_0 (* 180.0 (/ (atan -1.0) PI))))))))
    double code(double A, double B, double C) {
    	double t_0 = 180.0 * (atan((-2.0 * (A / B))) / ((double) M_PI));
    	double tmp;
    	if (B <= -1550000.0) {
    		tmp = 180.0 * (atan(1.0) / ((double) M_PI));
    	} else if (B <= -4.7e-287) {
    		tmp = t_0;
    	} else if (B <= 5.5e-219) {
    		tmp = (180.0 * atan(0.0)) / ((double) M_PI);
    	} else if (B <= 3.2e-26) {
    		tmp = t_0;
    	} else {
    		tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double t_0 = 180.0 * (Math.atan((-2.0 * (A / B))) / Math.PI);
    	double tmp;
    	if (B <= -1550000.0) {
    		tmp = 180.0 * (Math.atan(1.0) / Math.PI);
    	} else if (B <= -4.7e-287) {
    		tmp = t_0;
    	} else if (B <= 5.5e-219) {
    		tmp = (180.0 * Math.atan(0.0)) / Math.PI;
    	} else if (B <= 3.2e-26) {
    		tmp = t_0;
    	} else {
    		tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	t_0 = 180.0 * (math.atan((-2.0 * (A / B))) / math.pi)
    	tmp = 0
    	if B <= -1550000.0:
    		tmp = 180.0 * (math.atan(1.0) / math.pi)
    	elif B <= -4.7e-287:
    		tmp = t_0
    	elif B <= 5.5e-219:
    		tmp = (180.0 * math.atan(0.0)) / math.pi
    	elif B <= 3.2e-26:
    		tmp = t_0
    	else:
    		tmp = 180.0 * (math.atan(-1.0) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	t_0 = Float64(180.0 * Float64(atan(Float64(-2.0 * Float64(A / B))) / pi))
    	tmp = 0.0
    	if (B <= -1550000.0)
    		tmp = Float64(180.0 * Float64(atan(1.0) / pi));
    	elseif (B <= -4.7e-287)
    		tmp = t_0;
    	elseif (B <= 5.5e-219)
    		tmp = Float64(Float64(180.0 * atan(0.0)) / pi);
    	elseif (B <= 3.2e-26)
    		tmp = t_0;
    	else
    		tmp = Float64(180.0 * Float64(atan(-1.0) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	t_0 = 180.0 * (atan((-2.0 * (A / B))) / pi);
    	tmp = 0.0;
    	if (B <= -1550000.0)
    		tmp = 180.0 * (atan(1.0) / pi);
    	elseif (B <= -4.7e-287)
    		tmp = t_0;
    	elseif (B <= 5.5e-219)
    		tmp = (180.0 * atan(0.0)) / pi;
    	elseif (B <= 3.2e-26)
    		tmp = t_0;
    	else
    		tmp = 180.0 * (atan(-1.0) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := Block[{t$95$0 = N[(180.0 * N[(N[ArcTan[N[(-2.0 * N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[B, -1550000.0], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, -4.7e-287], t$95$0, If[LessEqual[B, 5.5e-219], N[(N[(180.0 * N[ArcTan[0.0], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], If[LessEqual[B, 3.2e-26], t$95$0, N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_0 := 180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\
    \mathbf{if}\;B \leq -1550000:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
    
    \mathbf{elif}\;B \leq -4.7 \cdot 10^{-287}:\\
    \;\;\;\;t_0\\
    
    \mathbf{elif}\;B \leq 5.5 \cdot 10^{-219}:\\
    \;\;\;\;\frac{180 \cdot \tan^{-1} 0}{\pi}\\
    
    \mathbf{elif}\;B \leq 3.2 \cdot 10^{-26}:\\
    \;\;\;\;t_0\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 4 regimes
    2. if B < -1.55e6

      1. Initial program 42.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. Taylor expanded in B around -inf 57.8%

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

      if -1.55e6 < B < -4.6999999999999999e-287 or 5.50000000000000017e-219 < B < 3.2000000000000001e-26

      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. Taylor expanded in A around inf 39.6%

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

      if -4.6999999999999999e-287 < B < 5.50000000000000017e-219

      1. Initial program 61.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. Step-by-step derivation
        1. associate-*r/61.4%

          \[\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}} \]
        2. associate-*l/61.4%

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(A - C, B\right)}{B}\right)}{\pi}} \]
      4. Step-by-step derivation
        1. div-sub36.2%

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

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

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

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

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

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{0}}{\pi} \]
      8. Simplified61.4%

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

      if 3.2000000000000001e-26 < B

      1. Initial program 47.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. Taylor expanded in B around inf 64.9%

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -1550000:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq -4.7 \cdot 10^{-287}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 5.5 \cdot 10^{-219}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 0}{\pi}\\ \mathbf{elif}\;B \leq 3.2 \cdot 10^{-26}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \]

    Alternative 13: 47.4% accurate, 2.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -880000:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq 6.8 \cdot 10^{-299}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 3.1 \cdot 10^{-222}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\ \mathbf{elif}\;B \leq 6.2 \cdot 10^{-30}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= B -880000.0)
       (* 180.0 (/ (atan 1.0) PI))
       (if (<= B 6.8e-299)
         (* 180.0 (/ (atan (* -2.0 (/ A B))) PI))
         (if (<= B 3.1e-222)
           (* 180.0 (/ (atan (* -0.5 (/ B C))) PI))
           (if (<= B 6.2e-30)
             (* 180.0 (/ (atan (* 0.5 (/ B A))) PI))
             (* 180.0 (/ (atan -1.0) PI)))))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (B <= -880000.0) {
    		tmp = 180.0 * (atan(1.0) / ((double) M_PI));
    	} else if (B <= 6.8e-299) {
    		tmp = 180.0 * (atan((-2.0 * (A / B))) / ((double) M_PI));
    	} else if (B <= 3.1e-222) {
    		tmp = 180.0 * (atan((-0.5 * (B / C))) / ((double) M_PI));
    	} else if (B <= 6.2e-30) {
    		tmp = 180.0 * (atan((0.5 * (B / A))) / ((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 <= -880000.0) {
    		tmp = 180.0 * (Math.atan(1.0) / Math.PI);
    	} else if (B <= 6.8e-299) {
    		tmp = 180.0 * (Math.atan((-2.0 * (A / B))) / Math.PI);
    	} else if (B <= 3.1e-222) {
    		tmp = 180.0 * (Math.atan((-0.5 * (B / C))) / Math.PI);
    	} else if (B <= 6.2e-30) {
    		tmp = 180.0 * (Math.atan((0.5 * (B / A))) / Math.PI);
    	} else {
    		tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if B <= -880000.0:
    		tmp = 180.0 * (math.atan(1.0) / math.pi)
    	elif B <= 6.8e-299:
    		tmp = 180.0 * (math.atan((-2.0 * (A / B))) / math.pi)
    	elif B <= 3.1e-222:
    		tmp = 180.0 * (math.atan((-0.5 * (B / C))) / math.pi)
    	elif B <= 6.2e-30:
    		tmp = 180.0 * (math.atan((0.5 * (B / A))) / math.pi)
    	else:
    		tmp = 180.0 * (math.atan(-1.0) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (B <= -880000.0)
    		tmp = Float64(180.0 * Float64(atan(1.0) / pi));
    	elseif (B <= 6.8e-299)
    		tmp = Float64(180.0 * Float64(atan(Float64(-2.0 * Float64(A / B))) / pi));
    	elseif (B <= 3.1e-222)
    		tmp = Float64(180.0 * Float64(atan(Float64(-0.5 * Float64(B / C))) / pi));
    	elseif (B <= 6.2e-30)
    		tmp = Float64(180.0 * Float64(atan(Float64(0.5 * Float64(B / A))) / 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 <= -880000.0)
    		tmp = 180.0 * (atan(1.0) / pi);
    	elseif (B <= 6.8e-299)
    		tmp = 180.0 * (atan((-2.0 * (A / B))) / pi);
    	elseif (B <= 3.1e-222)
    		tmp = 180.0 * (atan((-0.5 * (B / C))) / pi);
    	elseif (B <= 6.2e-30)
    		tmp = 180.0 * (atan((0.5 * (B / A))) / pi);
    	else
    		tmp = 180.0 * (atan(-1.0) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[B, -880000.0], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 6.8e-299], N[(180.0 * N[(N[ArcTan[N[(-2.0 * N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 3.1e-222], N[(180.0 * N[(N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 6.2e-30], N[(180.0 * N[(N[ArcTan[N[(0.5 * N[(B / A), $MachinePrecision]), $MachinePrecision]], $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 -880000:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
    
    \mathbf{elif}\;B \leq 6.8 \cdot 10^{-299}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\
    
    \mathbf{elif}\;B \leq 3.1 \cdot 10^{-222}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\
    
    \mathbf{elif}\;B \leq 6.2 \cdot 10^{-30}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 5 regimes
    2. if B < -8.8e5

      1. Initial program 42.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. Taylor expanded in B around -inf 57.8%

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

      if -8.8e5 < B < 6.7999999999999996e-299

      1. Initial program 66.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. Taylor expanded in A around inf 46.3%

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

      if 6.7999999999999996e-299 < B < 3.09999999999999979e-222

      1. Initial program 67.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. Taylor expanded in A around 0 41.7%

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

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

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

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

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

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

      if 3.09999999999999979e-222 < B < 6.19999999999999982e-30

      1. Initial program 62.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. Taylor expanded in A around -inf 43.2%

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

      if 6.19999999999999982e-30 < B

      1. Initial program 48.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. Taylor expanded in B around inf 64.3%

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -880000:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq 6.8 \cdot 10^{-299}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 3.1 \cdot 10^{-222}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\ \mathbf{elif}\;B \leq 6.2 \cdot 10^{-30}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \]

    Alternative 14: 55.6% accurate, 2.4× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{if}\;A \leq -4.2 \cdot 10^{-14}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq -1.3 \cdot 10^{-265}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;A \leq 5.8 \cdot 10^{-241}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \mathbf{elif}\;A \leq 5.8 \cdot 10^{+49}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (let* ((t_0 (* 180.0 (/ (atan (+ 1.0 (/ C B))) PI))))
       (if (<= A -4.2e-14)
         (* 180.0 (/ (atan (* 0.5 (/ B A))) PI))
         (if (<= A -1.3e-265)
           t_0
           (if (<= A 5.8e-241)
             (* 180.0 (/ (atan -1.0) PI))
             (if (<= A 5.8e+49) t_0 (* 180.0 (/ (atan (* -2.0 (/ A B))) PI))))))))
    double code(double A, double B, double C) {
    	double t_0 = 180.0 * (atan((1.0 + (C / B))) / ((double) M_PI));
    	double tmp;
    	if (A <= -4.2e-14) {
    		tmp = 180.0 * (atan((0.5 * (B / A))) / ((double) M_PI));
    	} else if (A <= -1.3e-265) {
    		tmp = t_0;
    	} else if (A <= 5.8e-241) {
    		tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
    	} else if (A <= 5.8e+49) {
    		tmp = t_0;
    	} else {
    		tmp = 180.0 * (atan((-2.0 * (A / B))) / ((double) M_PI));
    	}
    	return tmp;
    }
    
    public static double code(double A, double B, double C) {
    	double t_0 = 180.0 * (Math.atan((1.0 + (C / B))) / Math.PI);
    	double tmp;
    	if (A <= -4.2e-14) {
    		tmp = 180.0 * (Math.atan((0.5 * (B / A))) / Math.PI);
    	} else if (A <= -1.3e-265) {
    		tmp = t_0;
    	} else if (A <= 5.8e-241) {
    		tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
    	} else if (A <= 5.8e+49) {
    		tmp = t_0;
    	} else {
    		tmp = 180.0 * (Math.atan((-2.0 * (A / B))) / Math.PI);
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	t_0 = 180.0 * (math.atan((1.0 + (C / B))) / math.pi)
    	tmp = 0
    	if A <= -4.2e-14:
    		tmp = 180.0 * (math.atan((0.5 * (B / A))) / math.pi)
    	elif A <= -1.3e-265:
    		tmp = t_0
    	elif A <= 5.8e-241:
    		tmp = 180.0 * (math.atan(-1.0) / math.pi)
    	elif A <= 5.8e+49:
    		tmp = t_0
    	else:
    		tmp = 180.0 * (math.atan((-2.0 * (A / B))) / math.pi)
    	return tmp
    
    function code(A, B, C)
    	t_0 = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(C / B))) / pi))
    	tmp = 0.0
    	if (A <= -4.2e-14)
    		tmp = Float64(180.0 * Float64(atan(Float64(0.5 * Float64(B / A))) / pi));
    	elseif (A <= -1.3e-265)
    		tmp = t_0;
    	elseif (A <= 5.8e-241)
    		tmp = Float64(180.0 * Float64(atan(-1.0) / pi));
    	elseif (A <= 5.8e+49)
    		tmp = t_0;
    	else
    		tmp = Float64(180.0 * Float64(atan(Float64(-2.0 * Float64(A / B))) / pi));
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	t_0 = 180.0 * (atan((1.0 + (C / B))) / pi);
    	tmp = 0.0;
    	if (A <= -4.2e-14)
    		tmp = 180.0 * (atan((0.5 * (B / A))) / pi);
    	elseif (A <= -1.3e-265)
    		tmp = t_0;
    	elseif (A <= 5.8e-241)
    		tmp = 180.0 * (atan(-1.0) / pi);
    	elseif (A <= 5.8e+49)
    		tmp = t_0;
    	else
    		tmp = 180.0 * (atan((-2.0 * (A / B))) / pi);
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := Block[{t$95$0 = N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[A, -4.2e-14], N[(180.0 * N[(N[ArcTan[N[(0.5 * N[(B / A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -1.3e-265], t$95$0, If[LessEqual[A, 5.8e-241], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, 5.8e+49], t$95$0, N[(180.0 * N[(N[ArcTan[N[(-2.0 * N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_0 := 180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\
    \mathbf{if}\;A \leq -4.2 \cdot 10^{-14}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\
    
    \mathbf{elif}\;A \leq -1.3 \cdot 10^{-265}:\\
    \;\;\;\;t_0\\
    
    \mathbf{elif}\;A \leq 5.8 \cdot 10^{-241}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
    
    \mathbf{elif}\;A \leq 5.8 \cdot 10^{+49}:\\
    \;\;\;\;t_0\\
    
    \mathbf{else}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 4 regimes
    2. if A < -4.1999999999999998e-14

      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. Taylor expanded in A around -inf 68.5%

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

      if -4.1999999999999998e-14 < A < -1.30000000000000005e-265 or 5.7999999999999998e-241 < A < 5.8e49

      1. Initial program 59.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. Taylor expanded in A around 0 53.0%

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

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

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

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

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

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

      if -1.30000000000000005e-265 < A < 5.7999999999999998e-241

      1. Initial program 60.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. Taylor expanded in B around inf 53.2%

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

      if 5.8e49 < A

      1. Initial program 77.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. Taylor expanded in A around inf 73.1%

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -4.2 \cdot 10^{-14}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq -1.3 \cdot 10^{-265}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{elif}\;A \leq 5.8 \cdot 10^{-241}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \mathbf{elif}\;A \leq 5.8 \cdot 10^{+49}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\ \end{array} \]

    Alternative 15: 64.4% accurate, 2.4× speedup?

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

      1. Initial program 53.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. Step-by-step derivation
        1. associate-*r/53.3%

          \[\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}} \]
        2. associate-*l/53.3%

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

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

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

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

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

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

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

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

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

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

      if -4.50000000000000017e-287 < B < 1.50000000000000009e-220

      1. Initial program 61.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. Step-by-step derivation
        1. associate-*r/61.4%

          \[\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}} \]
        2. associate-*l/61.4%

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(A - C, B\right)}{B}\right)}{\pi}} \]
      4. Step-by-step derivation
        1. div-sub36.2%

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

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

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

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

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

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{0}}{\pi} \]
      8. Simplified61.4%

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

      if 1.50000000000000009e-220 < B

      1. Initial program 53.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. Applied egg-rr79.6%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -4.5 \cdot 10^{-287}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 1.5 \cdot 10^{-220}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 0}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\frac{\frac{\pi}{180}}{\tan^{-1} \left(\frac{C - A}{B} + -1\right)}}\\ \end{array} \]

    Alternative 16: 64.4% accurate, 2.4× speedup?

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

      1. Initial program 53.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. Taylor expanded in B around -inf 67.8%

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

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

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

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

      if -4.2999999999999999e-287 < B < 2.80000000000000019e-221

      1. Initial program 61.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. Step-by-step derivation
        1. associate-*r/61.4%

          \[\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}} \]
        2. associate-*l/61.4%

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(A - C, B\right)}{B}\right)}{\pi}} \]
      4. Step-by-step derivation
        1. div-sub36.2%

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

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

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

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

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

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{0}}{\pi} \]
      8. Simplified61.4%

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

      if 2.80000000000000019e-221 < B

      1. Initial program 53.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. Step-by-step derivation
        1. Simplified75.8%

          \[\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. Taylor expanded in B around inf 71.8%

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

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

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

        \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -4.3 \cdot 10^{-287}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 2.8 \cdot 10^{-221}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 0}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \left(A + B\right)}{B}\right)}{\pi}\\ \end{array} \]

      Alternative 17: 64.4% accurate, 2.4× speedup?

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

        1. Initial program 53.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. Step-by-step derivation
          1. associate-*r/53.3%

            \[\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}} \]
          2. associate-*l/53.3%

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

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

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

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

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

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

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

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

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

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

        if -6.7999999999999997e-287 < B < 2.7e-221

        1. Initial program 61.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. Step-by-step derivation
          1. associate-*r/61.4%

            \[\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}} \]
          2. associate-*l/61.4%

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

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

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

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

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

          \[\leadsto \color{blue}{\frac{180 \cdot \tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(A - C, B\right)}{B}\right)}{\pi}} \]
        4. Step-by-step derivation
          1. div-sub36.2%

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

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

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

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

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

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

            \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{0}}{\pi} \]
        8. Simplified61.4%

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

        if 2.7e-221 < B

        1. Initial program 53.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. Step-by-step derivation
          1. Simplified75.8%

            \[\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. Taylor expanded in B around inf 71.8%

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

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

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

          \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -6.8 \cdot 10^{-287}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 2.7 \cdot 10^{-221}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 0}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \left(A + B\right)}{B}\right)}{\pi}\\ \end{array} \]

        Alternative 18: 45.1% accurate, 2.5× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -4.8 \cdot 10^{-179}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq 2.05 \cdot 10^{-134}:\\ \;\;\;\;\frac{180 \cdot \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 -4.8e-179)
           (* 180.0 (/ (atan 1.0) PI))
           (if (<= B 2.05e-134)
             (/ (* 180.0 (atan 0.0)) PI)
             (* 180.0 (/ (atan -1.0) PI)))))
        double code(double A, double B, double C) {
        	double tmp;
        	if (B <= -4.8e-179) {
        		tmp = 180.0 * (atan(1.0) / ((double) M_PI));
        	} else if (B <= 2.05e-134) {
        		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 <= -4.8e-179) {
        		tmp = 180.0 * (Math.atan(1.0) / Math.PI);
        	} else if (B <= 2.05e-134) {
        		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 <= -4.8e-179:
        		tmp = 180.0 * (math.atan(1.0) / math.pi)
        	elif B <= 2.05e-134:
        		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 <= -4.8e-179)
        		tmp = Float64(180.0 * Float64(atan(1.0) / pi));
        	elseif (B <= 2.05e-134)
        		tmp = Float64(Float64(180.0 * 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 <= -4.8e-179)
        		tmp = 180.0 * (atan(1.0) / pi);
        	elseif (B <= 2.05e-134)
        		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, -4.8e-179], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 2.05e-134], N[(N[(180.0 * N[ArcTan[0.0], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        \mathbf{if}\;B \leq -4.8 \cdot 10^{-179}:\\
        \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
        
        \mathbf{elif}\;B \leq 2.05 \cdot 10^{-134}:\\
        \;\;\;\;\frac{180 \cdot \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 < -4.8000000000000001e-179

          1. Initial program 52.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. Taylor expanded in B around -inf 45.6%

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

          if -4.8000000000000001e-179 < B < 2.0500000000000001e-134

          1. Initial program 58.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. Step-by-step derivation
            1. associate-*r/58.9%

              \[\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}} \]
            2. associate-*l/58.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          if 2.0500000000000001e-134 < B

          1. Initial program 53.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. Taylor expanded in B around inf 53.9%

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

          \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -4.8 \cdot 10^{-179}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq 2.05 \cdot 10^{-134}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 0}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \]

        Alternative 19: 39.9% accurate, 2.5× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -8.8 \cdot 10^{-308}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \end{array} \]
        (FPCore (A B C)
         :precision binary64
         (if (<= B -8.8e-308)
           (* 180.0 (/ (atan 1.0) PI))
           (* 180.0 (/ (atan -1.0) PI))))
        double code(double A, double B, double C) {
        	double tmp;
        	if (B <= -8.8e-308) {
        		tmp = 180.0 * (atan(1.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 <= -8.8e-308) {
        		tmp = 180.0 * (Math.atan(1.0) / Math.PI);
        	} else {
        		tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
        	}
        	return tmp;
        }
        
        def code(A, B, C):
        	tmp = 0
        	if B <= -8.8e-308:
        		tmp = 180.0 * (math.atan(1.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 <= -8.8e-308)
        		tmp = Float64(180.0 * Float64(atan(1.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 <= -8.8e-308)
        		tmp = 180.0 * (atan(1.0) / pi);
        	else
        		tmp = 180.0 * (atan(-1.0) / pi);
        	end
        	tmp_2 = tmp;
        end
        
        code[A_, B_, C_] := If[LessEqual[B, -8.8e-308], N[(180.0 * N[(N[ArcTan[1.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 -8.8 \cdot 10^{-308}:\\
        \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
        
        \mathbf{else}:\\
        \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if B < -8.79999999999999979e-308

          1. Initial program 53.2%

            \[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. Taylor expanded in B around -inf 38.5%

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

          if -8.79999999999999979e-308 < B

          1. Initial program 55.2%

            \[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. Taylor expanded in B around inf 43.5%

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

          \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -8.8 \cdot 10^{-308}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \]

        Alternative 20: 21.1% accurate, 2.5× 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 54.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. Taylor expanded in B around inf 24.0%

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

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

        Reproduce

        ?
        herbie shell --seed 2023321 
        (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)))