ABCF->ab-angle angle

Percentage Accurate: 54.1% → 81.6%
Time: 18.5s
Alternatives: 21
Speedup: 3.6×

Specification

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

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 21 alternatives:

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

Initial Program: 54.1% 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: 81.6% accurate, 1.9× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;C \leq 9.2 \cdot 10^{+89}:\\
\;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}}\\

\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \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 < 9.1999999999999996e89

    1. Initial program 63.5%

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

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

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

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

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

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

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

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

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

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

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

    if 9.1999999999999996e89 < C

    1. Initial program 15.1%

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

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

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

      \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + -1 \cdot A}{B} + -0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
    6. Step-by-step derivation
      1. distribute-rgt1-in82.5%

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

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

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

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

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

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

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(\color{blue}{\left(0 - 0\right)} + \frac{B}{C} \cdot -0.5\right)}{\pi} \]
      8. associate-+l-82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(0 - \left(0 - \frac{B}{C} \cdot -0.5\right)\right)}}{\pi} \]
      9. neg-sub082.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{\left(-\frac{B}{C} \cdot -0.5\right)}\right)}{\pi} \]
      10. *-commutative82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \left(-\color{blue}{-0.5 \cdot \frac{B}{C}}\right)\right)}{\pi} \]
      11. distribute-lft-neg-in82.5%

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

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{0.5} \cdot \frac{B}{C}\right)}{\pi} \]
      13. neg-sub082.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
      14. distribute-lft-neg-in82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\left(-0.5\right) \cdot \frac{B}{C}\right)}}{\pi} \]
      15. metadata-eval82.5%

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

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

Alternative 2: 78.3% accurate, 1.9× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;C \leq -5.9 \cdot 10^{-34}:\\
\;\;\;\;\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right) \cdot \frac{180}{\pi}\\

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

\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \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 < -5.9000000000000002e-34

    1. Initial program 80.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -5.9000000000000002e-34 < C < 6.49999999999999996e86

    1. Initial program 55.9%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. associate-*r/55.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}} \]
    4. Applied egg-rr79.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 6.49999999999999996e86 < C

    1. Initial program 15.1%

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

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

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

      \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + -1 \cdot A}{B} + -0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
    6. Step-by-step derivation
      1. distribute-rgt1-in82.5%

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

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

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

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

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

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

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(\color{blue}{\left(0 - 0\right)} + \frac{B}{C} \cdot -0.5\right)}{\pi} \]
      8. associate-+l-82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(0 - \left(0 - \frac{B}{C} \cdot -0.5\right)\right)}}{\pi} \]
      9. neg-sub082.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{\left(-\frac{B}{C} \cdot -0.5\right)}\right)}{\pi} \]
      10. *-commutative82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \left(-\color{blue}{-0.5 \cdot \frac{B}{C}}\right)\right)}{\pi} \]
      11. distribute-lft-neg-in82.5%

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

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{0.5} \cdot \frac{B}{C}\right)}{\pi} \]
      13. neg-sub082.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
      14. distribute-lft-neg-in82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\left(-0.5\right) \cdot \frac{B}{C}\right)}}{\pi} \]
      15. metadata-eval82.5%

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

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

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

Alternative 3: 78.3% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;C \leq -3.7 \cdot 10^{-34}:\\ \;\;\;\;\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right) \cdot \frac{180}{\pi}\\ \mathbf{elif}\;C \leq 2.7 \cdot 10^{+87}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{A + \mathsf{hypot}\left(A, B\right)}{-B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\ \end{array} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (if (<= C -3.7e-34)
   (* (atan (/ (- C (hypot C B)) B)) (/ 180.0 PI))
   (if (<= C 2.7e+87)
     (/ (* 180.0 (atan (/ (+ A (hypot A B)) (- B)))) PI)
     (/ (* 180.0 (atan (* -0.5 (/ B C)))) PI))))
