?

Average Error: 30.0 → 23.9
Time: 19.2s
Precision: binary64
Cost: 34324

?

\[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} \]
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \left(\left(\frac{C}{{A}^{2}} + \frac{1}{A}\right) \cdot B\right)\right)}{\pi}\\ \mathbf{if}\;B \leq -4.2 \cdot 10^{+160}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq -7.8 \cdot 10^{-252}:\\ \;\;\;\;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}\\ \mathbf{elif}\;B \leq 4 \cdot 10^{-260}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - C}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 6.2 \cdot 10^{-173}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq 7.2 \cdot 10^{-141}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\left(-\frac{A + \left(-A\right)}{B}\right) + -0.5 \cdot \frac{\left({B}^{2} + {A}^{2}\right) - {\left(-A\right)}^{2}}{B \cdot C}\right)}{\pi}\\ \mathbf{elif}\;B \leq 4.2 \cdot 10^{-62}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} - \left(1 + \frac{A}{B}\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)))
(FPCore (A B C)
 :precision binary64
 (let* ((t_0
         (*
          180.0
          (/ (atan (* 0.5 (* (+ (/ C (pow A 2.0)) (/ 1.0 A)) B))) PI))))
   (if (<= B -4.2e+160)
     (* 180.0 (/ (atan (- (+ 1.0 (/ C B)) (/ A B))) PI))
     (if (<= B -7.8e-252)
       (*
        180.0
        (/
         (atan
          (* (/ 1.0 B) (- (- C A) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0))))))
         PI))
       (if (<= B 4e-260)
         (* 180.0 (/ (atan (/ (- C C) B)) PI))
         (if (<= B 6.2e-173)
           t_0
           (if (<= B 7.2e-141)
             (*
              180.0
              (/
               (atan
                (+
                 (- (/ (+ A (- A)) B))
                 (*
                  -0.5
                  (/
                   (- (+ (pow B 2.0) (pow A 2.0)) (pow (- A) 2.0))
                   (* B C)))))
               PI))
             (if (<= B 4.2e-62)
               t_0
               (* 180.0 (/ (atan (- (/ C B) (+ 1.0 (/ A B)))) 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));
}
double code(double A, double B, double C) {
	double t_0 = 180.0 * (atan((0.5 * (((C / pow(A, 2.0)) + (1.0 / A)) * B))) / ((double) M_PI));
	double tmp;
	if (B <= -4.2e+160) {
		tmp = 180.0 * (atan(((1.0 + (C / B)) - (A / B))) / ((double) M_PI));
	} else if (B <= -7.8e-252) {
		tmp = 180.0 * (atan(((1.0 / B) * ((C - A) - sqrt((pow((A - C), 2.0) + pow(B, 2.0)))))) / ((double) M_PI));
	} else if (B <= 4e-260) {
		tmp = 180.0 * (atan(((C - C) / B)) / ((double) M_PI));
	} else if (B <= 6.2e-173) {
		tmp = t_0;
	} else if (B <= 7.2e-141) {
		tmp = 180.0 * (atan((-((A + -A) / B) + (-0.5 * (((pow(B, 2.0) + pow(A, 2.0)) - pow(-A, 2.0)) / (B * C))))) / ((double) M_PI));
	} else if (B <= 4.2e-62) {
		tmp = t_0;
	} else {
		tmp = 180.0 * (atan(((C / B) - (1.0 + (A / B)))) / ((double) M_PI));
	}
	return tmp;
}
public static double code(double A, double B, double C) {
	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);
}
public static double code(double A, double B, double C) {
	double t_0 = 180.0 * (Math.atan((0.5 * (((C / Math.pow(A, 2.0)) + (1.0 / A)) * B))) / Math.PI);
	double tmp;
	if (B <= -4.2e+160) {
		tmp = 180.0 * (Math.atan(((1.0 + (C / B)) - (A / B))) / Math.PI);
	} else if (B <= -7.8e-252) {
		tmp = 180.0 * (Math.atan(((1.0 / B) * ((C - A) - Math.sqrt((Math.pow((A - C), 2.0) + Math.pow(B, 2.0)))))) / Math.PI);
	} else if (B <= 4e-260) {
		tmp = 180.0 * (Math.atan(((C - C) / B)) / Math.PI);
	} else if (B <= 6.2e-173) {
		tmp = t_0;
	} else if (B <= 7.2e-141) {
		tmp = 180.0 * (Math.atan((-((A + -A) / B) + (-0.5 * (((Math.pow(B, 2.0) + Math.pow(A, 2.0)) - Math.pow(-A, 2.0)) / (B * C))))) / Math.PI);
	} else if (B <= 4.2e-62) {
		tmp = t_0;
	} else {
		tmp = 180.0 * (Math.atan(((C / B) - (1.0 + (A / B)))) / Math.PI);
	}
	return tmp;
}
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)
def code(A, B, C):
	t_0 = 180.0 * (math.atan((0.5 * (((C / math.pow(A, 2.0)) + (1.0 / A)) * B))) / math.pi)
	tmp = 0
	if B <= -4.2e+160:
		tmp = 180.0 * (math.atan(((1.0 + (C / B)) - (A / B))) / math.pi)
	elif B <= -7.8e-252:
		tmp = 180.0 * (math.atan(((1.0 / B) * ((C - A) - math.sqrt((math.pow((A - C), 2.0) + math.pow(B, 2.0)))))) / math.pi)
	elif B <= 4e-260:
		tmp = 180.0 * (math.atan(((C - C) / B)) / math.pi)
	elif B <= 6.2e-173:
		tmp = t_0
	elif B <= 7.2e-141:
		tmp = 180.0 * (math.atan((-((A + -A) / B) + (-0.5 * (((math.pow(B, 2.0) + math.pow(A, 2.0)) - math.pow(-A, 2.0)) / (B * C))))) / math.pi)
	elif B <= 4.2e-62:
		tmp = t_0
	else:
		tmp = 180.0 * (math.atan(((C / B) - (1.0 + (A / B)))) / math.pi)
	return tmp
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 code(A, B, C)
	t_0 = Float64(180.0 * Float64(atan(Float64(0.5 * Float64(Float64(Float64(C / (A ^ 2.0)) + Float64(1.0 / A)) * B))) / pi))
	tmp = 0.0
	if (B <= -4.2e+160)
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(1.0 + Float64(C / B)) - Float64(A / B))) / pi));
	elseif (B <= -7.8e-252)
		tmp = 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));
	elseif (B <= 4e-260)
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(C - C) / B)) / pi));
	elseif (B <= 6.2e-173)
		tmp = t_0;
	elseif (B <= 7.2e-141)
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(-Float64(Float64(A + Float64(-A)) / B)) + Float64(-0.5 * Float64(Float64(Float64((B ^ 2.0) + (A ^ 2.0)) - (Float64(-A) ^ 2.0)) / Float64(B * C))))) / pi));
	elseif (B <= 4.2e-62)
		tmp = t_0;
	else
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(C / B) - Float64(1.0 + Float64(A / B)))) / pi));
	end
	return tmp
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
function tmp_2 = code(A, B, C)
	t_0 = 180.0 * (atan((0.5 * (((C / (A ^ 2.0)) + (1.0 / A)) * B))) / pi);
	tmp = 0.0;
	if (B <= -4.2e+160)
		tmp = 180.0 * (atan(((1.0 + (C / B)) - (A / B))) / pi);
	elseif (B <= -7.8e-252)
		tmp = 180.0 * (atan(((1.0 / B) * ((C - A) - sqrt((((A - C) ^ 2.0) + (B ^ 2.0)))))) / pi);
	elseif (B <= 4e-260)
		tmp = 180.0 * (atan(((C - C) / B)) / pi);
	elseif (B <= 6.2e-173)
		tmp = t_0;
	elseif (B <= 7.2e-141)
		tmp = 180.0 * (atan((-((A + -A) / B) + (-0.5 * ((((B ^ 2.0) + (A ^ 2.0)) - (-A ^ 2.0)) / (B * C))))) / pi);
	elseif (B <= 4.2e-62)
		tmp = t_0;
	else
		tmp = 180.0 * (atan(((C / B) - (1.0 + (A / B)))) / pi);
	end
	tmp_2 = tmp;
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]
code[A_, B_, C_] := Block[{t$95$0 = N[(180.0 * N[(N[ArcTan[N[(0.5 * N[(N[(N[(C / N[Power[A, 2.0], $MachinePrecision]), $MachinePrecision] + N[(1.0 / A), $MachinePrecision]), $MachinePrecision] * B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[B, -4.2e+160], N[(180.0 * N[(N[ArcTan[N[(N[(1.0 + N[(C / B), $MachinePrecision]), $MachinePrecision] - N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, -7.8e-252], 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], If[LessEqual[B, 4e-260], N[(180.0 * N[(N[ArcTan[N[(N[(C - C), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 6.2e-173], t$95$0, If[LessEqual[B, 7.2e-141], N[(180.0 * N[(N[ArcTan[N[((-N[(N[(A + (-A)), $MachinePrecision] / B), $MachinePrecision]) + N[(-0.5 * N[(N[(N[(N[Power[B, 2.0], $MachinePrecision] + N[Power[A, 2.0], $MachinePrecision]), $MachinePrecision] - N[Power[(-A), 2.0], $MachinePrecision]), $MachinePrecision] / N[(B * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 4.2e-62], t$95$0, N[(180.0 * N[(N[ArcTan[N[(N[(C / B), $MachinePrecision] - N[(1.0 + N[(A / B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]]]]]
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}
\begin{array}{l}
t_0 := 180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \left(\left(\frac{C}{{A}^{2}} + \frac{1}{A}\right) \cdot B\right)\right)}{\pi}\\
\mathbf{if}\;B \leq -4.2 \cdot 10^{+160}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}{\pi}\\

\mathbf{elif}\;B \leq -7.8 \cdot 10^{-252}:\\
\;\;\;\;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}\\

\mathbf{elif}\;B \leq 4 \cdot 10^{-260}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - C}{B}\right)}{\pi}\\

\mathbf{elif}\;B \leq 6.2 \cdot 10^{-173}:\\
\;\;\;\;t_0\\

\mathbf{elif}\;B \leq 7.2 \cdot 10^{-141}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\left(-\frac{A + \left(-A\right)}{B}\right) + -0.5 \cdot \frac{\left({B}^{2} + {A}^{2}\right) - {\left(-A\right)}^{2}}{B \cdot C}\right)}{\pi}\\

\mathbf{elif}\;B \leq 4.2 \cdot 10^{-62}:\\
\;\;\;\;t_0\\

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


\end{array}

Error?

Try it out?

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation?

  1. Split input into 6 regimes
  2. if B < -4.19999999999999993e160

    1. Initial program 47.5

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

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

    if -4.19999999999999993e160 < B < -7.7999999999999998e-252

    1. Initial program 24.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} \]

    if -7.7999999999999998e-252 < B < 3.99999999999999985e-260

    1. Initial program 24.1

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

      \[\leadsto 180 \cdot \frac{\tan^{-1} \color{blue}{\left(\frac{C - \sqrt{{B}^{2} + {C}^{2}}}{B}\right)}}{\pi} \]
    3. Taylor expanded in B around 0 39.6

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

    if 3.99999999999999985e-260 < B < 6.20000000000000011e-173 or 7.2000000000000003e-141 < B < 4.1999999999999998e-62

    1. Initial program 27.5

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

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

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

      [Start]39.5

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

      rational_best-simplify-47 [=>]39.5

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

      rational_best-simplify-2 [=>]39.5

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

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

    if 6.20000000000000011e-173 < B < 7.2000000000000003e-141

    1. Initial program 32.2

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

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

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

      [Start]55.5

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

      rational_best-simplify-1 [=>]55.5

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

      rational_best-simplify-2 [=>]55.5

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

      rational_best-simplify-12 [=>]55.5

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

      rational_best-simplify-2 [=>]55.5

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

      rational_best-simplify-13 [<=]55.5

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

      rational_best-simplify-2 [=>]55.5

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

      rational_best-simplify-13 [<=]55.5

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

      rational_best-simplify-2 [=>]55.5

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

    if 4.1999999999999998e-62 < B

    1. Initial program 31.5

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;B \leq -4.2 \cdot 10^{+160}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq -7.8 \cdot 10^{-252}:\\ \;\;\;\;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}\\ \mathbf{elif}\;B \leq 4 \cdot 10^{-260}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - C}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 6.2 \cdot 10^{-173}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \left(\left(\frac{C}{{A}^{2}} + \frac{1}{A}\right) \cdot B\right)\right)}{\pi}\\ \mathbf{elif}\;B \leq 7.2 \cdot 10^{-141}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\left(-\frac{A + \left(-A\right)}{B}\right) + -0.5 \cdot \frac{\left({B}^{2} + {A}^{2}\right) - {\left(-A\right)}^{2}}{B \cdot C}\right)}{\pi}\\ \mathbf{elif}\;B \leq 4.2 \cdot 10^{-62}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \left(\left(\frac{C}{{A}^{2}} + \frac{1}{A}\right) \cdot B\right)\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \]

Alternatives

Alternative 1
Error23.6
Cost33284
\[\begin{array}{l} \mathbf{if}\;A \leq -7.5 \cdot 10^{-66}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \left(\left(\frac{C}{{A}^{2}} + \frac{1}{A}\right) \cdot B\right)\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;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 2
Error24.1
Cost33032
\[\begin{array}{l} \mathbf{if}\;A \leq -8.6 \cdot 10^{-60}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \left(\left(\frac{C}{{A}^{2}} + \frac{1}{A}\right) \cdot B\right)\right)}{\pi}\\ \mathbf{elif}\;A \leq 8.8 \cdot 10^{-68}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - \sqrt{{B}^{2} + {C}^{2}}}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \]
Alternative 3
Error24.7
Cost20688
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \left(\left(\frac{C}{{A}^{2}} + \frac{1}{A}\right) \cdot B\right)\right)}{\pi}\\ \mathbf{if}\;B \leq -3.5 \cdot 10^{-165}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 6.2 \cdot 10^{-173}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq 7 \cdot 10^{-141}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{\frac{{B}^{2}}{C} \cdot -0.5}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 10^{-61}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \]
Alternative 4
Error24.7
Cost20232
\[\begin{array}{l} \mathbf{if}\;B \leq -4.8 \cdot 10^{-250}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 2.1 \cdot 10^{-99}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-\frac{-0.5 \cdot \frac{{B}^{2}}{A}}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \]
Alternative 5
Error24.4
Cost20168
\[\begin{array}{l} \mathbf{if}\;B \leq -2 \cdot 10^{-246}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 3.75 \cdot 10^{-121}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{\frac{{B}^{2}}{C} \cdot -0.5}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \]
Alternative 6
Error26.1
Cost13964
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}{\pi}\\ \mathbf{if}\;A \leq -4.8 \cdot 10^{-45}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 2.2 \cdot 10^{-66}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;A \leq 175000:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 - \frac{A}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;t_0\\ \end{array} \]
Alternative 7
Error33.8
Cost13840
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{if}\;A \leq -2.7 \cdot 10^{-303}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 2.2 \cdot 10^{-68}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;A \leq 3650000:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \mathbf{elif}\;A \leq 1.5 \cdot 10^{+39}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-2 \cdot \frac{A}{B}\right)}{\pi}\\ \end{array} \]
Alternative 8
Error33.7
Cost13840
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ t_1 := 180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{if}\;B \leq -5.6 \cdot 10^{+110}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;B \leq -2.45 \cdot 10^{+39}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq -3.1 \cdot 10^{-6}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;B \leq 1250000:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 - \frac{A}{B}\right)}{\pi}\\ \end{array} \]
Alternative 9
Error24.9
Cost13832
\[\begin{array}{l} \mathbf{if}\;B \leq -1.2 \cdot 10^{-251}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\left(1 + \frac{C}{B}\right) - \frac{A}{B}\right)}{\pi}\\ \mathbf{elif}\;B \leq 2 \cdot 10^{-98}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C - C}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} - \left(1 + \frac{A}{B}\right)\right)}{\pi}\\ \end{array} \]
Alternative 10
Error29.7
Cost13708
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(1 - \frac{A}{B}\right)}{\pi}\\ \mathbf{if}\;A \leq -2.1 \cdot 10^{-303}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 1.75 \cdot 10^{-68}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;A \leq 70000:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 - \frac{A}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;t_0\\ \end{array} \]
Alternative 11
Error26.6
Cost13576
\[\begin{array}{l} \mathbf{if}\;A \leq -3.8 \cdot 10^{-41}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 400000000:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} - 1\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 - \frac{A}{B}\right)}{\pi}\\ \end{array} \]
Alternative 12
Error26.2
Cost13576
\[\begin{array}{l} \mathbf{if}\;A \leq -4.5 \cdot 10^{-44}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 1.55 \cdot 10^{-69}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C + B}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(-1 - \frac{A}{B}\right)}{\pi}\\ \end{array} \]
Alternative 13
Error34.6
Cost13448
\[\begin{array}{l} \mathbf{if}\;B \leq -2.5 \cdot 10^{-138}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq 0.058:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \]
Alternative 14
Error38.5
Cost13188
\[\begin{array}{l} \mathbf{if}\;B \leq -2 \cdot 10^{-310}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\ \end{array} \]
Alternative 15
Error50.5
Cost13056
\[180 \cdot \frac{\tan^{-1} -1}{\pi} \]

Error

Reproduce?

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