?

Average Error: 46.12% → 17.33%
Time: 21.7s
Precision: binary64
Cost: 66952

?

\[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 := \frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\\ \mathbf{if}\;t_0 \leq -1 \cdot 10^{-102}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}{\pi}\\ \mathbf{elif}\;t_0 \leq 0:\\ \;\;\;\;\frac{\frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{0.005555555555555556}}{\pi}\\ \mathbf{else}:\\ \;\;\;\;{\left(0.005555555555555556 \cdot \frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(A - C, B\right)}{B}\right)}\right)}^{-1}\\ \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
         (* (/ 1.0 B) (- (- C A) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0)))))))
   (if (<= t_0 -1e-102)
     (* 180.0 (/ (atan (/ (- (- C A) (hypot B (- A C))) B)) PI))
     (if (<= t_0 0.0)
       (/ (/ (atan (* 0.5 (/ B A))) 0.005555555555555556) PI)
       (pow
        (*
         0.005555555555555556
         (/ PI (atan (/ (- (- C A) (hypot (- A C) B)) B))))
        -1.0)))))
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 = (1.0 / B) * ((C - A) - sqrt((pow((A - C), 2.0) + pow(B, 2.0))));
	double tmp;
	if (t_0 <= -1e-102) {
		tmp = 180.0 * (atan((((C - A) - hypot(B, (A - C))) / B)) / ((double) M_PI));
	} else if (t_0 <= 0.0) {
		tmp = (atan((0.5 * (B / A))) / 0.005555555555555556) / ((double) M_PI);
	} else {
		tmp = pow((0.005555555555555556 * (((double) M_PI) / atan((((C - A) - hypot((A - C), B)) / B)))), -1.0);
	}
	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 = (1.0 / B) * ((C - A) - Math.sqrt((Math.pow((A - C), 2.0) + Math.pow(B, 2.0))));
	double tmp;
	if (t_0 <= -1e-102) {
		tmp = 180.0 * (Math.atan((((C - A) - Math.hypot(B, (A - C))) / B)) / Math.PI);
	} else if (t_0 <= 0.0) {
		tmp = (Math.atan((0.5 * (B / A))) / 0.005555555555555556) / Math.PI;
	} else {
		tmp = Math.pow((0.005555555555555556 * (Math.PI / Math.atan((((C - A) - Math.hypot((A - C), B)) / B)))), -1.0);
	}
	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 = (1.0 / B) * ((C - A) - math.sqrt((math.pow((A - C), 2.0) + math.pow(B, 2.0))))
	tmp = 0
	if t_0 <= -1e-102:
		tmp = 180.0 * (math.atan((((C - A) - math.hypot(B, (A - C))) / B)) / math.pi)
	elif t_0 <= 0.0:
		tmp = (math.atan((0.5 * (B / A))) / 0.005555555555555556) / math.pi
	else:
		tmp = math.pow((0.005555555555555556 * (math.pi / math.atan((((C - A) - math.hypot((A - C), B)) / B)))), -1.0)
	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(Float64(1.0 / B) * Float64(Float64(C - A) - sqrt(Float64((Float64(A - C) ^ 2.0) + (B ^ 2.0)))))
	tmp = 0.0
	if (t_0 <= -1e-102)
		tmp = Float64(180.0 * Float64(atan(Float64(Float64(Float64(C - A) - hypot(B, Float64(A - C))) / B)) / pi));
	elseif (t_0 <= 0.0)
		tmp = Float64(Float64(atan(Float64(0.5 * Float64(B / A))) / 0.005555555555555556) / pi);
	else
		tmp = Float64(0.005555555555555556 * Float64(pi / atan(Float64(Float64(Float64(C - A) - hypot(Float64(A - C), B)) / B)))) ^ -1.0;
	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 = (1.0 / B) * ((C - A) - sqrt((((A - C) ^ 2.0) + (B ^ 2.0))));
	tmp = 0.0;
	if (t_0 <= -1e-102)
		tmp = 180.0 * (atan((((C - A) - hypot(B, (A - C))) / B)) / pi);
	elseif (t_0 <= 0.0)
		tmp = (atan((0.5 * (B / A))) / 0.005555555555555556) / pi;
	else
		tmp = (0.005555555555555556 * (pi / atan((((C - A) - hypot((A - C), B)) / B)))) ^ -1.0;
	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[(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]}, If[LessEqual[t$95$0, -1e-102], 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], If[LessEqual[t$95$0, 0.0], N[(N[(N[ArcTan[N[(0.5 * N[(B / A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / 0.005555555555555556), $MachinePrecision] / Pi), $MachinePrecision], N[Power[N[(0.005555555555555556 * N[(Pi / N[ArcTan[N[(N[(N[(C - A), $MachinePrecision] - N[Sqrt[N[(A - C), $MachinePrecision] ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -1.0], $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 := \frac{1}{B} \cdot \left(\left(C - A\right) - \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)\\
\mathbf{if}\;t_0 \leq -1 \cdot 10^{-102}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}{\pi}\\

\mathbf{elif}\;t_0 \leq 0:\\
\;\;\;\;\frac{\frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{0.005555555555555556}}{\pi}\\

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


\end{array}

Error?

Try it out?

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation?

  1. Split input into 3 regimes
  2. if (*.f64 (/.f64 1 B) (-.f64 (-.f64 C A) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))) < -9.99999999999999933e-103

    1. Initial program 41.02

      \[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. Simplified12.91

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

      [Start]41.02

      \[ 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} \]

      associate-*l/ [=>]41.02

      \[ 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} \]

      *-lft-identity [=>]41.02

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

      +-commutative [=>]41.02

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

      unpow2 [=>]41.02

      \[ 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} \]

      unpow2 [=>]41.02

      \[ 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} \]

      hypot-def [=>]12.91

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

    if -9.99999999999999933e-103 < (*.f64 (/.f64 1 B) (-.f64 (-.f64 C A) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) 2) (pow.f64 B 2))))) < -0.0

    1. Initial program 81.02

      \[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. Simplified88.62

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

      [Start]81.02

      \[ 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} \]

      associate-*r/ [=>]81.02

      \[ \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}} \]

      associate-*l/ [<=]81.02

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

      associate-*l/ [=>]81.02

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

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

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

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

    1. Initial program 40.54

      \[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. Simplified40.55

      \[\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 \cdot B}\right)\right)}{\pi}} \]
      Proof

      [Start]40.54

      \[ 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} \]

      associate-*r/ [=>]40.55

      \[ \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}} \]

      sub-neg [=>]40.55

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

      sub-neg [<=]40.55

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

      unpow2 [=>]40.55

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

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

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

Alternatives

Alternative 1
Error22.14%
Cost20104
\[\begin{array}{l} \mathbf{if}\;A \leq -3.65 \cdot 10^{+146}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(0.5 \cdot \left(\frac{B}{A} + \frac{B}{\frac{A}{\frac{C}{A}}}\right)\right)\\ \mathbf{elif}\;A \leq 8.2 \cdot 10^{-26}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - \mathsf{hypot}\left(B, C\right)}{B}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{\left(-A\right) - \mathsf{hypot}\left(A, B\right)}{B}\right)\\ \end{array} \]
Alternative 2
Error24.65%
Cost20040
\[\begin{array}{l} \mathbf{if}\;A \leq -1.7 \cdot 10^{+146}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(0.5 \cdot \left(\frac{B}{A} + \frac{B}{\frac{A}{\frac{C}{A}}}\right)\right)\\ \mathbf{elif}\;A \leq 1.75 \cdot 10^{+114}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - \mathsf{hypot}\left(B, C\right)}{B}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B - A}{B}\right)}}\\ \end{array} \]
Alternative 3
Error21.83%
Cost20032
\[180 \cdot \frac{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}{\pi} \]
Alternative 4
Error21.84%
Cost20032
\[\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(B, A - C\right)}{B}\right)}} \]
Alternative 5
Error38.31%
Cost14348
\[\begin{array}{l} \mathbf{if}\;B \leq -4.1 \cdot 10^{-221}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{\left(B + C\right) - A}{B}\right)\\ \mathbf{elif}\;B \leq 5.4 \cdot 10^{-188}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(0.5 \cdot \left(\frac{B}{A} + \frac{B}{\frac{A}{\frac{C}{A}}}\right)\right)}{\pi}\\ \mathbf{elif}\;B \leq 4.5 \cdot 10^{-63}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{B \cdot -0.5}{A - C} + \frac{\left(C - A\right) \cdot 2}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - B}{B}\right)\\ \end{array} \]
Alternative 6
Error38.54%
Cost14088
\[\begin{array}{l} t_0 := \frac{180}{\pi} \cdot \tan^{-1} \left(\frac{\left(B + C\right) - A}{B}\right)\\ \mathbf{if}\;B \leq -6.6 \cdot 10^{-222}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq 1.26 \cdot 10^{-188}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(0.5 \cdot \left(\frac{B}{A} + \frac{B}{\frac{A}{\frac{C}{A}}}\right)\right)\\ \mathbf{elif}\;B \leq 4.8 \cdot 10^{-47}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - B}{B}\right)\\ \end{array} \]
Alternative 7
Error38.56%
Cost14088
\[\begin{array}{l} t_0 := \frac{180}{\pi} \cdot \tan^{-1} \left(\frac{\left(B + C\right) - A}{B}\right)\\ \mathbf{if}\;B \leq -6.6 \cdot 10^{-222}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq 2.1 \cdot 10^{-188}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} \left(0.5 \cdot \left(\frac{B}{A} + \frac{B}{\frac{A}{\frac{C}{A}}}\right)\right)}{\pi}\\ \mathbf{elif}\;B \leq 1.4 \cdot 10^{-47}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - B}{B}\right)\\ \end{array} \]
Alternative 8
Error40.63%
Cost13840
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(\frac{B + C}{B}\right)}{\pi}\\ \mathbf{if}\;A \leq -5 \cdot 10^{+100}:\\ \;\;\;\;\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right) \cdot \frac{180}{\pi}\\ \mathbf{elif}\;A \leq -1.15 \cdot 10^{-295}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;A \leq 9 \cdot 10^{-180}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - B}{B}\right)\\ \mathbf{elif}\;A \leq 8.2 \cdot 10^{-132}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B - A}{B}\right)}{\pi}\\ \end{array} \]
Alternative 9
Error40.6%
Cost13840
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(\frac{B + C}{B}\right)}{\pi}\\ \mathbf{if}\;A \leq -1.7 \cdot 10^{+101}:\\ \;\;\;\;\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right) \cdot \frac{180}{\pi}\\ \mathbf{elif}\;A \leq -9 \cdot 10^{-294}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;A \leq 9.5 \cdot 10^{-180}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - B}{B}\right)\\ \mathbf{elif}\;A \leq 9 \cdot 10^{-135}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\frac{\pi}{\tan^{-1} \left(\frac{B - A}{B}\right)}}\\ \end{array} \]
Alternative 10
Error37.13%
Cost13836
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(\frac{\left(B + C\right) - A}{B}\right)}{\pi}\\ \mathbf{if}\;B \leq 1.08 \cdot 10^{-306}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq 1.2 \cdot 10^{-269}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{0}{B}\right)\\ \mathbf{elif}\;B \leq 1.9 \cdot 10^{-47}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - B}{B}\right)\\ \end{array} \]
Alternative 11
Error37.15%
Cost13836
\[\begin{array}{l} t_0 := \frac{180}{\pi} \cdot \tan^{-1} \left(\frac{\left(B + C\right) - A}{B}\right)\\ \mathbf{if}\;B \leq 5.8 \cdot 10^{-307}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq 3.05 \cdot 10^{-266}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{0}{B}\right)\\ \mathbf{elif}\;B \leq 3.5 \cdot 10^{-49}:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{C - B}{B}\right)\\ \end{array} \]
Alternative 12
Error52.47%
Cost13776
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(\frac{-A}{B}\right)}{\pi}\\ \mathbf{if}\;B \leq -2.05 \cdot 10^{-56}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq -2.6 \cdot 10^{-248}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq 2.2 \cdot 10^{-187}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{0}{B}\right)\\ \mathbf{elif}\;B \leq 0.036:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} -1}{\pi}\\ \end{array} \]
Alternative 13
Error52.69%
Cost13776
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(\frac{-A}{B}\right)}{\pi}\\ \mathbf{if}\;B \leq -4 \cdot 10^{-58}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq -9.6 \cdot 10^{-248}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq 2.6 \cdot 10^{-187}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;B \leq 0.25:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} -1}{\pi}\\ \end{array} \]
Alternative 14
Error53.66%
Cost13712
\[\begin{array}{l} t_0 := 180 \cdot \frac{\tan^{-1} \left(\frac{C}{B}\right)}{\pi}\\ \mathbf{if}\;B \leq -7.5 \cdot 10^{-72}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq -2.2 \cdot 10^{-248}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;B \leq 1.56 \cdot 10^{-171}:\\ \;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{0}{B}\right)\\ \mathbf{elif}\;B \leq 2100:\\ \;\;\;\;t_0\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} -1}{\pi}\\ \end{array} \]
Alternative 15
Error44.17%
Cost13576
\[\begin{array}{l} \mathbf{if}\;A \leq -5 \cdot 10^{+100}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 8 \cdot 10^{+104}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B + C}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{-A}{B}\right)}{\pi}\\ \end{array} \]
Alternative 16
Error40.73%
Cost13576
\[\begin{array}{l} \mathbf{if}\;A \leq -5 \cdot 10^{+100}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\ \mathbf{elif}\;A \leq 1.55 \cdot 10^{-133}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B + C}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B - A}{B}\right)}{\pi}\\ \end{array} \]
Alternative 17
Error40.7%
Cost13576
\[\begin{array}{l} \mathbf{if}\;A \leq -5 \cdot 10^{+100}:\\ \;\;\;\;\tan^{-1} \left(0.5 \cdot \frac{B}{A}\right) \cdot \frac{180}{\pi}\\ \mathbf{elif}\;A \leq 5 \cdot 10^{-135}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B + C}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B - A}{B}\right)}{\pi}\\ \end{array} \]
Alternative 18
Error52.6%
Cost13448
\[\begin{array}{l} \mathbf{if}\;B \leq -2.25 \cdot 10^{-73}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 1}{\pi}\\ \mathbf{elif}\;B \leq 1750:\\ \;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B}\right)}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} -1}{\pi}\\ \end{array} \]
Alternative 19
Error59.7%
Cost13188
\[\begin{array}{l} \mathbf{if}\;B \leq -1 \cdot 10^{-310}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} 1}{\pi}\\ \mathbf{else}:\\ \;\;\;\;\frac{180 \cdot \tan^{-1} -1}{\pi}\\ \end{array} \]
Alternative 20
Error79.34%
Cost13056
\[\frac{180 \cdot \tan^{-1} -1}{\pi} \]

Error

Reproduce?

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