double code(double A, double B, double C) {
	double tmp;
	if (C <= -3.7e-34) {
		tmp = atan(((C - hypot(C, B)) / B)) * (180.0 / ((double) M_PI));
	} else if (C <= 2.7e+87) {
		tmp = (180.0 * atan(((A + hypot(A, 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.7e-34) {
		tmp = Math.atan(((C - Math.hypot(C, B)) / B)) * (180.0 / Math.PI);
	} else if (C <= 2.7e+87) {
		tmp = (180.0 * Math.atan(((A + Math.hypot(A, 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.7e-34:
		tmp = math.atan(((C - math.hypot(C, B)) / B)) * (180.0 / math.pi)
	elif C <= 2.7e+87:
		tmp = (180.0 * math.atan(((A + math.hypot(A, 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.7e-34)
		tmp = Float64(atan(Float64(Float64(C - hypot(C, B)) / B)) * Float64(180.0 / pi));
	elseif (C <= 2.7e+87)
		tmp = Float64(Float64(180.0 * atan(Float64(Float64(A + hypot(A, B)) / Float64(-B)))) / pi);
	else
		tmp = Float64(Float64(180.0 * 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.7e-34)
		tmp = atan(((C - hypot(C, B)) / B)) * (180.0 / pi);
	elseif (C <= 2.7e+87)
		tmp = (180.0 * atan(((A + hypot(A, 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.7e-34], N[(N[ArcTan[N[(N[(C - N[Sqrt[C ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] * N[(180.0 / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, 2.7e+87], N[(N[(180.0 * N[ArcTan[N[(N[(A + N[Sqrt[A ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / (-B)), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], N[(N[(180.0 * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;C \leq -3.7 \cdot 10^{-34}:\\
\;\;\;\;\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right) \cdot \frac{180}{\pi}\\

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

\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \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 < -3.69999999999999988e-34

    1. Initial program 80.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -3.69999999999999988e-34 < C < 2.70000000000000007e87

    1. Initial program 55.9%

      \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. associate-*r/55.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}} \]
    4. Applied egg-rr79.7%

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

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

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

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

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

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

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

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

    if 2.70000000000000007e87 < C

    1. Initial program 15.1%

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

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

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

      \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + -1 \cdot A}{B} + -0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
    6. Step-by-step derivation
      1. distribute-rgt1-in82.5%

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

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

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

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

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

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

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(\color{blue}{\left(0 - 0\right)} + \frac{B}{C} \cdot -0.5\right)}{\pi} \]
      8. associate-+l-82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(0 - \left(0 - \frac{B}{C} \cdot -0.5\right)\right)}}{\pi} \]
      9. neg-sub082.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{\left(-\frac{B}{C} \cdot -0.5\right)}\right)}{\pi} \]
      10. *-commutative82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \left(-\color{blue}{-0.5 \cdot \frac{B}{C}}\right)\right)}{\pi} \]
      11. distribute-lft-neg-in82.5%

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

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{0.5} \cdot \frac{B}{C}\right)}{\pi} \]
      13. neg-sub082.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
      14. distribute-lft-neg-in82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\left(-0.5\right) \cdot \frac{B}{C}\right)}}{\pi} \]
      15. metadata-eval82.5%

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

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

Alternative 4: 78.3% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;C \leq -2.25 \cdot 10^{-35}:\\ \;\;\;\;\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right) \cdot \frac{180}{\pi}\\ \mathbf{elif}\;C \leq 3.05 \cdot 10^{+88}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(A, B\right)}{-B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\ \end{array} \end{array} \]
(FPCore (A B C)
 :precision binary64
 (if (<= C -2.25e-35)
   (* (atan (/ (- C (hypot C B)) B)) (/ 180.0 PI))
   (if (<= C 3.05e+88)
     (* 180.0 (/ (atan (/ (+ A (hypot A B)) (- B))) PI))
     (/ (* 180.0 (atan (* -0.5 (/ B C)))) PI))))
double code(double A, double B, double C) {
	double tmp;
	if (C <= -2.25e-35) {
		tmp = atan(((C - hypot(C, B)) / B)) * (180.0 / ((double) M_PI));
	} else if (C <= 3.05e+88) {
		tmp = 180.0 * (atan(((A + hypot(A, 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 <= -2.25e-35) {
		tmp = Math.atan(((C - Math.hypot(C, B)) / B)) * (180.0 / Math.PI);
	} else if (C <= 3.05e+88) {
		tmp = 180.0 * (Math.atan(((A + Math.hypot(A, 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 <= -2.25e-35:
		tmp = math.atan(((C - math.hypot(C, B)) / B)) * (180.0 / math.pi)
	elif C <= 3.05e+88:
		tmp = 180.0 * (math.atan(((A + math.hypot(A, 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 <= -2.25e-35)
		tmp = Float64(atan(Float64(Float64(C - hypot(C, B)) / B)) * Float64(180.0 / pi));
	elseif (C <= 3.05e+88)
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(A + hypot(A, B)) / Float64(-B))) / pi));
	else
		tmp = Float64(Float64(180.0 * atan(Float64(-0.5 * Float64(B / C)))) / pi);
	end
	return tmp
end
function tmp_2 = code(A, B, C)
	tmp = 0.0;
	if (C <= -2.25e-35)
		tmp = atan(((C - hypot(C, B)) / B)) * (180.0 / pi);
	elseif (C <= 3.05e+88)
		tmp = 180.0 * (atan(((A + hypot(A, 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, -2.25e-35], N[(N[ArcTan[N[(N[(C - N[Sqrt[C ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] * N[(180.0 / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, 3.05e+88], N[(180.0 * N[(N[ArcTan[N[(N[(A + N[Sqrt[A ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / (-B)), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(N[(180.0 * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;C \leq -2.25 \cdot 10^{-35}:\\
\;\;\;\;\tan^{-1} \left(\frac{C - \mathsf{hypot}\left(C, B\right)}{B}\right) \cdot \frac{180}{\pi}\\

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

\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \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 < -2.25000000000000005e-35

    1. Initial program 80.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -2.25000000000000005e-35 < C < 3.0499999999999999e88

    1. Initial program 55.9%

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

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

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

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

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

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

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

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

    if 3.0499999999999999e88 < C

    1. Initial program 15.1%

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

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

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

      \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + -1 \cdot A}{B} + -0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
    6. Step-by-step derivation
      1. distribute-rgt1-in82.5%

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

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

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

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

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

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

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(\color{blue}{\left(0 - 0\right)} + \frac{B}{C} \cdot -0.5\right)}{\pi} \]
      8. associate-+l-82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(0 - \left(0 - \frac{B}{C} \cdot -0.5\right)\right)}}{\pi} \]
      9. neg-sub082.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{\left(-\frac{B}{C} \cdot -0.5\right)}\right)}{\pi} \]
      10. *-commutative82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \left(-\color{blue}{-0.5 \cdot \frac{B}{C}}\right)\right)}{\pi} \]
      11. distribute-lft-neg-in82.5%

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

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{0.5} \cdot \frac{B}{C}\right)}{\pi} \]
      13. neg-sub082.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
      14. distribute-lft-neg-in82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\left(-0.5\right) \cdot \frac{B}{C}\right)}}{\pi} \]
      15. metadata-eval82.5%

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

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

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

Alternative 5: 76.3% accurate, 1.9× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if A < -2.3e94

    1. Initial program 14.8%

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

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

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

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

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

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

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

    if -2.3e94 < A < 1.55e-13

    1. Initial program 57.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 1.55e-13 < A

    1. Initial program 76.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 6: 76.2% accurate, 1.9× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if A < -3.60000000000000005e86

    1. Initial program 14.8%

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

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

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

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

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

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

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

    if -3.60000000000000005e86 < A < 3.3000000000000001e-13

    1. Initial program 57.6%

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

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

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

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

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

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

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

    if 3.3000000000000001e-13 < A

    1. Initial program 76.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 7: 81.6% accurate, 1.9× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;C \leq 5.1 \cdot 10^{+88}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}{\pi}\\

\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \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 < 5.0999999999999997e88

    1. Initial program 63.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-*l/63.5%

        \[\leadsto 180 \cdot \frac{\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} \]
      2. *-lft-identity63.5%

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

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

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

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

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

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

    if 5.0999999999999997e88 < C

    1. Initial program 15.1%

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

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

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

      \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + -1 \cdot A}{B} + -0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
    6. Step-by-step derivation
      1. distribute-rgt1-in82.5%

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

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

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

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

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

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

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(\color{blue}{\left(0 - 0\right)} + \frac{B}{C} \cdot -0.5\right)}{\pi} \]
      8. associate-+l-82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(0 - \left(0 - \frac{B}{C} \cdot -0.5\right)\right)}}{\pi} \]
      9. neg-sub082.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{\left(-\frac{B}{C} \cdot -0.5\right)}\right)}{\pi} \]
      10. *-commutative82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \left(-\color{blue}{-0.5 \cdot \frac{B}{C}}\right)\right)}{\pi} \]
      11. distribute-lft-neg-in82.5%

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

        \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{0.5} \cdot \frac{B}{C}\right)}{\pi} \]
      13. neg-sub082.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
      14. distribute-lft-neg-in82.5%

        \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\left(-0.5\right) \cdot \frac{B}{C}\right)}}{\pi} \]
      15. metadata-eval82.5%

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

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

Alternative 8: 81.5% accurate, 1.9× speedup?

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if A < -4.49999999999999957e96

    1. Initial program 14.8%

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

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

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

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

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

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

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

    if -4.49999999999999957e96 < A

    1. Initial program 62.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. Simplified84.3%

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

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

    Alternative 9: 65.2% accurate, 3.4× speedup?

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

      1. Initial program 55.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -3.60000000000000008e-96 < B < -2.40000000000000009e-253

      1. Initial program 46.6%

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

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

        \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(-1 \cdot \frac{A + -1 \cdot A}{B} + -1 \cdot \frac{0.5 \cdot B + 0.5 \cdot \frac{A \cdot B}{C}}{C}\right)}}{\pi} \]
      5. Step-by-step derivation
        1. distribute-rgt1-in55.4%

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

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

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

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

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

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

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

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

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

          \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{A + -1 \cdot A}{B} - \frac{0.5 \cdot B + 0.5 \cdot \frac{A \cdot B}{C}}{C}\right)}}{\pi} \]
        11. distribute-rgt1-in55.4%

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

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

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

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

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

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

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

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

      if -2.40000000000000009e-253 < B

      1. Initial program 57.1%

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

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

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

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

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

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

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

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

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

    Alternative 10: 54.2% accurate, 3.5× speedup?

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

      1. Initial program 55.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -3.8000000000000001e-96 < B < 2.69999999999999981e-252

      1. Initial program 53.9%

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(\color{blue}{\left(0 - 0\right)} + \frac{B}{C} \cdot -0.5\right)}{\pi} \]
        8. associate-+l-44.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(0 - \left(0 - \frac{B}{C} \cdot -0.5\right)\right)}}{\pi} \]
        9. neg-sub044.0%

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \left(-\color{blue}{-0.5 \cdot \frac{B}{C}}\right)\right)}{\pi} \]
        11. distribute-lft-neg-in44.0%

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{0.5} \cdot \frac{B}{C}\right)}{\pi} \]
        13. neg-sub044.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
        14. distribute-lft-neg-in44.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\left(-0.5\right) \cdot \frac{B}{C}\right)}}{\pi} \]
        15. metadata-eval44.0%

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

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

      if 2.69999999999999981e-252 < B

      1. Initial program 55.1%

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

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

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

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

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

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

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

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

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

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

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

    Alternative 11: 53.3% accurate, 3.5× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;C \leq -8 \cdot 10^{-278}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(1 + \frac{C}{B}\right)\\ \mathbf{elif}\;C \leq 2.5 \cdot 10^{-213}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= C -8e-278)
       (* (/ 180.0 PI) (atan (+ 1.0 (/ C B))))
       (if (<= C 2.5e-213)
         (* 180.0 (/ (atan -1.0) PI))
         (/ (* 180.0 (atan (* -0.5 (/ B C)))) PI))))
    double code(double A, double B, double C) {
    	double tmp;
    	if (C <= -8e-278) {
    		tmp = (180.0 / ((double) M_PI)) * atan((1.0 + (C / B)));
    	} else if (C <= 2.5e-213) {
    		tmp = 180.0 * (atan(-1.0) / ((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 <= -8e-278) {
    		tmp = (180.0 / Math.PI) * Math.atan((1.0 + (C / B)));
    	} else if (C <= 2.5e-213) {
    		tmp = 180.0 * (Math.atan(-1.0) / 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 <= -8e-278:
    		tmp = (180.0 / math.pi) * math.atan((1.0 + (C / B)))
    	elif C <= 2.5e-213:
    		tmp = 180.0 * (math.atan(-1.0) / 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 <= -8e-278)
    		tmp = Float64(Float64(180.0 / pi) * atan(Float64(1.0 + Float64(C / B))));
    	elseif (C <= 2.5e-213)
    		tmp = Float64(180.0 * Float64(atan(-1.0) / pi));
    	else
    		tmp = Float64(Float64(180.0 * atan(Float64(-0.5 * Float64(B / C)))) / pi);
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (C <= -8e-278)
    		tmp = (180.0 / pi) * atan((1.0 + (C / B)));
    	elseif (C <= 2.5e-213)
    		tmp = 180.0 * (atan(-1.0) / pi);
    	else
    		tmp = (180.0 * atan((-0.5 * (B / C)))) / pi;
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[C, -8e-278], N[(N[(180.0 / Pi), $MachinePrecision] * N[ArcTan[N[(1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[C, 2.5e-213], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(N[(180.0 * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;C \leq -8 \cdot 10^{-278}:\\
    \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(1 + \frac{C}{B}\right)\\
    
    \mathbf{elif}\;C \leq 2.5 \cdot 10^{-213}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{180 \cdot \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 < -7.9999999999999995e-278

      1. Initial program 70.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -7.9999999999999995e-278 < C < 2.49999999999999989e-213

      1. Initial program 50.8%

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

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

      if 2.49999999999999989e-213 < C

      1. Initial program 41.6%

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(\color{blue}{\left(0 - 0\right)} + \frac{B}{C} \cdot -0.5\right)}{\pi} \]
        8. associate-+l-55.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(0 - \left(0 - \frac{B}{C} \cdot -0.5\right)\right)}}{\pi} \]
        9. neg-sub055.0%

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \left(-\color{blue}{-0.5 \cdot \frac{B}{C}}\right)\right)}{\pi} \]
        11. distribute-lft-neg-in55.0%

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{0.5} \cdot \frac{B}{C}\right)}{\pi} \]
        13. neg-sub055.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
        14. distribute-lft-neg-in55.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\left(-0.5\right) \cdot \frac{B}{C}\right)}}{\pi} \]
        15. metadata-eval55.0%

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

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

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

    Alternative 12: 53.2% accurate, 3.5× speedup?

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

      1. Initial program 70.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -2.50000000000000014e-280 < C < 3.1999999999999999e-222

      1. Initial program 50.8%

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

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

      if 3.1999999999999999e-222 < C

      1. Initial program 41.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(\color{blue}{\left(0 - 0\right)} + \frac{B}{C} \cdot -0.5\right)}{\pi} \]
        8. associate-+l-55.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(0 - \left(0 - \frac{B}{C} \cdot -0.5\right)\right)}}{\pi} \]
        9. neg-sub055.0%

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \left(-\color{blue}{-0.5 \cdot \frac{B}{C}}\right)\right)}{\pi} \]
        11. distribute-lft-neg-in55.0%

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{0.5} \cdot \frac{B}{C}\right)}{\pi} \]
        13. neg-sub055.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
        14. distribute-lft-neg-in55.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\left(-0.5\right) \cdot \frac{B}{C}\right)}}{\pi} \]
        15. metadata-eval55.0%

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

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

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

    Alternative 13: 58.1% accurate, 3.5× speedup?

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

      1. Initial program 28.0%

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

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

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

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

      if -6.1999999999999995e-51 < A < 6.9000000000000004e75

      1. Initial program 65.4%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. associate-*r/65.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}} \]
      4. Applied egg-rr88.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if 6.9000000000000004e75 < A

      1. Initial program 74.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-*l/74.4%

          \[\leadsto 180 \cdot \frac{\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} \]
        2. *-lft-identity74.4%

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

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

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

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

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

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

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

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

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

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

    Alternative 14: 48.4% accurate, 3.5× speedup?

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

      1. Initial program 33.3%

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

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

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

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

      if -4.09999999999999993e-97 < A < 3.00000000000000016e-87

      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. Add Preprocessing
      3. Taylor expanded in B around inf 36.3%

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

      if 3.00000000000000016e-87 < A

      1. Initial program 72.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. associate-*l/72.8%

          \[\leadsto 180 \cdot \frac{\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} \]
        2. *-lft-identity72.8%

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

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

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

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

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

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

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

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

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;A \leq -4.1 \cdot 10^{-97}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 3 \cdot 10^{-87}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A \cdot -2}{B}\right)}{\pi}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 15: 45.6% accurate, 3.5× speedup?

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

      1. Initial program 55.1%

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

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

      if -6.9999999999999997e-134 < B < 7.5999999999999995e23

      1. Initial program 57.0%

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

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

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

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

      if 7.5999999999999995e23 < B

      1. Initial program 50.6%

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

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

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

    Alternative 16: 66.6% accurate, 3.6× speedup?

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

      1. Initial program 54.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -1.00000000000000004e-153 < B

      1. Initial program 54.8%

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

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

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

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

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

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

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

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

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

    Alternative 17: 61.8% accurate, 3.6× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;C \leq 5 \cdot 10^{-34}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= C 5e-34)
       (/ 180.0 (/ PI (atan (+ 1.0 (/ (- C A) B)))))
       (/ (* 180.0 (atan (* -0.5 (/ B C)))) PI)))
    double code(double A, double B, double C) {
    	double tmp;
    	if (C <= 5e-34) {
    		tmp = 180.0 / (((double) M_PI) / atan((1.0 + ((C - A) / B))));
    	} 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 <= 5e-34) {
    		tmp = 180.0 / (Math.PI / Math.atan((1.0 + ((C - A) / B))));
    	} else {
    		tmp = (180.0 * Math.atan((-0.5 * (B / C)))) / Math.PI;
    	}
    	return tmp;
    }
    
    def code(A, B, C):
    	tmp = 0
    	if C <= 5e-34:
    		tmp = 180.0 / (math.pi / math.atan((1.0 + ((C - A) / B))))
    	else:
    		tmp = (180.0 * math.atan((-0.5 * (B / C)))) / math.pi
    	return tmp
    
    function code(A, B, C)
    	tmp = 0.0
    	if (C <= 5e-34)
    		tmp = Float64(180.0 / Float64(pi / atan(Float64(1.0 + Float64(Float64(C - A) / B)))));
    	else
    		tmp = Float64(Float64(180.0 * atan(Float64(-0.5 * Float64(B / C)))) / pi);
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (C <= 5e-34)
    		tmp = 180.0 / (pi / atan((1.0 + ((C - A) / B))));
    	else
    		tmp = (180.0 * atan((-0.5 * (B / C)))) / pi;
    	end
    	tmp_2 = tmp;
    end
    
    code[A_, B_, C_] := If[LessEqual[C, 5e-34], N[(180.0 / N[(Pi / N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(180.0 * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;C \leq 5 \cdot 10^{-34}:\\
    \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}}\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{180 \cdot \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 < 5.0000000000000003e-34

      1. Initial program 67.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if 5.0000000000000003e-34 < C

      1. Initial program 27.4%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. associate-*r/27.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}} \]
      4. Applied egg-rr55.0%

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

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

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

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

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

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

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

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(\color{blue}{\left(0 - 0\right)} + \frac{B}{C} \cdot -0.5\right)}{\pi} \]
        8. associate-+l-67.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(0 - \left(0 - \frac{B}{C} \cdot -0.5\right)\right)}}{\pi} \]
        9. neg-sub067.0%

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \left(-\color{blue}{-0.5 \cdot \frac{B}{C}}\right)\right)}{\pi} \]
        11. distribute-lft-neg-in67.0%

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{0.5} \cdot \frac{B}{C}\right)}{\pi} \]
        13. neg-sub067.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
        14. distribute-lft-neg-in67.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\left(-0.5\right) \cdot \frac{B}{C}\right)}}{\pi} \]
        15. metadata-eval67.0%

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

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

    Alternative 18: 61.8% accurate, 3.6× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;C \leq 6.5 \cdot 10^{-31}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\ \end{array} \end{array} \]
    (FPCore (A B C)
     :precision binary64
     (if (<= C 6.5e-31)
       (* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI))
       (/ (* 180.0 (atan (* -0.5 (/ B C)))) PI)))
    double code(double A, double B, double C) {
    	double tmp;
    	if (C <= 6.5e-31) {
    		tmp = 180.0 * (atan((1.0 + ((C - 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 <= 6.5e-31) {
    		tmp = 180.0 * (Math.atan((1.0 + ((C - 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 <= 6.5e-31:
    		tmp = 180.0 * (math.atan((1.0 + ((C - 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 <= 6.5e-31)
    		tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(Float64(C - A) / B))) / pi));
    	else
    		tmp = Float64(Float64(180.0 * atan(Float64(-0.5 * Float64(B / C)))) / pi);
    	end
    	return tmp
    end
    
    function tmp_2 = code(A, B, C)
    	tmp = 0.0;
    	if (C <= 6.5e-31)
    		tmp = 180.0 * (atan((1.0 + ((C - 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, 6.5e-31], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(N[(180.0 * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;C \leq 6.5 \cdot 10^{-31}:\\
    \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{180 \cdot \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 < 6.49999999999999967e-31

      1. Initial program 67.0%

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

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

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

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

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

      if 6.49999999999999967e-31 < C

      1. Initial program 27.4%

        \[180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\right)}{\pi} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. associate-*r/27.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}} \]
      4. Applied egg-rr55.0%

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

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

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

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

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

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

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

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(\color{blue}{\left(0 - 0\right)} + \frac{B}{C} \cdot -0.5\right)}{\pi} \]
        8. associate-+l-67.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(0 - \left(0 - \frac{B}{C} \cdot -0.5\right)\right)}}{\pi} \]
        9. neg-sub067.0%

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \left(-\color{blue}{-0.5 \cdot \frac{B}{C}}\right)\right)}{\pi} \]
        11. distribute-lft-neg-in67.0%

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

          \[\leadsto \frac{180 \cdot \tan^{-1} \left(0 - \color{blue}{0.5} \cdot \frac{B}{C}\right)}{\pi} \]
        13. neg-sub067.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(-0.5 \cdot \frac{B}{C}\right)}}{\pi} \]
        14. distribute-lft-neg-in67.0%

          \[\leadsto \frac{180 \cdot \tan^{-1} \color{blue}{\left(\left(-0.5\right) \cdot \frac{B}{C}\right)}}{\pi} \]
        15. metadata-eval67.0%

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

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

    Alternative 19: 45.2% accurate, 3.6× speedup?

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

      1. Initial program 55.7%

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

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

      if -1.52000000000000001e-133 < B < 7.80000000000000002e-118

      1. Initial program 51.6%

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

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

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

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

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

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

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

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

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

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

      if 7.80000000000000002e-118 < B

      1. Initial program 56.3%

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

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

    Alternative 20: 39.7% accurate, 3.8× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;B \leq -8.8 \cdot 10^{-302}:\\ \;\;\;\;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-302)
       (* 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-302) {
    		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-302) {
    		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-302:
    		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-302)
    		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-302)
    		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-302], 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^{-302}:\\
    \;\;\;\;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.8000000000000003e-302

      1. Initial program 52.9%

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

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

      if -8.8000000000000003e-302 < B

      1. Initial program 56.7%

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

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

    Alternative 21: 20.6% accurate, 4.0× speedup?

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

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

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

    Reproduce

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