
(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:
Herbie found 18 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(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}
(FPCore (A B C) :precision binary64 (if (<= A -1.2e+59) (* 180.0 (/ (atan (/ (* -0.5 (+ B (* B (/ C 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 <= -1.2e+59) {
tmp = 180.0 * (atan(((-0.5 * (B + (B * (C / 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 <= -1.2e+59) {
tmp = 180.0 * (Math.atan(((-0.5 * (B + (B * (C / 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 <= -1.2e+59: tmp = 180.0 * (math.atan(((-0.5 * (B + (B * (C / 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 <= -1.2e+59) tmp = Float64(180.0 * Float64(atan(Float64(Float64(-0.5 * Float64(B + Float64(B * Float64(C / 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 <= -1.2e+59) tmp = 180.0 * (atan(((-0.5 * (B + (B * (C / 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, -1.2e+59], N[(180.0 * N[(N[ArcTan[N[(N[(-0.5 * N[(B + N[(B * N[(C / A), $MachinePrecision]), $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 -1.2 \cdot 10^{+59}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{-0.5 \cdot \left(B + B \cdot \frac{C}{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}
if A < -1.2000000000000001e59Initial program 19.6%
Taylor expanded in A around -inf 75.2%
mul-1-neg75.2%
distribute-neg-frac275.2%
distribute-lft-out75.2%
associate-/l*75.5%
Simplified75.5%
if -1.2000000000000001e59 < A Initial program 64.2%
Simplified85.0%
Final simplification82.8%
(FPCore (A B C)
:precision binary64
(if (<= C -3.8e+137)
(* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI))
(if (<= C 1.85e+124)
(* 180.0 (/ (atan (/ (+ A (hypot B A)) (- B))) PI))
(* (/ 180.0 PI) (atan (* -0.5 (/ B C)))))))
double code(double A, double B, double C) {
double tmp;
if (C <= -3.8e+137) {
tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / ((double) M_PI));
} else if (C <= 1.85e+124) {
tmp = 180.0 * (atan(((A + hypot(B, A)) / -B)) / ((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 <= -3.8e+137) {
tmp = 180.0 * (Math.atan((1.0 + ((C - A) / B))) / Math.PI);
} else if (C <= 1.85e+124) {
tmp = 180.0 * (Math.atan(((A + Math.hypot(B, A)) / -B)) / 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 <= -3.8e+137: tmp = 180.0 * (math.atan((1.0 + ((C - A) / B))) / math.pi) elif C <= 1.85e+124: tmp = 180.0 * (math.atan(((A + math.hypot(B, A)) / -B)) / 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 <= -3.8e+137) tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(Float64(C - A) / B))) / pi)); elseif (C <= 1.85e+124) tmp = Float64(180.0 * Float64(atan(Float64(Float64(A + hypot(B, A)) / Float64(-B))) / pi)); else tmp = Float64(Float64(180.0 / pi) * atan(Float64(-0.5 * Float64(B / C)))); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (C <= -3.8e+137) tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / pi); elseif (C <= 1.85e+124) tmp = 180.0 * (atan(((A + hypot(B, A)) / -B)) / pi); else tmp = (180.0 / pi) * atan((-0.5 * (B / C))); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[C, -3.8e+137], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, 1.85e+124], N[(180.0 * N[(N[ArcTan[N[(N[(A + N[Sqrt[B ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision] / (-B)), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(N[(180.0 / Pi), $MachinePrecision] * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq -3.8 \cdot 10^{+137}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
\mathbf{elif}\;C \leq 1.85 \cdot 10^{+124}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A + \mathsf{hypot}\left(B, A\right)}{-B}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)\\
\end{array}
\end{array}
if C < -3.79999999999999963e137Initial program 85.4%
Taylor expanded in B around -inf 93.6%
associate--l+93.6%
div-sub93.7%
Simplified93.7%
if -3.79999999999999963e137 < C < 1.85000000000000004e124Initial program 53.8%
Taylor expanded in C around 0 49.6%
mul-1-neg49.6%
distribute-neg-frac249.6%
+-commutative49.6%
unpow249.6%
unpow249.6%
hypot-define74.0%
Simplified74.0%
if 1.85000000000000004e124 < C Initial program 13.7%
associate-*l/13.7%
*-lft-identity13.7%
+-commutative13.7%
unpow213.7%
unpow213.7%
hypot-define50.0%
Simplified50.0%
*-commutative50.0%
associate-*l/50.0%
hypot-undefine13.7%
unpow213.7%
unpow213.7%
+-commutative13.7%
unpow213.7%
unpow213.7%
hypot-define50.0%
Applied egg-rr50.0%
Taylor expanded in C around inf 82.4%
Taylor expanded in A around 0 82.4%
associate-*r/82.4%
*-commutative82.4%
+-commutative82.4%
distribute-rgt1-in82.4%
metadata-eval82.4%
mul0-lft82.4%
mul0-lft82.4%
neg-mul-182.4%
fma-undefine82.4%
associate-*r/82.5%
*-commutative82.5%
Simplified82.5%
Final simplification78.2%
(FPCore (A B C)
:precision binary64
(if (<= C -4e+137)
(* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI))
(if (<= C 5.5e+123)
(* (/ 180.0 PI) (atan (/ (- (- A) (hypot A B)) B)))
(* (/ 180.0 PI) (atan (* -0.5 (/ B C)))))))
double code(double A, double B, double C) {
double tmp;
if (C <= -4e+137) {
tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / ((double) M_PI));
} else if (C <= 5.5e+123) {
tmp = (180.0 / ((double) M_PI)) * atan(((-A - hypot(A, B)) / B));
} 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 <= -4e+137) {
tmp = 180.0 * (Math.atan((1.0 + ((C - A) / B))) / Math.PI);
} else if (C <= 5.5e+123) {
tmp = (180.0 / Math.PI) * Math.atan(((-A - Math.hypot(A, B)) / B));
} else {
tmp = (180.0 / Math.PI) * Math.atan((-0.5 * (B / C)));
}
return tmp;
}
def code(A, B, C): tmp = 0 if C <= -4e+137: tmp = 180.0 * (math.atan((1.0 + ((C - A) / B))) / math.pi) elif C <= 5.5e+123: tmp = (180.0 / math.pi) * math.atan(((-A - math.hypot(A, B)) / B)) else: tmp = (180.0 / math.pi) * math.atan((-0.5 * (B / C))) return tmp
function code(A, B, C) tmp = 0.0 if (C <= -4e+137) tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(Float64(C - A) / B))) / pi)); elseif (C <= 5.5e+123) tmp = Float64(Float64(180.0 / pi) * atan(Float64(Float64(Float64(-A) - hypot(A, B)) / B))); else tmp = Float64(Float64(180.0 / pi) * atan(Float64(-0.5 * Float64(B / C)))); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (C <= -4e+137) tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / pi); elseif (C <= 5.5e+123) tmp = (180.0 / pi) * atan(((-A - hypot(A, B)) / B)); else tmp = (180.0 / pi) * atan((-0.5 * (B / C))); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[C, -4e+137], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, 5.5e+123], N[(N[(180.0 / Pi), $MachinePrecision] * N[ArcTan[N[(N[((-A) - N[Sqrt[A ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[(180.0 / Pi), $MachinePrecision] * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq -4 \cdot 10^{+137}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
\mathbf{elif}\;C \leq 5.5 \cdot 10^{+123}:\\
\;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(\frac{\left(-A\right) - \mathsf{hypot}\left(A, B\right)}{B}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)\\
\end{array}
\end{array}
if C < -4.0000000000000001e137Initial program 85.4%
Taylor expanded in B around -inf 93.6%
associate--l+93.6%
div-sub93.7%
Simplified93.7%
if -4.0000000000000001e137 < C < 5.5000000000000002e123Initial program 53.8%
associate-*l/53.8%
*-lft-identity53.8%
+-commutative53.8%
unpow253.8%
unpow253.8%
hypot-define78.1%
Simplified78.1%
clear-num78.1%
un-div-inv78.1%
hypot-undefine53.8%
unpow253.8%
unpow253.8%
+-commutative53.8%
unpow253.8%
unpow253.8%
hypot-define78.1%
Applied egg-rr78.1%
associate-/r/78.1%
sub-neg78.1%
associate-+l-70.5%
sub-neg70.5%
remove-double-neg70.5%
hypot-undefine52.1%
unpow252.1%
unpow252.1%
+-commutative52.1%
unpow252.1%
unpow252.1%
hypot-undefine70.5%
Simplified70.5%
Taylor expanded in C around 0 49.6%
distribute-lft-in49.6%
mul-1-neg49.6%
unsub-neg49.6%
mul-1-neg49.6%
unpow249.6%
unpow249.6%
hypot-define74.1%
Simplified74.1%
if 5.5000000000000002e123 < C Initial program 13.7%
associate-*l/13.7%
*-lft-identity13.7%
+-commutative13.7%
unpow213.7%
unpow213.7%
hypot-define50.0%
Simplified50.0%
*-commutative50.0%
associate-*l/50.0%
hypot-undefine13.7%
unpow213.7%
unpow213.7%
+-commutative13.7%
unpow213.7%
unpow213.7%
hypot-define50.0%
Applied egg-rr50.0%
Taylor expanded in C around inf 82.4%
Taylor expanded in A around 0 82.4%
associate-*r/82.4%
*-commutative82.4%
+-commutative82.4%
distribute-rgt1-in82.4%
metadata-eval82.4%
mul0-lft82.4%
mul0-lft82.4%
neg-mul-182.4%
fma-undefine82.4%
associate-*r/82.5%
*-commutative82.5%
Simplified82.5%
Final simplification78.2%
(FPCore (A B C) :precision binary64 (if (<= C 3.15e+125) (/ (* (atan (/ (- (- C A) (hypot (- A C) B)) B)) 180.0) PI) (* (/ 180.0 PI) (atan (* -0.5 (/ B C))))))
double code(double A, double B, double C) {
double tmp;
if (C <= 3.15e+125) {
tmp = (atan((((C - A) - hypot((A - C), B)) / B)) * 180.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 <= 3.15e+125) {
tmp = (Math.atan((((C - A) - Math.hypot((A - C), B)) / B)) * 180.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 <= 3.15e+125: tmp = (math.atan((((C - A) - math.hypot((A - C), B)) / B)) * 180.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 <= 3.15e+125) tmp = Float64(Float64(atan(Float64(Float64(Float64(C - A) - hypot(Float64(A - C), B)) / B)) * 180.0) / pi); else tmp = Float64(Float64(180.0 / pi) * atan(Float64(-0.5 * Float64(B / C)))); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (C <= 3.15e+125) tmp = (atan((((C - A) - hypot((A - C), B)) / B)) * 180.0) / pi; else tmp = (180.0 / pi) * atan((-0.5 * (B / C))); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[C, 3.15e+125], N[(N[(N[ArcTan[N[(N[(N[(C - A), $MachinePrecision] - N[Sqrt[N[(A - C), $MachinePrecision] ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] * 180.0), $MachinePrecision] / Pi), $MachinePrecision], N[(N[(180.0 / Pi), $MachinePrecision] * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq 3.15 \cdot 10^{+125}:\\
\;\;\;\;\frac{\tan^{-1} \left(\frac{\left(C - A\right) - \mathsf{hypot}\left(A - C, B\right)}{B}\right) \cdot 180}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)\\
\end{array}
\end{array}
if C < 3.1500000000000001e125Initial program 59.4%
associate-*l/59.4%
*-lft-identity59.4%
+-commutative59.4%
unpow259.4%
unpow259.4%
hypot-define82.0%
Simplified82.0%
*-commutative82.0%
associate-*l/82.0%
hypot-undefine59.4%
unpow259.4%
unpow259.4%
+-commutative59.4%
unpow259.4%
unpow259.4%
hypot-define82.0%
Applied egg-rr82.0%
if 3.1500000000000001e125 < C Initial program 13.7%
associate-*l/13.7%
*-lft-identity13.7%
+-commutative13.7%
unpow213.7%
unpow213.7%
hypot-define50.0%
Simplified50.0%
*-commutative50.0%
associate-*l/50.0%
hypot-undefine13.7%
unpow213.7%
unpow213.7%
+-commutative13.7%
unpow213.7%
unpow213.7%
hypot-define50.0%
Applied egg-rr50.0%
Taylor expanded in C around inf 82.4%
Taylor expanded in A around 0 82.4%
associate-*r/82.4%
*-commutative82.4%
+-commutative82.4%
distribute-rgt1-in82.4%
metadata-eval82.4%
mul0-lft82.4%
mul0-lft82.4%
neg-mul-182.4%
fma-undefine82.4%
associate-*r/82.5%
*-commutative82.5%
Simplified82.5%
Final simplification82.1%
(FPCore (A B C) :precision binary64 (if (<= C 1.7e+123) (* 180.0 (/ (atan (/ (- (- C A) (hypot B (- A C))) B)) PI)) (* (/ 180.0 PI) (atan (* -0.5 (/ B C))))))
double code(double A, double B, double C) {
double tmp;
if (C <= 1.7e+123) {
tmp = 180.0 * (atan((((C - A) - hypot(B, (A - C))) / B)) / ((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 <= 1.7e+123) {
tmp = 180.0 * (Math.atan((((C - A) - Math.hypot(B, (A - C))) / B)) / 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 <= 1.7e+123: tmp = 180.0 * (math.atan((((C - A) - math.hypot(B, (A - C))) / B)) / 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 <= 1.7e+123) tmp = Float64(180.0 * Float64(atan(Float64(Float64(Float64(C - A) - hypot(B, Float64(A - C))) / B)) / pi)); else tmp = Float64(Float64(180.0 / pi) * atan(Float64(-0.5 * Float64(B / C)))); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (C <= 1.7e+123) tmp = 180.0 * (atan((((C - A) - hypot(B, (A - C))) / B)) / pi); else tmp = (180.0 / pi) * atan((-0.5 * (B / C))); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[C, 1.7e+123], 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 / Pi), $MachinePrecision] * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq 1.7 \cdot 10^{+123}:\\
\;\;\;\;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}{\pi} \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)\\
\end{array}
\end{array}
if C < 1.70000000000000001e123Initial program 59.4%
associate-*l/59.4%
*-lft-identity59.4%
+-commutative59.4%
unpow259.4%
unpow259.4%
hypot-define82.0%
Simplified82.0%
if 1.70000000000000001e123 < C Initial program 13.7%
associate-*l/13.7%
*-lft-identity13.7%
+-commutative13.7%
unpow213.7%
unpow213.7%
hypot-define50.0%
Simplified50.0%
*-commutative50.0%
associate-*l/50.0%
hypot-undefine13.7%
unpow213.7%
unpow213.7%
+-commutative13.7%
unpow213.7%
unpow213.7%
hypot-define50.0%
Applied egg-rr50.0%
Taylor expanded in C around inf 82.4%
Taylor expanded in A around 0 82.4%
associate-*r/82.4%
*-commutative82.4%
+-commutative82.4%
distribute-rgt1-in82.4%
metadata-eval82.4%
mul0-lft82.4%
mul0-lft82.4%
neg-mul-182.4%
fma-undefine82.4%
associate-*r/82.5%
*-commutative82.5%
Simplified82.5%
Final simplification82.1%
(FPCore (A B C)
:precision binary64
(let* ((t_0 (* 180.0 (/ (atan (/ (* B 0.5) A)) PI))))
(if (<= A -1.45e+41)
t_0
(if (<= A -1.4e-77)
(* 180.0 (/ (atan (* -0.5 (/ B C))) PI))
(if (<= A -1.75e-130)
t_0
(if (<= A -1.95e-240)
(* 180.0 (/ (atan -1.0) PI))
(if (<= A 3.5e-194)
(* 180.0 (/ (atan (/ (* C 2.0) B)) PI))
(if (<= A 2e-126)
(* 180.0 (/ (atan 1.0) PI))
(* 180.0 (/ (atan (* (/ A B) -2.0)) PI))))))))))
double code(double A, double B, double C) {
double t_0 = 180.0 * (atan(((B * 0.5) / A)) / ((double) M_PI));
double tmp;
if (A <= -1.45e+41) {
tmp = t_0;
} else if (A <= -1.4e-77) {
tmp = 180.0 * (atan((-0.5 * (B / C))) / ((double) M_PI));
} else if (A <= -1.75e-130) {
tmp = t_0;
} else if (A <= -1.95e-240) {
tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
} else if (A <= 3.5e-194) {
tmp = 180.0 * (atan(((C * 2.0) / B)) / ((double) M_PI));
} else if (A <= 2e-126) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else {
tmp = 180.0 * (atan(((A / B) * -2.0)) / ((double) M_PI));
}
return tmp;
}
public static double code(double A, double B, double C) {
double t_0 = 180.0 * (Math.atan(((B * 0.5) / A)) / Math.PI);
double tmp;
if (A <= -1.45e+41) {
tmp = t_0;
} else if (A <= -1.4e-77) {
tmp = 180.0 * (Math.atan((-0.5 * (B / C))) / Math.PI);
} else if (A <= -1.75e-130) {
tmp = t_0;
} else if (A <= -1.95e-240) {
tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
} else if (A <= 3.5e-194) {
tmp = 180.0 * (Math.atan(((C * 2.0) / B)) / Math.PI);
} else if (A <= 2e-126) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else {
tmp = 180.0 * (Math.atan(((A / B) * -2.0)) / Math.PI);
}
return tmp;
}
def code(A, B, C): t_0 = 180.0 * (math.atan(((B * 0.5) / A)) / math.pi) tmp = 0 if A <= -1.45e+41: tmp = t_0 elif A <= -1.4e-77: tmp = 180.0 * (math.atan((-0.5 * (B / C))) / math.pi) elif A <= -1.75e-130: tmp = t_0 elif A <= -1.95e-240: tmp = 180.0 * (math.atan(-1.0) / math.pi) elif A <= 3.5e-194: tmp = 180.0 * (math.atan(((C * 2.0) / B)) / math.pi) elif A <= 2e-126: tmp = 180.0 * (math.atan(1.0) / math.pi) else: tmp = 180.0 * (math.atan(((A / B) * -2.0)) / math.pi) return tmp
function code(A, B, C) t_0 = Float64(180.0 * Float64(atan(Float64(Float64(B * 0.5) / A)) / pi)) tmp = 0.0 if (A <= -1.45e+41) tmp = t_0; elseif (A <= -1.4e-77) tmp = Float64(180.0 * Float64(atan(Float64(-0.5 * Float64(B / C))) / pi)); elseif (A <= -1.75e-130) tmp = t_0; elseif (A <= -1.95e-240) tmp = Float64(180.0 * Float64(atan(-1.0) / pi)); elseif (A <= 3.5e-194) tmp = Float64(180.0 * Float64(atan(Float64(Float64(C * 2.0) / B)) / pi)); elseif (A <= 2e-126) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); else tmp = Float64(180.0 * Float64(atan(Float64(Float64(A / B) * -2.0)) / pi)); end return tmp end
function tmp_2 = code(A, B, C) t_0 = 180.0 * (atan(((B * 0.5) / A)) / pi); tmp = 0.0; if (A <= -1.45e+41) tmp = t_0; elseif (A <= -1.4e-77) tmp = 180.0 * (atan((-0.5 * (B / C))) / pi); elseif (A <= -1.75e-130) tmp = t_0; elseif (A <= -1.95e-240) tmp = 180.0 * (atan(-1.0) / pi); elseif (A <= 3.5e-194) tmp = 180.0 * (atan(((C * 2.0) / B)) / pi); elseif (A <= 2e-126) tmp = 180.0 * (atan(1.0) / pi); else tmp = 180.0 * (atan(((A / B) * -2.0)) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := Block[{t$95$0 = N[(180.0 * N[(N[ArcTan[N[(N[(B * 0.5), $MachinePrecision] / A), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[A, -1.45e+41], t$95$0, If[LessEqual[A, -1.4e-77], N[(180.0 * N[(N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -1.75e-130], t$95$0, If[LessEqual[A, -1.95e-240], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, 3.5e-194], N[(180.0 * N[(N[ArcTan[N[(N[(C * 2.0), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, 2e-126], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(A / B), $MachinePrecision] * -2.0), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\
\mathbf{if}\;A \leq -1.45 \cdot 10^{+41}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;A \leq -1.4 \cdot 10^{-77}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\
\mathbf{elif}\;A \leq -1.75 \cdot 10^{-130}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;A \leq -1.95 \cdot 10^{-240}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
\mathbf{elif}\;A \leq 3.5 \cdot 10^{-194}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C \cdot 2}{B}\right)}{\pi}\\
\mathbf{elif}\;A \leq 2 \cdot 10^{-126}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A}{B} \cdot -2\right)}{\pi}\\
\end{array}
\end{array}
if A < -1.44999999999999994e41 or -1.4e-77 < A < -1.75e-130Initial program 24.9%
Taylor expanded in A around -inf 67.4%
associate-*r/67.4%
Simplified67.4%
if -1.44999999999999994e41 < A < -1.4e-77Initial program 42.0%
associate-*l/42.0%
*-lft-identity42.0%
+-commutative42.0%
unpow242.0%
unpow242.0%
hypot-define61.5%
Simplified61.5%
*-commutative61.5%
associate-*l/61.5%
hypot-undefine42.0%
unpow242.0%
unpow242.0%
+-commutative42.0%
unpow242.0%
unpow242.0%
hypot-define61.5%
Applied egg-rr61.5%
Taylor expanded in C around inf 44.2%
Taylor expanded in A around inf 44.2%
if -1.75e-130 < A < -1.95000000000000007e-240Initial program 48.4%
Taylor expanded in B around inf 46.4%
if -1.95000000000000007e-240 < A < 3.5000000000000003e-194Initial program 71.1%
Taylor expanded in C around -inf 43.9%
associate-*r/43.9%
Simplified43.9%
if 3.5000000000000003e-194 < A < 1.9999999999999999e-126Initial program 46.3%
Taylor expanded in B around -inf 46.6%
if 1.9999999999999999e-126 < A Initial program 77.0%
Taylor expanded in A around inf 58.5%
Final simplification56.1%
(FPCore (A B C)
:precision binary64
(let* ((t_0 (* 180.0 (/ (atan (/ (* B 0.5) A)) PI))))
(if (<= A -1.5e+41)
t_0
(if (<= A -1.05e-77)
(* (/ 180.0 PI) (atan (* -0.5 (/ B C))))
(if (<= A -4.1e-132)
t_0
(if (<= A -1.75e-245)
(* 180.0 (/ (atan -1.0) PI))
(if (<= A 1.5e-198)
(* 180.0 (/ (atan (/ (* C 2.0) B)) PI))
(if (<= A 1.9e-126)
(* 180.0 (/ (atan 1.0) PI))
(* 180.0 (/ (atan (* (/ A B) -2.0)) PI))))))))))
double code(double A, double B, double C) {
double t_0 = 180.0 * (atan(((B * 0.5) / A)) / ((double) M_PI));
double tmp;
if (A <= -1.5e+41) {
tmp = t_0;
} else if (A <= -1.05e-77) {
tmp = (180.0 / ((double) M_PI)) * atan((-0.5 * (B / C)));
} else if (A <= -4.1e-132) {
tmp = t_0;
} else if (A <= -1.75e-245) {
tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
} else if (A <= 1.5e-198) {
tmp = 180.0 * (atan(((C * 2.0) / B)) / ((double) M_PI));
} else if (A <= 1.9e-126) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else {
tmp = 180.0 * (atan(((A / B) * -2.0)) / ((double) M_PI));
}
return tmp;
}
public static double code(double A, double B, double C) {
double t_0 = 180.0 * (Math.atan(((B * 0.5) / A)) / Math.PI);
double tmp;
if (A <= -1.5e+41) {
tmp = t_0;
} else if (A <= -1.05e-77) {
tmp = (180.0 / Math.PI) * Math.atan((-0.5 * (B / C)));
} else if (A <= -4.1e-132) {
tmp = t_0;
} else if (A <= -1.75e-245) {
tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
} else if (A <= 1.5e-198) {
tmp = 180.0 * (Math.atan(((C * 2.0) / B)) / Math.PI);
} else if (A <= 1.9e-126) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else {
tmp = 180.0 * (Math.atan(((A / B) * -2.0)) / Math.PI);
}
return tmp;
}
def code(A, B, C): t_0 = 180.0 * (math.atan(((B * 0.5) / A)) / math.pi) tmp = 0 if A <= -1.5e+41: tmp = t_0 elif A <= -1.05e-77: tmp = (180.0 / math.pi) * math.atan((-0.5 * (B / C))) elif A <= -4.1e-132: tmp = t_0 elif A <= -1.75e-245: tmp = 180.0 * (math.atan(-1.0) / math.pi) elif A <= 1.5e-198: tmp = 180.0 * (math.atan(((C * 2.0) / B)) / math.pi) elif A <= 1.9e-126: tmp = 180.0 * (math.atan(1.0) / math.pi) else: tmp = 180.0 * (math.atan(((A / B) * -2.0)) / math.pi) return tmp
function code(A, B, C) t_0 = Float64(180.0 * Float64(atan(Float64(Float64(B * 0.5) / A)) / pi)) tmp = 0.0 if (A <= -1.5e+41) tmp = t_0; elseif (A <= -1.05e-77) tmp = Float64(Float64(180.0 / pi) * atan(Float64(-0.5 * Float64(B / C)))); elseif (A <= -4.1e-132) tmp = t_0; elseif (A <= -1.75e-245) tmp = Float64(180.0 * Float64(atan(-1.0) / pi)); elseif (A <= 1.5e-198) tmp = Float64(180.0 * Float64(atan(Float64(Float64(C * 2.0) / B)) / pi)); elseif (A <= 1.9e-126) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); else tmp = Float64(180.0 * Float64(atan(Float64(Float64(A / B) * -2.0)) / pi)); end return tmp end
function tmp_2 = code(A, B, C) t_0 = 180.0 * (atan(((B * 0.5) / A)) / pi); tmp = 0.0; if (A <= -1.5e+41) tmp = t_0; elseif (A <= -1.05e-77) tmp = (180.0 / pi) * atan((-0.5 * (B / C))); elseif (A <= -4.1e-132) tmp = t_0; elseif (A <= -1.75e-245) tmp = 180.0 * (atan(-1.0) / pi); elseif (A <= 1.5e-198) tmp = 180.0 * (atan(((C * 2.0) / B)) / pi); elseif (A <= 1.9e-126) tmp = 180.0 * (atan(1.0) / pi); else tmp = 180.0 * (atan(((A / B) * -2.0)) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := Block[{t$95$0 = N[(180.0 * N[(N[ArcTan[N[(N[(B * 0.5), $MachinePrecision] / A), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[A, -1.5e+41], t$95$0, If[LessEqual[A, -1.05e-77], N[(N[(180.0 / Pi), $MachinePrecision] * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -4.1e-132], t$95$0, If[LessEqual[A, -1.75e-245], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, 1.5e-198], N[(180.0 * N[(N[ArcTan[N[(N[(C * 2.0), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, 1.9e-126], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(A / B), $MachinePrecision] * -2.0), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\
\mathbf{if}\;A \leq -1.5 \cdot 10^{+41}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;A \leq -1.05 \cdot 10^{-77}:\\
\;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)\\
\mathbf{elif}\;A \leq -4.1 \cdot 10^{-132}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;A \leq -1.75 \cdot 10^{-245}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
\mathbf{elif}\;A \leq 1.5 \cdot 10^{-198}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C \cdot 2}{B}\right)}{\pi}\\
\mathbf{elif}\;A \leq 1.9 \cdot 10^{-126}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A}{B} \cdot -2\right)}{\pi}\\
\end{array}
\end{array}
if A < -1.4999999999999999e41 or -1.05000000000000008e-77 < A < -4.10000000000000007e-132Initial program 24.9%
Taylor expanded in A around -inf 67.4%
associate-*r/67.4%
Simplified67.4%
if -1.4999999999999999e41 < A < -1.05000000000000008e-77Initial program 42.0%
associate-*l/42.0%
*-lft-identity42.0%
+-commutative42.0%
unpow242.0%
unpow242.0%
hypot-define61.5%
Simplified61.5%
*-commutative61.5%
associate-*l/61.5%
hypot-undefine42.0%
unpow242.0%
unpow242.0%
+-commutative42.0%
unpow242.0%
unpow242.0%
hypot-define61.5%
Applied egg-rr61.5%
Taylor expanded in C around inf 44.2%
Taylor expanded in A around 0 44.2%
associate-*r/44.2%
*-commutative44.2%
+-commutative44.2%
distribute-rgt1-in44.2%
metadata-eval44.2%
mul0-lft44.2%
mul0-lft44.2%
neg-mul-144.2%
fma-undefine44.2%
associate-*r/44.3%
*-commutative44.3%
Simplified44.3%
if -4.10000000000000007e-132 < A < -1.75000000000000008e-245Initial program 48.4%
Taylor expanded in B around inf 46.4%
if -1.75000000000000008e-245 < A < 1.5000000000000001e-198Initial program 71.1%
Taylor expanded in C around -inf 43.9%
associate-*r/43.9%
Simplified43.9%
if 1.5000000000000001e-198 < A < 1.8999999999999999e-126Initial program 46.3%
Taylor expanded in B around -inf 46.6%
if 1.8999999999999999e-126 < A Initial program 77.0%
Taylor expanded in A around inf 58.5%
Final simplification56.1%
(FPCore (A B C)
:precision binary64
(let* ((t_0 (* 180.0 (/ (atan (/ (* B 0.5) A)) PI))))
(if (<= A -1.1e+41)
t_0
(if (<= A -1.6e-77)
(* (/ 180.0 PI) (atan (* B (/ -0.5 C))))
(if (<= A -1.3e-132)
t_0
(if (<= A -3.3e-245)
(* 180.0 (/ (atan -1.0) PI))
(if (<= A 7.5e-192)
(* 180.0 (/ (atan (/ (* C 2.0) B)) PI))
(if (<= A 1.02e-128)
(* 180.0 (/ (atan 1.0) PI))
(* 180.0 (/ (atan (* (/ A B) -2.0)) PI))))))))))
double code(double A, double B, double C) {
double t_0 = 180.0 * (atan(((B * 0.5) / A)) / ((double) M_PI));
double tmp;
if (A <= -1.1e+41) {
tmp = t_0;
} else if (A <= -1.6e-77) {
tmp = (180.0 / ((double) M_PI)) * atan((B * (-0.5 / C)));
} else if (A <= -1.3e-132) {
tmp = t_0;
} else if (A <= -3.3e-245) {
tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
} else if (A <= 7.5e-192) {
tmp = 180.0 * (atan(((C * 2.0) / B)) / ((double) M_PI));
} else if (A <= 1.02e-128) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else {
tmp = 180.0 * (atan(((A / B) * -2.0)) / ((double) M_PI));
}
return tmp;
}
public static double code(double A, double B, double C) {
double t_0 = 180.0 * (Math.atan(((B * 0.5) / A)) / Math.PI);
double tmp;
if (A <= -1.1e+41) {
tmp = t_0;
} else if (A <= -1.6e-77) {
tmp = (180.0 / Math.PI) * Math.atan((B * (-0.5 / C)));
} else if (A <= -1.3e-132) {
tmp = t_0;
} else if (A <= -3.3e-245) {
tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
} else if (A <= 7.5e-192) {
tmp = 180.0 * (Math.atan(((C * 2.0) / B)) / Math.PI);
} else if (A <= 1.02e-128) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else {
tmp = 180.0 * (Math.atan(((A / B) * -2.0)) / Math.PI);
}
return tmp;
}
def code(A, B, C): t_0 = 180.0 * (math.atan(((B * 0.5) / A)) / math.pi) tmp = 0 if A <= -1.1e+41: tmp = t_0 elif A <= -1.6e-77: tmp = (180.0 / math.pi) * math.atan((B * (-0.5 / C))) elif A <= -1.3e-132: tmp = t_0 elif A <= -3.3e-245: tmp = 180.0 * (math.atan(-1.0) / math.pi) elif A <= 7.5e-192: tmp = 180.0 * (math.atan(((C * 2.0) / B)) / math.pi) elif A <= 1.02e-128: tmp = 180.0 * (math.atan(1.0) / math.pi) else: tmp = 180.0 * (math.atan(((A / B) * -2.0)) / math.pi) return tmp
function code(A, B, C) t_0 = Float64(180.0 * Float64(atan(Float64(Float64(B * 0.5) / A)) / pi)) tmp = 0.0 if (A <= -1.1e+41) tmp = t_0; elseif (A <= -1.6e-77) tmp = Float64(Float64(180.0 / pi) * atan(Float64(B * Float64(-0.5 / C)))); elseif (A <= -1.3e-132) tmp = t_0; elseif (A <= -3.3e-245) tmp = Float64(180.0 * Float64(atan(-1.0) / pi)); elseif (A <= 7.5e-192) tmp = Float64(180.0 * Float64(atan(Float64(Float64(C * 2.0) / B)) / pi)); elseif (A <= 1.02e-128) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); else tmp = Float64(180.0 * Float64(atan(Float64(Float64(A / B) * -2.0)) / pi)); end return tmp end
function tmp_2 = code(A, B, C) t_0 = 180.0 * (atan(((B * 0.5) / A)) / pi); tmp = 0.0; if (A <= -1.1e+41) tmp = t_0; elseif (A <= -1.6e-77) tmp = (180.0 / pi) * atan((B * (-0.5 / C))); elseif (A <= -1.3e-132) tmp = t_0; elseif (A <= -3.3e-245) tmp = 180.0 * (atan(-1.0) / pi); elseif (A <= 7.5e-192) tmp = 180.0 * (atan(((C * 2.0) / B)) / pi); elseif (A <= 1.02e-128) tmp = 180.0 * (atan(1.0) / pi); else tmp = 180.0 * (atan(((A / B) * -2.0)) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := Block[{t$95$0 = N[(180.0 * N[(N[ArcTan[N[(N[(B * 0.5), $MachinePrecision] / A), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[A, -1.1e+41], t$95$0, If[LessEqual[A, -1.6e-77], N[(N[(180.0 / Pi), $MachinePrecision] * N[ArcTan[N[(B * N[(-0.5 / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -1.3e-132], t$95$0, If[LessEqual[A, -3.3e-245], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, 7.5e-192], N[(180.0 * N[(N[ArcTan[N[(N[(C * 2.0), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, 1.02e-128], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(A / B), $MachinePrecision] * -2.0), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\
\mathbf{if}\;A \leq -1.1 \cdot 10^{+41}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;A \leq -1.6 \cdot 10^{-77}:\\
\;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(B \cdot \frac{-0.5}{C}\right)\\
\mathbf{elif}\;A \leq -1.3 \cdot 10^{-132}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;A \leq -3.3 \cdot 10^{-245}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
\mathbf{elif}\;A \leq 7.5 \cdot 10^{-192}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C \cdot 2}{B}\right)}{\pi}\\
\mathbf{elif}\;A \leq 1.02 \cdot 10^{-128}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A}{B} \cdot -2\right)}{\pi}\\
\end{array}
\end{array}
if A < -1.09999999999999995e41 or -1.6e-77 < A < -1.3e-132Initial program 24.9%
Taylor expanded in A around -inf 67.4%
associate-*r/67.4%
Simplified67.4%
if -1.09999999999999995e41 < A < -1.6e-77Initial program 42.0%
associate-*l/42.0%
*-lft-identity42.0%
+-commutative42.0%
unpow242.0%
unpow242.0%
hypot-define61.5%
Simplified61.5%
*-commutative61.5%
associate-*l/61.5%
hypot-undefine42.0%
unpow242.0%
unpow242.0%
+-commutative42.0%
unpow242.0%
unpow242.0%
hypot-define61.5%
Applied egg-rr61.5%
Taylor expanded in C around inf 44.2%
add-log-exp12.6%
+-commutative12.6%
fma-define12.6%
mul-1-neg12.6%
distribute-rgt1-in12.6%
metadata-eval12.6%
Applied egg-rr12.6%
Taylor expanded in B around 0 44.2%
metadata-eval44.2%
distribute-lft-neg-in44.2%
distribute-lft-neg-in44.2%
metadata-eval44.2%
+-rgt-identity44.2%
div044.2%
fma-undefine44.2%
associate-*r/44.2%
associate-*l/44.3%
fma-undefine44.3%
div044.3%
+-rgt-identity44.3%
associate-*r/44.3%
*-commutative44.3%
associate-/l*44.3%
Simplified44.3%
if -1.3e-132 < A < -3.3000000000000001e-245Initial program 48.4%
Taylor expanded in B around inf 46.4%
if -3.3000000000000001e-245 < A < 7.5000000000000001e-192Initial program 71.1%
Taylor expanded in C around -inf 43.9%
associate-*r/43.9%
Simplified43.9%
if 7.5000000000000001e-192 < A < 1.02e-128Initial program 46.3%
Taylor expanded in B around -inf 46.6%
if 1.02e-128 < A Initial program 77.0%
Taylor expanded in A around inf 58.5%
Final simplification56.1%
(FPCore (A B C)
:precision binary64
(let* ((t_0 (* 180.0 (/ (atan (/ (* B 0.5) A)) PI))))
(if (<= B -1.3e-118)
(* 180.0 (/ (atan 1.0) PI))
(if (<= B -3.8e-210)
t_0
(if (<= B -5.5e-299)
(* 180.0 (/ (atan (* -0.5 (/ B C))) PI))
(if (<= B 1.45e-271)
(* 180.0 (/ (atan (* (/ A B) -2.0)) PI))
(if (<= B 1.95e-22) t_0 (* 180.0 (/ (atan -1.0) PI)))))))))
double code(double A, double B, double C) {
double t_0 = 180.0 * (atan(((B * 0.5) / A)) / ((double) M_PI));
double tmp;
if (B <= -1.3e-118) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else if (B <= -3.8e-210) {
tmp = t_0;
} else if (B <= -5.5e-299) {
tmp = 180.0 * (atan((-0.5 * (B / C))) / ((double) M_PI));
} else if (B <= 1.45e-271) {
tmp = 180.0 * (atan(((A / B) * -2.0)) / ((double) M_PI));
} else if (B <= 1.95e-22) {
tmp = t_0;
} else {
tmp = 180.0 * (atan(-1.0) / ((double) M_PI));
}
return tmp;
}
public static double code(double A, double B, double C) {
double t_0 = 180.0 * (Math.atan(((B * 0.5) / A)) / Math.PI);
double tmp;
if (B <= -1.3e-118) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else if (B <= -3.8e-210) {
tmp = t_0;
} else if (B <= -5.5e-299) {
tmp = 180.0 * (Math.atan((-0.5 * (B / C))) / Math.PI);
} else if (B <= 1.45e-271) {
tmp = 180.0 * (Math.atan(((A / B) * -2.0)) / Math.PI);
} else if (B <= 1.95e-22) {
tmp = t_0;
} else {
tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
}
return tmp;
}
def code(A, B, C): t_0 = 180.0 * (math.atan(((B * 0.5) / A)) / math.pi) tmp = 0 if B <= -1.3e-118: tmp = 180.0 * (math.atan(1.0) / math.pi) elif B <= -3.8e-210: tmp = t_0 elif B <= -5.5e-299: tmp = 180.0 * (math.atan((-0.5 * (B / C))) / math.pi) elif B <= 1.45e-271: tmp = 180.0 * (math.atan(((A / B) * -2.0)) / math.pi) elif B <= 1.95e-22: tmp = t_0 else: tmp = 180.0 * (math.atan(-1.0) / math.pi) return tmp
function code(A, B, C) t_0 = Float64(180.0 * Float64(atan(Float64(Float64(B * 0.5) / A)) / pi)) tmp = 0.0 if (B <= -1.3e-118) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); elseif (B <= -3.8e-210) tmp = t_0; elseif (B <= -5.5e-299) tmp = Float64(180.0 * Float64(atan(Float64(-0.5 * Float64(B / C))) / pi)); elseif (B <= 1.45e-271) tmp = Float64(180.0 * Float64(atan(Float64(Float64(A / B) * -2.0)) / pi)); elseif (B <= 1.95e-22) tmp = t_0; else tmp = Float64(180.0 * Float64(atan(-1.0) / pi)); end return tmp end
function tmp_2 = code(A, B, C) t_0 = 180.0 * (atan(((B * 0.5) / A)) / pi); tmp = 0.0; if (B <= -1.3e-118) tmp = 180.0 * (atan(1.0) / pi); elseif (B <= -3.8e-210) tmp = t_0; elseif (B <= -5.5e-299) tmp = 180.0 * (atan((-0.5 * (B / C))) / pi); elseif (B <= 1.45e-271) tmp = 180.0 * (atan(((A / B) * -2.0)) / pi); elseif (B <= 1.95e-22) tmp = t_0; else tmp = 180.0 * (atan(-1.0) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := Block[{t$95$0 = N[(180.0 * N[(N[ArcTan[N[(N[(B * 0.5), $MachinePrecision] / A), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[B, -1.3e-118], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, -3.8e-210], t$95$0, If[LessEqual[B, -5.5e-299], N[(180.0 * N[(N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 1.45e-271], N[(180.0 * N[(N[ArcTan[N[(N[(A / B), $MachinePrecision] * -2.0), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 1.95e-22], t$95$0, N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\
\mathbf{if}\;B \leq -1.3 \cdot 10^{-118}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{elif}\;B \leq -3.8 \cdot 10^{-210}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;B \leq -5.5 \cdot 10^{-299}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\
\mathbf{elif}\;B \leq 1.45 \cdot 10^{-271}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A}{B} \cdot -2\right)}{\pi}\\
\mathbf{elif}\;B \leq 1.95 \cdot 10^{-22}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
\end{array}
\end{array}
if B < -1.3e-118Initial program 57.0%
Taylor expanded in B around -inf 52.1%
if -1.3e-118 < B < -3.80000000000000003e-210 or 1.45000000000000007e-271 < B < 1.94999999999999999e-22Initial program 48.2%
Taylor expanded in A around -inf 51.1%
associate-*r/51.1%
Simplified51.1%
if -3.80000000000000003e-210 < B < -5.5e-299Initial program 49.6%
associate-*l/49.6%
*-lft-identity49.6%
+-commutative49.6%
unpow249.6%
unpow249.6%
hypot-define75.2%
Simplified75.2%
*-commutative75.2%
associate-*l/75.2%
hypot-undefine49.6%
unpow249.6%
unpow249.6%
+-commutative49.6%
unpow249.6%
unpow249.6%
hypot-define75.2%
Applied egg-rr75.2%
Taylor expanded in C around inf 54.2%
Taylor expanded in A around inf 54.2%
if -5.5e-299 < B < 1.45000000000000007e-271Initial program 100.0%
Taylor expanded in A around inf 100.0%
if 1.94999999999999999e-22 < B Initial program 50.1%
Taylor expanded in B around inf 54.3%
Final simplification54.1%
(FPCore (A B C)
:precision binary64
(let* ((t_0 (/ (- C A) B)))
(if (<= B 1.26e-272)
(* 180.0 (/ (atan (+ 1.0 t_0)) PI))
(if (<= B 1.65e-96)
(* 180.0 (/ (atan (* 0.5 (/ (+ B (/ (* C B) A)) A))) 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 <= 1.26e-272) {
tmp = 180.0 * (atan((1.0 + t_0)) / ((double) M_PI));
} else if (B <= 1.65e-96) {
tmp = 180.0 * (atan((0.5 * ((B + ((C * B) / A)) / A))) / ((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 <= 1.26e-272) {
tmp = 180.0 * (Math.atan((1.0 + t_0)) / Math.PI);
} else if (B <= 1.65e-96) {
tmp = 180.0 * (Math.atan((0.5 * ((B + ((C * B) / A)) / A))) / 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 <= 1.26e-272: tmp = 180.0 * (math.atan((1.0 + t_0)) / math.pi) elif B <= 1.65e-96: tmp = 180.0 * (math.atan((0.5 * ((B + ((C * B) / A)) / A))) / 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 <= 1.26e-272) tmp = Float64(180.0 * Float64(atan(Float64(1.0 + t_0)) / pi)); elseif (B <= 1.65e-96) tmp = Float64(180.0 * Float64(atan(Float64(0.5 * Float64(Float64(B + Float64(Float64(C * B) / A)) / A))) / 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 <= 1.26e-272) tmp = 180.0 * (atan((1.0 + t_0)) / pi); elseif (B <= 1.65e-96) tmp = 180.0 * (atan((0.5 * ((B + ((C * B) / A)) / A))) / 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, 1.26e-272], N[(180.0 * N[(N[ArcTan[N[(1.0 + t$95$0), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 1.65e-96], N[(180.0 * N[(N[ArcTan[N[(0.5 * N[(N[(B + N[(N[(C * B), $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] / A), $MachinePrecision]), $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 1.26 \cdot 10^{-272}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + t\_0\right)}{\pi}\\
\mathbf{elif}\;B \leq 1.65 \cdot 10^{-96}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(0.5 \cdot \frac{B + \frac{C \cdot B}{A}}{A}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(t\_0 + -1\right)}{\pi}\\
\end{array}
\end{array}
if B < 1.25999999999999995e-272Initial program 57.8%
Taylor expanded in B around -inf 70.4%
associate--l+70.4%
div-sub71.1%
Simplified71.1%
if 1.25999999999999995e-272 < B < 1.64999999999999995e-96Initial program 41.9%
Taylor expanded in A around -inf 66.8%
mul-1-neg66.8%
distribute-neg-frac266.8%
distribute-lft-out66.8%
associate-/l*66.8%
Simplified66.8%
Taylor expanded in B around 0 66.8%
if 1.64999999999999995e-96 < B Initial program 51.6%
associate-*l/51.6%
*-lft-identity51.6%
+-commutative51.6%
unpow251.6%
unpow251.6%
hypot-define71.1%
Simplified71.1%
*-commutative71.1%
associate-*l/71.1%
hypot-undefine51.6%
unpow251.6%
unpow251.6%
+-commutative51.6%
unpow251.6%
unpow251.6%
hypot-define71.1%
Applied egg-rr71.1%
Taylor expanded in B around inf 68.5%
+-commutative68.5%
associate--r+68.5%
div-sub68.5%
Simplified68.5%
Final simplification69.7%
(FPCore (A B C)
:precision binary64
(if (<= B -0.00052)
(* 180.0 (/ (atan 1.0) PI))
(if (<= B 2.9e-275)
(* 180.0 (/ (atan (* (/ A B) -2.0)) PI))
(if (<= B 5.7e-123)
(* 180.0 (/ (atan (/ 0.0 B)) PI))
(* 180.0 (/ (atan -1.0) PI))))))
double code(double A, double B, double C) {
double tmp;
if (B <= -0.00052) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else if (B <= 2.9e-275) {
tmp = 180.0 * (atan(((A / B) * -2.0)) / ((double) M_PI));
} else if (B <= 5.7e-123) {
tmp = 180.0 * (atan((0.0 / B)) / ((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 <= -0.00052) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else if (B <= 2.9e-275) {
tmp = 180.0 * (Math.atan(((A / B) * -2.0)) / Math.PI);
} else if (B <= 5.7e-123) {
tmp = 180.0 * (Math.atan((0.0 / B)) / Math.PI);
} else {
tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
}
return tmp;
}
def code(A, B, C): tmp = 0 if B <= -0.00052: tmp = 180.0 * (math.atan(1.0) / math.pi) elif B <= 2.9e-275: tmp = 180.0 * (math.atan(((A / B) * -2.0)) / math.pi) elif B <= 5.7e-123: tmp = 180.0 * (math.atan((0.0 / B)) / math.pi) else: tmp = 180.0 * (math.atan(-1.0) / math.pi) return tmp
function code(A, B, C) tmp = 0.0 if (B <= -0.00052) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); elseif (B <= 2.9e-275) tmp = Float64(180.0 * Float64(atan(Float64(Float64(A / B) * -2.0)) / pi)); elseif (B <= 5.7e-123) tmp = Float64(180.0 * Float64(atan(Float64(0.0 / B)) / 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 <= -0.00052) tmp = 180.0 * (atan(1.0) / pi); elseif (B <= 2.9e-275) tmp = 180.0 * (atan(((A / B) * -2.0)) / pi); elseif (B <= 5.7e-123) tmp = 180.0 * (atan((0.0 / B)) / pi); else tmp = 180.0 * (atan(-1.0) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[B, -0.00052], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 2.9e-275], N[(180.0 * N[(N[ArcTan[N[(N[(A / B), $MachinePrecision] * -2.0), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 5.7e-123], N[(180.0 * N[(N[ArcTan[N[(0.0 / B), $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 -0.00052:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{elif}\;B \leq 2.9 \cdot 10^{-275}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{A}{B} \cdot -2\right)}{\pi}\\
\mathbf{elif}\;B \leq 5.7 \cdot 10^{-123}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{0}{B}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
\end{array}
\end{array}
if B < -5.19999999999999954e-4Initial program 49.5%
Taylor expanded in B around -inf 59.7%
if -5.19999999999999954e-4 < B < 2.9e-275Initial program 65.9%
Taylor expanded in A around inf 40.7%
if 2.9e-275 < B < 5.70000000000000027e-123Initial program 39.0%
Taylor expanded in C around inf 43.7%
associate-*r/43.7%
distribute-rgt1-in43.7%
metadata-eval43.7%
mul0-lft43.7%
metadata-eval43.7%
Simplified43.7%
if 5.70000000000000027e-123 < B Initial program 51.6%
Taylor expanded in B around inf 46.8%
Final simplification48.2%
(FPCore (A B C)
:precision binary64
(let* ((t_0 (/ (- C A) B)))
(if (<= B 4.4e-272)
(* 180.0 (/ (atan (+ 1.0 t_0)) PI))
(if (<= B 9.2e-123)
(/ (* 180.0 (atan (* 0.5 (/ B A)))) 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 <= 4.4e-272) {
tmp = 180.0 * (atan((1.0 + t_0)) / ((double) M_PI));
} else if (B <= 9.2e-123) {
tmp = (180.0 * atan((0.5 * (B / A)))) / ((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 <= 4.4e-272) {
tmp = 180.0 * (Math.atan((1.0 + t_0)) / Math.PI);
} else if (B <= 9.2e-123) {
tmp = (180.0 * Math.atan((0.5 * (B / A)))) / 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 <= 4.4e-272: tmp = 180.0 * (math.atan((1.0 + t_0)) / math.pi) elif B <= 9.2e-123: tmp = (180.0 * math.atan((0.5 * (B / A)))) / 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 <= 4.4e-272) tmp = Float64(180.0 * Float64(atan(Float64(1.0 + t_0)) / pi)); elseif (B <= 9.2e-123) tmp = Float64(Float64(180.0 * atan(Float64(0.5 * Float64(B / A)))) / 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 <= 4.4e-272) tmp = 180.0 * (atan((1.0 + t_0)) / pi); elseif (B <= 9.2e-123) tmp = (180.0 * atan((0.5 * (B / A)))) / 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, 4.4e-272], N[(180.0 * N[(N[ArcTan[N[(1.0 + t$95$0), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 9.2e-123], N[(N[(180.0 * N[ArcTan[N[(0.5 * N[(B / A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $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 4.4 \cdot 10^{-272}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + t\_0\right)}{\pi}\\
\mathbf{elif}\;B \leq 9.2 \cdot 10^{-123}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(0.5 \cdot \frac{B}{A}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(t\_0 + -1\right)}{\pi}\\
\end{array}
\end{array}
if B < 4.39999999999999976e-272Initial program 57.8%
Taylor expanded in B around -inf 70.4%
associate--l+70.4%
div-sub71.1%
Simplified71.1%
if 4.39999999999999976e-272 < B < 9.19999999999999947e-123Initial program 37.8%
associate-*l/37.8%
*-lft-identity37.8%
+-commutative37.8%
unpow237.8%
unpow237.8%
hypot-define69.0%
Simplified69.0%
*-commutative69.0%
associate-*l/69.0%
hypot-undefine37.8%
unpow237.8%
unpow237.8%
+-commutative37.8%
unpow237.8%
unpow237.8%
hypot-define69.0%
Applied egg-rr69.0%
Taylor expanded in A around -inf 65.8%
if 9.19999999999999947e-123 < B Initial program 52.2%
associate-*l/52.2%
*-lft-identity52.2%
+-commutative52.2%
unpow252.2%
unpow252.2%
hypot-define71.2%
Simplified71.2%
*-commutative71.2%
associate-*l/71.3%
hypot-undefine52.2%
unpow252.2%
unpow252.2%
+-commutative52.2%
unpow252.2%
unpow252.2%
hypot-define71.3%
Applied egg-rr71.3%
Taylor expanded in B around inf 67.4%
+-commutative67.4%
associate--r+67.4%
div-sub67.4%
Simplified67.4%
Final simplification69.2%
(FPCore (A B C)
:precision binary64
(if (<= C -1.55e+122)
(* 180.0 (/ (atan (/ (* C 2.0) B)) PI))
(if (<= C 650.0)
(* (/ 180.0 PI) (atan (- 1.0 (/ A B))))
(* (/ 180.0 PI) (atan (* -0.5 (/ B C)))))))
double code(double A, double B, double C) {
double tmp;
if (C <= -1.55e+122) {
tmp = 180.0 * (atan(((C * 2.0) / B)) / ((double) M_PI));
} else if (C <= 650.0) {
tmp = (180.0 / ((double) M_PI)) * atan((1.0 - (A / B)));
} 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 <= -1.55e+122) {
tmp = 180.0 * (Math.atan(((C * 2.0) / B)) / Math.PI);
} else if (C <= 650.0) {
tmp = (180.0 / Math.PI) * Math.atan((1.0 - (A / B)));
} else {
tmp = (180.0 / Math.PI) * Math.atan((-0.5 * (B / C)));
}
return tmp;
}
def code(A, B, C): tmp = 0 if C <= -1.55e+122: tmp = 180.0 * (math.atan(((C * 2.0) / B)) / math.pi) elif C <= 650.0: tmp = (180.0 / math.pi) * math.atan((1.0 - (A / B))) else: tmp = (180.0 / math.pi) * math.atan((-0.5 * (B / C))) return tmp
function code(A, B, C) tmp = 0.0 if (C <= -1.55e+122) tmp = Float64(180.0 * Float64(atan(Float64(Float64(C * 2.0) / B)) / pi)); elseif (C <= 650.0) tmp = Float64(Float64(180.0 / pi) * atan(Float64(1.0 - Float64(A / B)))); else tmp = Float64(Float64(180.0 / pi) * atan(Float64(-0.5 * Float64(B / C)))); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (C <= -1.55e+122) tmp = 180.0 * (atan(((C * 2.0) / B)) / pi); elseif (C <= 650.0) tmp = (180.0 / pi) * atan((1.0 - (A / B))); else tmp = (180.0 / pi) * atan((-0.5 * (B / C))); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[C, -1.55e+122], N[(180.0 * N[(N[ArcTan[N[(N[(C * 2.0), $MachinePrecision] / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, 650.0], N[(N[(180.0 / Pi), $MachinePrecision] * N[ArcTan[N[(1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[(180.0 / Pi), $MachinePrecision] * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq -1.55 \cdot 10^{+122}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C \cdot 2}{B}\right)}{\pi}\\
\mathbf{elif}\;C \leq 650:\\
\;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(1 - \frac{A}{B}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{180}{\pi} \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)\\
\end{array}
\end{array}
if C < -1.54999999999999999e122Initial program 83.0%
Taylor expanded in C around -inf 79.0%
associate-*r/79.0%
Simplified79.0%
if -1.54999999999999999e122 < C < 650Initial program 58.0%
associate-*l/58.0%
*-lft-identity58.0%
+-commutative58.0%
unpow258.0%
unpow258.0%
hypot-define81.0%
Simplified81.0%
clear-num81.0%
un-div-inv81.0%
hypot-undefine58.0%
unpow258.0%
unpow258.0%
+-commutative58.0%
unpow258.0%
unpow258.0%
hypot-define81.0%
Applied egg-rr81.0%
associate-/r/81.0%
sub-neg81.0%
associate-+l-73.7%
sub-neg73.7%
remove-double-neg73.7%
hypot-undefine56.0%
unpow256.0%
unpow256.0%
+-commutative56.0%
unpow256.0%
unpow256.0%
hypot-undefine73.7%
Simplified73.7%
Taylor expanded in C around 0 54.0%
distribute-lft-in54.0%
mul-1-neg54.0%
unsub-neg54.0%
mul-1-neg54.0%
unpow254.0%
unpow254.0%
hypot-define77.2%
Simplified77.2%
Taylor expanded in B around -inf 47.7%
mul-1-neg47.7%
unsub-neg47.7%
Simplified47.7%
if 650 < C Initial program 22.5%
associate-*l/22.5%
*-lft-identity22.5%
+-commutative22.5%
unpow222.5%
unpow222.5%
hypot-define55.0%
Simplified55.0%
*-commutative55.0%
associate-*l/55.1%
hypot-undefine22.5%
unpow222.5%
unpow222.5%
+-commutative22.5%
unpow222.5%
unpow222.5%
hypot-define55.1%
Applied egg-rr55.1%
Taylor expanded in C around inf 63.4%
Taylor expanded in A around 0 63.4%
associate-*r/63.4%
*-commutative63.4%
+-commutative63.4%
distribute-rgt1-in63.4%
metadata-eval63.4%
mul0-lft63.4%
mul0-lft63.4%
neg-mul-163.4%
fma-undefine63.4%
associate-*r/63.5%
*-commutative63.5%
Simplified63.5%
Final simplification57.0%
(FPCore (A B C)
:precision binary64
(if (<= B -5.5e-121)
(* 180.0 (/ (atan 1.0) PI))
(if (<= B 1.3e-123)
(* 180.0 (/ (atan (/ 0.0 B)) PI))
(* 180.0 (/ (atan -1.0) PI)))))
double code(double A, double B, double C) {
double tmp;
if (B <= -5.5e-121) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else if (B <= 1.3e-123) {
tmp = 180.0 * (atan((0.0 / B)) / ((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 <= -5.5e-121) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else if (B <= 1.3e-123) {
tmp = 180.0 * (Math.atan((0.0 / B)) / Math.PI);
} else {
tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
}
return tmp;
}
def code(A, B, C): tmp = 0 if B <= -5.5e-121: tmp = 180.0 * (math.atan(1.0) / math.pi) elif B <= 1.3e-123: tmp = 180.0 * (math.atan((0.0 / B)) / math.pi) else: tmp = 180.0 * (math.atan(-1.0) / math.pi) return tmp
function code(A, B, C) tmp = 0.0 if (B <= -5.5e-121) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); elseif (B <= 1.3e-123) tmp = Float64(180.0 * Float64(atan(Float64(0.0 / B)) / 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 <= -5.5e-121) tmp = 180.0 * (atan(1.0) / pi); elseif (B <= 1.3e-123) tmp = 180.0 * (atan((0.0 / B)) / pi); else tmp = 180.0 * (atan(-1.0) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[B, -5.5e-121], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 1.3e-123], N[(180.0 * N[(N[ArcTan[N[(0.0 / B), $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 -5.5 \cdot 10^{-121}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{elif}\;B \leq 1.3 \cdot 10^{-123}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{0}{B}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
\end{array}
\end{array}
if B < -5.50000000000000031e-121Initial program 56.5%
Taylor expanded in B around -inf 51.6%
if -5.50000000000000031e-121 < B < 1.29999999999999998e-123Initial program 52.3%
Taylor expanded in C around inf 36.9%
associate-*r/36.9%
distribute-rgt1-in36.9%
metadata-eval36.9%
mul0-lft36.9%
metadata-eval36.9%
Simplified36.9%
if 1.29999999999999998e-123 < B Initial program 51.6%
Taylor expanded in B around inf 46.8%
Final simplification45.7%
(FPCore (A B C) :precision binary64 (if (<= A -2.8e+76) (* 180.0 (/ (atan (/ (* B 0.5) A)) PI)) (* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI))))
double code(double A, double B, double C) {
double tmp;
if (A <= -2.8e+76) {
tmp = 180.0 * (atan(((B * 0.5) / A)) / ((double) M_PI));
} else {
tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / ((double) M_PI));
}
return tmp;
}
public static double code(double A, double B, double C) {
double tmp;
if (A <= -2.8e+76) {
tmp = 180.0 * (Math.atan(((B * 0.5) / A)) / Math.PI);
} else {
tmp = 180.0 * (Math.atan((1.0 + ((C - A) / B))) / Math.PI);
}
return tmp;
}
def code(A, B, C): tmp = 0 if A <= -2.8e+76: tmp = 180.0 * (math.atan(((B * 0.5) / A)) / math.pi) else: tmp = 180.0 * (math.atan((1.0 + ((C - A) / B))) / math.pi) return tmp
function code(A, B, C) tmp = 0.0 if (A <= -2.8e+76) tmp = Float64(180.0 * Float64(atan(Float64(Float64(B * 0.5) / A)) / pi)); else tmp = Float64(180.0 * Float64(atan(Float64(1.0 + Float64(Float64(C - A) / B))) / pi)); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (A <= -2.8e+76) tmp = 180.0 * (atan(((B * 0.5) / A)) / pi); else tmp = 180.0 * (atan((1.0 + ((C - A) / B))) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[A, -2.8e+76], N[(180.0 * N[(N[ArcTan[N[(N[(B * 0.5), $MachinePrecision] / A), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;A \leq -2.8 \cdot 10^{+76}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
\end{array}
\end{array}
if A < -2.7999999999999999e76Initial program 17.1%
Taylor expanded in A around -inf 75.0%
associate-*r/75.0%
Simplified75.0%
if -2.7999999999999999e76 < A Initial program 64.0%
Taylor expanded in B around -inf 60.4%
associate--l+60.4%
div-sub61.0%
Simplified61.0%
Final simplification64.1%
(FPCore (A B C) :precision binary64 (if (<= A -1.15e+77) (* 180.0 (/ (atan (/ (* B 0.5) A)) PI)) (/ (* 180.0 (atan (+ 1.0 (/ (- C A) B)))) PI)))
double code(double A, double B, double C) {
double tmp;
if (A <= -1.15e+77) {
tmp = 180.0 * (atan(((B * 0.5) / A)) / ((double) M_PI));
} else {
tmp = (180.0 * atan((1.0 + ((C - A) / B)))) / ((double) M_PI);
}
return tmp;
}
public static double code(double A, double B, double C) {
double tmp;
if (A <= -1.15e+77) {
tmp = 180.0 * (Math.atan(((B * 0.5) / A)) / Math.PI);
} else {
tmp = (180.0 * Math.atan((1.0 + ((C - A) / B)))) / Math.PI;
}
return tmp;
}
def code(A, B, C): tmp = 0 if A <= -1.15e+77: tmp = 180.0 * (math.atan(((B * 0.5) / A)) / math.pi) else: tmp = (180.0 * math.atan((1.0 + ((C - A) / B)))) / math.pi return tmp
function code(A, B, C) tmp = 0.0 if (A <= -1.15e+77) tmp = Float64(180.0 * Float64(atan(Float64(Float64(B * 0.5) / A)) / pi)); else tmp = Float64(Float64(180.0 * atan(Float64(1.0 + Float64(Float64(C - A) / B)))) / pi); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (A <= -1.15e+77) tmp = 180.0 * (atan(((B * 0.5) / A)) / pi); else tmp = (180.0 * atan((1.0 + ((C - A) / B)))) / pi; end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[A, -1.15e+77], N[(180.0 * N[(N[ArcTan[N[(N[(B * 0.5), $MachinePrecision] / A), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(N[(180.0 * N[ArcTan[N[(1.0 + N[(N[(C - A), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;A \leq -1.15 \cdot 10^{+77}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B \cdot 0.5}{A}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
\end{array}
\end{array}
if A < -1.14999999999999997e77Initial program 17.1%
Taylor expanded in A around -inf 75.0%
associate-*r/75.0%
Simplified75.0%
if -1.14999999999999997e77 < A Initial program 64.0%
associate-*l/64.0%
*-lft-identity64.0%
+-commutative64.0%
unpow264.0%
unpow264.0%
hypot-define84.7%
Simplified84.7%
*-commutative84.7%
associate-*l/84.8%
hypot-undefine64.0%
unpow264.0%
unpow264.0%
+-commutative64.0%
unpow264.0%
unpow264.0%
hypot-define84.8%
Applied egg-rr84.8%
Taylor expanded in B around -inf 60.4%
associate--l+60.4%
div-sub61.0%
Simplified61.0%
Final simplification64.1%
(FPCore (A B C) :precision binary64 (if (<= B -1e-310) (* 180.0 (/ (atan 1.0) PI)) (* 180.0 (/ (atan -1.0) PI))))
double code(double A, double B, double C) {
double tmp;
if (B <= -1e-310) {
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 <= -1e-310) {
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 <= -1e-310: 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 <= -1e-310) 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 <= -1e-310) 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, -1e-310], 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 -1 \cdot 10^{-310}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
\end{array}
\end{array}
if B < -9.999999999999969e-311Initial program 55.9%
Taylor expanded in B around -inf 39.3%
if -9.999999999999969e-311 < B Initial program 51.1%
Taylor expanded in B around inf 36.8%
Final simplification38.1%
(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}
Initial program 53.6%
Taylor expanded in B around inf 19.0%
Final simplification19.0%
herbie shell --seed 2024055
(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)))