
(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}
Herbie found 15 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.7e-19) (* 180.0 (/ (atan (- (/ (* -0.5 (+ B (* B (/ C A)))) A))) PI)) (/ (* 180.0 (atan (* (- (- C A) (hypot (- A C) B)) (pow B -1.0)))) PI)))
double code(double A, double B, double C) {
double tmp;
if (A <= -1.7e-19) {
tmp = 180.0 * (atan(-((-0.5 * (B + (B * (C / A)))) / A)) / ((double) M_PI));
} else {
tmp = (180.0 * atan((((C - A) - hypot((A - C), B)) * pow(B, -1.0)))) / ((double) M_PI);
}
return tmp;
}
public static double code(double A, double B, double C) {
double tmp;
if (A <= -1.7e-19) {
tmp = 180.0 * (Math.atan(-((-0.5 * (B + (B * (C / A)))) / A)) / Math.PI);
} else {
tmp = (180.0 * Math.atan((((C - A) - Math.hypot((A - C), B)) * Math.pow(B, -1.0)))) / Math.PI;
}
return tmp;
}
def code(A, B, C): tmp = 0 if A <= -1.7e-19: tmp = 180.0 * (math.atan(-((-0.5 * (B + (B * (C / A)))) / A)) / math.pi) else: tmp = (180.0 * math.atan((((C - A) - math.hypot((A - C), B)) * math.pow(B, -1.0)))) / math.pi return tmp
function code(A, B, C) tmp = 0.0 if (A <= -1.7e-19) tmp = Float64(180.0 * Float64(atan(Float64(-Float64(Float64(-0.5 * Float64(B + Float64(B * Float64(C / A)))) / A))) / pi)); else tmp = Float64(Float64(180.0 * atan(Float64(Float64(Float64(C - A) - hypot(Float64(A - C), B)) * (B ^ -1.0)))) / pi); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (A <= -1.7e-19) tmp = 180.0 * (atan(-((-0.5 * (B + (B * (C / A)))) / A)) / pi); else tmp = (180.0 * atan((((C - A) - hypot((A - C), B)) * (B ^ -1.0)))) / pi; end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[A, -1.7e-19], 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[(N[(180.0 * N[ArcTan[N[(N[(N[(C - A), $MachinePrecision] - N[Sqrt[N[(A - C), $MachinePrecision] ^ 2 + B ^ 2], $MachinePrecision]), $MachinePrecision] * N[Power[B, -1.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;A \leq -1.7 \cdot 10^{-19}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(-\frac{-0.5 \cdot \left(B + B \cdot \frac{C}{A}\right)}{A}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(\left(\left(C - A\right) - \mathsf{hypot}\left(A - C, B\right)\right) \cdot {B}^{-1}\right)}{\pi}\\
\end{array}
\end{array}
if A < -1.7000000000000001e-19Initial program 25.9%
Taylor expanded in A around -inf
mul-1-negN/A
lower-neg.f64N/A
lower-/.f64N/A
distribute-lft-outN/A
lower-*.f64N/A
lower-+.f64N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6464.7
Applied rewrites64.7%
if -1.7000000000000001e-19 < A Initial program 63.9%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites84.9%
(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-8)
(* 180.0 (/ (atan (* (/ 1.0 B) (- (- C A) B))) PI))
(if (<= t_0 0.0)
(* 180.0 (/ (atan (* (/ B A) 0.5)) PI))
(/ (* 180.0 (atan (+ 1.0 (/ (- C A) B)))) 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-8) {
tmp = 180.0 * (atan(((1.0 / B) * ((C - A) - B))) / ((double) M_PI));
} else if (t_0 <= 0.0) {
tmp = 180.0 * (atan(((B / A) * 0.5)) / ((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 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-8) {
tmp = 180.0 * (Math.atan(((1.0 / B) * ((C - A) - B))) / Math.PI);
} else if (t_0 <= 0.0) {
tmp = 180.0 * (Math.atan(((B / A) * 0.5)) / Math.PI);
} else {
tmp = (180.0 * Math.atan((1.0 + ((C - A) / B)))) / Math.PI;
}
return tmp;
}
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-8: tmp = 180.0 * (math.atan(((1.0 / B) * ((C - A) - B))) / math.pi) elif t_0 <= 0.0: tmp = 180.0 * (math.atan(((B / A) * 0.5)) / math.pi) else: tmp = (180.0 * math.atan((1.0 + ((C - A) / B)))) / math.pi return tmp
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-8) tmp = Float64(180.0 * Float64(atan(Float64(Float64(1.0 / B) * Float64(Float64(C - A) - B))) / pi)); elseif (t_0 <= 0.0) tmp = Float64(180.0 * Float64(atan(Float64(Float64(B / A) * 0.5)) / 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) t_0 = (1.0 / B) * ((C - A) - sqrt((((A - C) ^ 2.0) + (B ^ 2.0)))); tmp = 0.0; if (t_0 <= -1e-8) tmp = 180.0 * (atan(((1.0 / B) * ((C - A) - B))) / pi); elseif (t_0 <= 0.0) tmp = 180.0 * (atan(((B / A) * 0.5)) / pi); else tmp = (180.0 * atan((1.0 + ((C - A) / B)))) / pi; end tmp_2 = tmp; end
code[A_, B_, C_] := Block[{t$95$0 = N[(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-8], N[(180.0 * N[(N[ArcTan[N[(N[(1.0 / B), $MachinePrecision] * N[(N[(C - A), $MachinePrecision] - B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$0, 0.0], N[(180.0 * N[(N[ArcTan[N[(N[(B / A), $MachinePrecision] * 0.5), $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}
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^{-8}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - B\right)\right)}{\pi}\\
\mathbf{elif}\;t\_0 \leq 0:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A} \cdot 0.5\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
\end{array}
\end{array}
if (*.f64 (/.f64 #s(literal 1 binary64) B) (-.f64 (-.f64 C A) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) #s(literal 2 binary64)) (pow.f64 B #s(literal 2 binary64)))))) < -1e-8Initial program 59.4%
Taylor expanded in B around inf
Applied rewrites75.6%
if -1e-8 < (*.f64 (/.f64 #s(literal 1 binary64) B) (-.f64 (-.f64 C A) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) #s(literal 2 binary64)) (pow.f64 B #s(literal 2 binary64)))))) < -0.0Initial program 17.8%
Taylor expanded in A around -inf
*-commutativeN/A
lower-*.f64N/A
lower-/.f6451.1
Applied rewrites51.1%
if -0.0 < (*.f64 (/.f64 #s(literal 1 binary64) B) (-.f64 (-.f64 C A) (sqrt.f64 (+.f64 (pow.f64 (-.f64 A C) #s(literal 2 binary64)) (pow.f64 B #s(literal 2 binary64)))))) Initial program 59.0%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites87.3%
Taylor expanded in B around -inf
associate--l+N/A
div-subN/A
lower-+.f64N/A
lower-/.f64N/A
lift--.f6476.7
Applied rewrites76.7%
(FPCore (A B C)
:precision binary64
(if (<= C -6.1e+82)
(* 180.0 (/ (atan (* (/ 1.0 B) (- (- C A) B))) PI))
(if (<= C 1.8e+43)
(/ (* 180.0 (atan (- (/ (+ (hypot B A) A) B)))) PI)
(/
(* 180.0 (atan (fma -0.5 (+ (/ B C) (* A (/ B (* C C)))) (/ 0.0 B))))
PI))))
double code(double A, double B, double C) {
double tmp;
if (C <= -6.1e+82) {
tmp = 180.0 * (atan(((1.0 / B) * ((C - A) - B))) / ((double) M_PI));
} else if (C <= 1.8e+43) {
tmp = (180.0 * atan(-((hypot(B, A) + A) / B))) / ((double) M_PI);
} else {
tmp = (180.0 * atan(fma(-0.5, ((B / C) + (A * (B / (C * C)))), (0.0 / B)))) / ((double) M_PI);
}
return tmp;
}
function code(A, B, C) tmp = 0.0 if (C <= -6.1e+82) tmp = Float64(180.0 * Float64(atan(Float64(Float64(1.0 / B) * Float64(Float64(C - A) - B))) / pi)); elseif (C <= 1.8e+43) tmp = Float64(Float64(180.0 * atan(Float64(-Float64(Float64(hypot(B, A) + A) / B)))) / pi); else tmp = Float64(Float64(180.0 * atan(fma(-0.5, Float64(Float64(B / C) + Float64(A * Float64(B / Float64(C * C)))), Float64(0.0 / B)))) / pi); end return tmp end
code[A_, B_, C_] := If[LessEqual[C, -6.1e+82], N[(180.0 * N[(N[ArcTan[N[(N[(1.0 / B), $MachinePrecision] * N[(N[(C - A), $MachinePrecision] - B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, 1.8e+43], N[(N[(180.0 * N[ArcTan[(-N[(N[(N[Sqrt[B ^ 2 + A ^ 2], $MachinePrecision] + A), $MachinePrecision] / B), $MachinePrecision])], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], N[(N[(180.0 * N[ArcTan[N[(-0.5 * N[(N[(B / C), $MachinePrecision] + N[(A * N[(B / N[(C * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.0 / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq -6.1 \cdot 10^{+82}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - B\right)\right)}{\pi}\\
\mathbf{elif}\;C \leq 1.8 \cdot 10^{+43}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(-\frac{\mathsf{hypot}\left(B, A\right) + A}{B}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(\mathsf{fma}\left(-0.5, \frac{B}{C} + A \cdot \frac{B}{C \cdot C}, \frac{0}{B}\right)\right)}{\pi}\\
\end{array}
\end{array}
if C < -6.0999999999999999e82Initial program 79.6%
Taylor expanded in B around inf
Applied rewrites82.8%
if -6.0999999999999999e82 < C < 1.80000000000000005e43Initial program 57.0%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites80.1%
Taylor expanded in C around 0
mul-1-negN/A
lower-neg.f64N/A
lower-/.f64N/A
+-commutativeN/A
lower-+.f64N/A
+-commutativeN/A
pow2N/A
unpow2N/A
lower-hypot.f6475.1
Applied rewrites75.1%
if 1.80000000000000005e43 < C Initial program 22.5%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites55.8%
Taylor expanded in C around inf
+-commutativeN/A
distribute-lft-outN/A
mul-1-negN/A
distribute-rgt1-inN/A
metadata-evalN/A
lift-*.f64N/A
lift-/.f64N/A
lift-neg.f64N/A
lower-fma.f64N/A
Applied rewrites70.2%
(FPCore (A B C)
:precision binary64
(if (<= C -6.1e+82)
(* 180.0 (/ (atan (* (/ 1.0 B) (- (- C A) B))) PI))
(if (<= C 1.8e+43)
(* 180.0 (/ (atan (- (/ (+ (hypot A B) A) B))) PI))
(/
(* 180.0 (atan (fma -0.5 (+ (/ B C) (* A (/ B (* C C)))) (/ 0.0 B))))
PI))))
double code(double A, double B, double C) {
double tmp;
if (C <= -6.1e+82) {
tmp = 180.0 * (atan(((1.0 / B) * ((C - A) - B))) / ((double) M_PI));
} else if (C <= 1.8e+43) {
tmp = 180.0 * (atan(-((hypot(A, B) + A) / B)) / ((double) M_PI));
} else {
tmp = (180.0 * atan(fma(-0.5, ((B / C) + (A * (B / (C * C)))), (0.0 / B)))) / ((double) M_PI);
}
return tmp;
}
function code(A, B, C) tmp = 0.0 if (C <= -6.1e+82) tmp = Float64(180.0 * Float64(atan(Float64(Float64(1.0 / B) * Float64(Float64(C - A) - B))) / pi)); elseif (C <= 1.8e+43) tmp = Float64(180.0 * Float64(atan(Float64(-Float64(Float64(hypot(A, B) + A) / B))) / pi)); else tmp = Float64(Float64(180.0 * atan(fma(-0.5, Float64(Float64(B / C) + Float64(A * Float64(B / Float64(C * C)))), Float64(0.0 / B)))) / pi); end return tmp end
code[A_, B_, C_] := If[LessEqual[C, -6.1e+82], N[(180.0 * N[(N[ArcTan[N[(N[(1.0 / B), $MachinePrecision] * N[(N[(C - A), $MachinePrecision] - B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, 1.8e+43], N[(180.0 * N[(N[ArcTan[(-N[(N[(N[Sqrt[A ^ 2 + B ^ 2], $MachinePrecision] + A), $MachinePrecision] / B), $MachinePrecision])], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(N[(180.0 * N[ArcTan[N[(-0.5 * N[(N[(B / C), $MachinePrecision] + N[(A * N[(B / N[(C * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.0 / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq -6.1 \cdot 10^{+82}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{1}{B} \cdot \left(\left(C - A\right) - B\right)\right)}{\pi}\\
\mathbf{elif}\;C \leq 1.8 \cdot 10^{+43}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(-\frac{\mathsf{hypot}\left(A, B\right) + A}{B}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(\mathsf{fma}\left(-0.5, \frac{B}{C} + A \cdot \frac{B}{C \cdot C}, \frac{0}{B}\right)\right)}{\pi}\\
\end{array}
\end{array}
if C < -6.0999999999999999e82Initial program 79.6%
Taylor expanded in B around inf
Applied rewrites82.8%
if -6.0999999999999999e82 < C < 1.80000000000000005e43Initial program 57.0%
Taylor expanded in C around 0
mul-1-negN/A
lower-neg.f64N/A
lower-/.f64N/A
+-commutativeN/A
lower-+.f64N/A
unpow2N/A
unpow2N/A
lower-hypot.f6475.1
Applied rewrites75.1%
if 1.80000000000000005e43 < C Initial program 22.5%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites55.8%
Taylor expanded in C around inf
+-commutativeN/A
distribute-lft-outN/A
mul-1-negN/A
distribute-rgt1-inN/A
metadata-evalN/A
lift-*.f64N/A
lift-/.f64N/A
lift-neg.f64N/A
lower-fma.f64N/A
Applied rewrites70.2%
(FPCore (A B C)
:precision binary64
(if (<= C -4.8e+82)
(* 180.0 (/ (atan (/ C B)) PI))
(if (<= C -8.2e-13)
(* 180.0 (/ (atan (* (/ B A) 0.5)) PI))
(if (<= C -3.5e-306)
(/ (* 180.0 (atan (- -1.0 (/ A B)))) PI)
(if (<= C 4.8e-115)
(* 180.0 (/ (atan 1.0) PI))
(* 180.0 (/ (atan (* (/ B C) -0.5)) PI)))))))
double code(double A, double B, double C) {
double tmp;
if (C <= -4.8e+82) {
tmp = 180.0 * (atan((C / B)) / ((double) M_PI));
} else if (C <= -8.2e-13) {
tmp = 180.0 * (atan(((B / A) * 0.5)) / ((double) M_PI));
} else if (C <= -3.5e-306) {
tmp = (180.0 * atan((-1.0 - (A / B)))) / ((double) M_PI);
} else if (C <= 4.8e-115) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else {
tmp = 180.0 * (atan(((B / C) * -0.5)) / ((double) M_PI));
}
return tmp;
}
public static double code(double A, double B, double C) {
double tmp;
if (C <= -4.8e+82) {
tmp = 180.0 * (Math.atan((C / B)) / Math.PI);
} else if (C <= -8.2e-13) {
tmp = 180.0 * (Math.atan(((B / A) * 0.5)) / Math.PI);
} else if (C <= -3.5e-306) {
tmp = (180.0 * Math.atan((-1.0 - (A / B)))) / Math.PI;
} else if (C <= 4.8e-115) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else {
tmp = 180.0 * (Math.atan(((B / C) * -0.5)) / Math.PI);
}
return tmp;
}
def code(A, B, C): tmp = 0 if C <= -4.8e+82: tmp = 180.0 * (math.atan((C / B)) / math.pi) elif C <= -8.2e-13: tmp = 180.0 * (math.atan(((B / A) * 0.5)) / math.pi) elif C <= -3.5e-306: tmp = (180.0 * math.atan((-1.0 - (A / B)))) / math.pi elif C <= 4.8e-115: tmp = 180.0 * (math.atan(1.0) / math.pi) else: tmp = 180.0 * (math.atan(((B / C) * -0.5)) / math.pi) return tmp
function code(A, B, C) tmp = 0.0 if (C <= -4.8e+82) tmp = Float64(180.0 * Float64(atan(Float64(C / B)) / pi)); elseif (C <= -8.2e-13) tmp = Float64(180.0 * Float64(atan(Float64(Float64(B / A) * 0.5)) / pi)); elseif (C <= -3.5e-306) tmp = Float64(Float64(180.0 * atan(Float64(-1.0 - Float64(A / B)))) / pi); elseif (C <= 4.8e-115) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); else tmp = Float64(180.0 * Float64(atan(Float64(Float64(B / C) * -0.5)) / pi)); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (C <= -4.8e+82) tmp = 180.0 * (atan((C / B)) / pi); elseif (C <= -8.2e-13) tmp = 180.0 * (atan(((B / A) * 0.5)) / pi); elseif (C <= -3.5e-306) tmp = (180.0 * atan((-1.0 - (A / B)))) / pi; elseif (C <= 4.8e-115) tmp = 180.0 * (atan(1.0) / pi); else tmp = 180.0 * (atan(((B / C) * -0.5)) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[C, -4.8e+82], N[(180.0 * N[(N[ArcTan[N[(C / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, -8.2e-13], N[(180.0 * N[(N[ArcTan[N[(N[(B / A), $MachinePrecision] * 0.5), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, -3.5e-306], N[(N[(180.0 * N[ArcTan[N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], If[LessEqual[C, 4.8e-115], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(B / C), $MachinePrecision] * -0.5), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq -4.8 \cdot 10^{+82}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B}\right)}{\pi}\\
\mathbf{elif}\;C \leq -8.2 \cdot 10^{-13}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A} \cdot 0.5\right)}{\pi}\\
\mathbf{elif}\;C \leq -3.5 \cdot 10^{-306}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(-1 - \frac{A}{B}\right)}{\pi}\\
\mathbf{elif}\;C \leq 4.8 \cdot 10^{-115}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{C} \cdot -0.5\right)}{\pi}\\
\end{array}
\end{array}
if C < -4.79999999999999996e82Initial program 79.7%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites95.4%
Taylor expanded in B around inf
associate--r+N/A
lower--.f64N/A
lower--.f64N/A
lift-/.f64N/A
lower-/.f6480.2
Applied rewrites80.2%
Taylor expanded in C around inf
lift-/.f6475.1
Applied rewrites75.1%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6475.1
Applied rewrites75.1%
if -4.79999999999999996e82 < C < -8.2000000000000004e-13Initial program 65.8%
Taylor expanded in A around -inf
*-commutativeN/A
lower-*.f64N/A
lower-/.f6428.0
Applied rewrites28.0%
if -8.2000000000000004e-13 < C < -3.50000000000000018e-306Initial program 60.6%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites83.5%
Taylor expanded in B around inf
associate--r+N/A
lower--.f64N/A
lower--.f64N/A
lift-/.f64N/A
lower-/.f6453.8
Applied rewrites53.8%
Taylor expanded in B around inf
Applied rewrites48.6%
if -3.50000000000000018e-306 < C < 4.80000000000000042e-115Initial program 56.5%
Taylor expanded in B around -inf
Applied rewrites29.5%
if 4.80000000000000042e-115 < C Initial program 31.6%
Taylor expanded in C around inf
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
mul-1-negN/A
lower-neg.f64N/A
lower-/.f64N/A
distribute-rgt1-inN/A
metadata-evalN/A
lower-*.f6456.2
Applied rewrites56.2%
Taylor expanded in A around 0
*-commutativeN/A
lower-*.f64N/A
lift-/.f6456.2
Applied rewrites56.2%
(FPCore (A B C)
:precision binary64
(if (<= C -5e-73)
(* 180.0 (/ (atan (* (/ C B) 2.0)) PI))
(if (<= C -3.5e-306)
(/ (* 180.0 (atan (- -1.0 (/ A B)))) PI)
(if (<= C 4.8e-115)
(* 180.0 (/ (atan 1.0) PI))
(/ (* 180.0 (atan (* -0.5 (/ B C)))) PI)))))
double code(double A, double B, double C) {
double tmp;
if (C <= -5e-73) {
tmp = 180.0 * (atan(((C / B) * 2.0)) / ((double) M_PI));
} else if (C <= -3.5e-306) {
tmp = (180.0 * atan((-1.0 - (A / B)))) / ((double) M_PI);
} else if (C <= 4.8e-115) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else {
tmp = (180.0 * atan((-0.5 * (B / C)))) / ((double) M_PI);
}
return tmp;
}
public static double code(double A, double B, double C) {
double tmp;
if (C <= -5e-73) {
tmp = 180.0 * (Math.atan(((C / B) * 2.0)) / Math.PI);
} else if (C <= -3.5e-306) {
tmp = (180.0 * Math.atan((-1.0 - (A / B)))) / Math.PI;
} else if (C <= 4.8e-115) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else {
tmp = (180.0 * Math.atan((-0.5 * (B / C)))) / Math.PI;
}
return tmp;
}
def code(A, B, C): tmp = 0 if C <= -5e-73: tmp = 180.0 * (math.atan(((C / B) * 2.0)) / math.pi) elif C <= -3.5e-306: tmp = (180.0 * math.atan((-1.0 - (A / B)))) / math.pi elif C <= 4.8e-115: tmp = 180.0 * (math.atan(1.0) / math.pi) else: tmp = (180.0 * math.atan((-0.5 * (B / C)))) / math.pi return tmp
function code(A, B, C) tmp = 0.0 if (C <= -5e-73) tmp = Float64(180.0 * Float64(atan(Float64(Float64(C / B) * 2.0)) / pi)); elseif (C <= -3.5e-306) tmp = Float64(Float64(180.0 * atan(Float64(-1.0 - Float64(A / B)))) / pi); elseif (C <= 4.8e-115) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); else tmp = Float64(Float64(180.0 * atan(Float64(-0.5 * Float64(B / C)))) / pi); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (C <= -5e-73) tmp = 180.0 * (atan(((C / B) * 2.0)) / pi); elseif (C <= -3.5e-306) tmp = (180.0 * atan((-1.0 - (A / B)))) / pi; elseif (C <= 4.8e-115) tmp = 180.0 * (atan(1.0) / pi); else tmp = (180.0 * atan((-0.5 * (B / C)))) / pi; end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[C, -5e-73], N[(180.0 * N[(N[ArcTan[N[(N[(C / B), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, -3.5e-306], N[(N[(180.0 * N[ArcTan[N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], If[LessEqual[C, 4.8e-115], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(N[(180.0 * N[ArcTan[N[(-0.5 * N[(B / C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq -5 \cdot 10^{-73}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} \cdot 2\right)}{\pi}\\
\mathbf{elif}\;C \leq -3.5 \cdot 10^{-306}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(-1 - \frac{A}{B}\right)}{\pi}\\
\mathbf{elif}\;C \leq 4.8 \cdot 10^{-115}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(-0.5 \cdot \frac{B}{C}\right)}{\pi}\\
\end{array}
\end{array}
if C < -4.9999999999999998e-73Initial program 73.9%
Taylor expanded in C around -inf
*-commutativeN/A
lower-*.f64N/A
lower-/.f6461.2
Applied rewrites61.2%
if -4.9999999999999998e-73 < C < -3.50000000000000018e-306Initial program 59.3%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites83.1%
Taylor expanded in B around inf
associate--r+N/A
lower--.f64N/A
lower--.f64N/A
lift-/.f64N/A
lower-/.f6452.1
Applied rewrites52.1%
Taylor expanded in B around inf
Applied rewrites49.0%
if -3.50000000000000018e-306 < C < 4.80000000000000042e-115Initial program 56.5%
Taylor expanded in B around -inf
Applied rewrites29.5%
if 4.80000000000000042e-115 < C Initial program 31.6%
Taylor expanded in C around inf
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
mul-1-negN/A
lower-neg.f64N/A
lower-/.f64N/A
distribute-rgt1-inN/A
metadata-evalN/A
lower-*.f6456.2
Applied rewrites56.2%
Taylor expanded in A around 0
*-commutativeN/A
lower-*.f64N/A
lift-/.f6456.2
Applied rewrites56.2%
lift-*.f64N/A
lift-/.f64N/A
associate-*r/N/A
lower-/.f64N/A
Applied rewrites56.2%
(FPCore (A B C)
:precision binary64
(if (<= C -5e-73)
(* 180.0 (/ (atan (* (/ C B) 2.0)) PI))
(if (<= C -3.5e-306)
(/ (* 180.0 (atan (- -1.0 (/ A B)))) PI)
(if (<= C 4.8e-115)
(* 180.0 (/ (atan 1.0) PI))
(* 180.0 (/ (atan (* (/ B C) -0.5)) PI))))))
double code(double A, double B, double C) {
double tmp;
if (C <= -5e-73) {
tmp = 180.0 * (atan(((C / B) * 2.0)) / ((double) M_PI));
} else if (C <= -3.5e-306) {
tmp = (180.0 * atan((-1.0 - (A / B)))) / ((double) M_PI);
} else if (C <= 4.8e-115) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else {
tmp = 180.0 * (atan(((B / C) * -0.5)) / ((double) M_PI));
}
return tmp;
}
public static double code(double A, double B, double C) {
double tmp;
if (C <= -5e-73) {
tmp = 180.0 * (Math.atan(((C / B) * 2.0)) / Math.PI);
} else if (C <= -3.5e-306) {
tmp = (180.0 * Math.atan((-1.0 - (A / B)))) / Math.PI;
} else if (C <= 4.8e-115) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else {
tmp = 180.0 * (Math.atan(((B / C) * -0.5)) / Math.PI);
}
return tmp;
}
def code(A, B, C): tmp = 0 if C <= -5e-73: tmp = 180.0 * (math.atan(((C / B) * 2.0)) / math.pi) elif C <= -3.5e-306: tmp = (180.0 * math.atan((-1.0 - (A / B)))) / math.pi elif C <= 4.8e-115: tmp = 180.0 * (math.atan(1.0) / math.pi) else: tmp = 180.0 * (math.atan(((B / C) * -0.5)) / math.pi) return tmp
function code(A, B, C) tmp = 0.0 if (C <= -5e-73) tmp = Float64(180.0 * Float64(atan(Float64(Float64(C / B) * 2.0)) / pi)); elseif (C <= -3.5e-306) tmp = Float64(Float64(180.0 * atan(Float64(-1.0 - Float64(A / B)))) / pi); elseif (C <= 4.8e-115) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); else tmp = Float64(180.0 * Float64(atan(Float64(Float64(B / C) * -0.5)) / pi)); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (C <= -5e-73) tmp = 180.0 * (atan(((C / B) * 2.0)) / pi); elseif (C <= -3.5e-306) tmp = (180.0 * atan((-1.0 - (A / B)))) / pi; elseif (C <= 4.8e-115) tmp = 180.0 * (atan(1.0) / pi); else tmp = 180.0 * (atan(((B / C) * -0.5)) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[C, -5e-73], N[(180.0 * N[(N[ArcTan[N[(N[(C / B), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, -3.5e-306], N[(N[(180.0 * N[ArcTan[N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], If[LessEqual[C, 4.8e-115], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(B / C), $MachinePrecision] * -0.5), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq -5 \cdot 10^{-73}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B} \cdot 2\right)}{\pi}\\
\mathbf{elif}\;C \leq -3.5 \cdot 10^{-306}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(-1 - \frac{A}{B}\right)}{\pi}\\
\mathbf{elif}\;C \leq 4.8 \cdot 10^{-115}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{C} \cdot -0.5\right)}{\pi}\\
\end{array}
\end{array}
if C < -4.9999999999999998e-73Initial program 73.9%
Taylor expanded in C around -inf
*-commutativeN/A
lower-*.f64N/A
lower-/.f6461.2
Applied rewrites61.2%
if -4.9999999999999998e-73 < C < -3.50000000000000018e-306Initial program 59.3%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites83.1%
Taylor expanded in B around inf
associate--r+N/A
lower--.f64N/A
lower--.f64N/A
lift-/.f64N/A
lower-/.f6452.1
Applied rewrites52.1%
Taylor expanded in B around inf
Applied rewrites49.0%
if -3.50000000000000018e-306 < C < 4.80000000000000042e-115Initial program 56.5%
Taylor expanded in B around -inf
Applied rewrites29.5%
if 4.80000000000000042e-115 < C Initial program 31.6%
Taylor expanded in C around inf
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
mul-1-negN/A
lower-neg.f64N/A
lower-/.f64N/A
distribute-rgt1-inN/A
metadata-evalN/A
lower-*.f6456.2
Applied rewrites56.2%
Taylor expanded in A around 0
*-commutativeN/A
lower-*.f64N/A
lift-/.f6456.2
Applied rewrites56.2%
(FPCore (A B C)
:precision binary64
(if (<= C -5e-73)
(* 180.0 (/ (atan (/ C B)) PI))
(if (<= C -3.5e-306)
(/ (* 180.0 (atan (- -1.0 (/ A B)))) PI)
(if (<= C 4.8e-115)
(* 180.0 (/ (atan 1.0) PI))
(* 180.0 (/ (atan (* (/ B C) -0.5)) PI))))))
double code(double A, double B, double C) {
double tmp;
if (C <= -5e-73) {
tmp = 180.0 * (atan((C / B)) / ((double) M_PI));
} else if (C <= -3.5e-306) {
tmp = (180.0 * atan((-1.0 - (A / B)))) / ((double) M_PI);
} else if (C <= 4.8e-115) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else {
tmp = 180.0 * (atan(((B / C) * -0.5)) / ((double) M_PI));
}
return tmp;
}
public static double code(double A, double B, double C) {
double tmp;
if (C <= -5e-73) {
tmp = 180.0 * (Math.atan((C / B)) / Math.PI);
} else if (C <= -3.5e-306) {
tmp = (180.0 * Math.atan((-1.0 - (A / B)))) / Math.PI;
} else if (C <= 4.8e-115) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else {
tmp = 180.0 * (Math.atan(((B / C) * -0.5)) / Math.PI);
}
return tmp;
}
def code(A, B, C): tmp = 0 if C <= -5e-73: tmp = 180.0 * (math.atan((C / B)) / math.pi) elif C <= -3.5e-306: tmp = (180.0 * math.atan((-1.0 - (A / B)))) / math.pi elif C <= 4.8e-115: tmp = 180.0 * (math.atan(1.0) / math.pi) else: tmp = 180.0 * (math.atan(((B / C) * -0.5)) / math.pi) return tmp
function code(A, B, C) tmp = 0.0 if (C <= -5e-73) tmp = Float64(180.0 * Float64(atan(Float64(C / B)) / pi)); elseif (C <= -3.5e-306) tmp = Float64(Float64(180.0 * atan(Float64(-1.0 - Float64(A / B)))) / pi); elseif (C <= 4.8e-115) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); else tmp = Float64(180.0 * Float64(atan(Float64(Float64(B / C) * -0.5)) / pi)); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (C <= -5e-73) tmp = 180.0 * (atan((C / B)) / pi); elseif (C <= -3.5e-306) tmp = (180.0 * atan((-1.0 - (A / B)))) / pi; elseif (C <= 4.8e-115) tmp = 180.0 * (atan(1.0) / pi); else tmp = 180.0 * (atan(((B / C) * -0.5)) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[C, -5e-73], N[(180.0 * N[(N[ArcTan[N[(C / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[C, -3.5e-306], N[(N[(180.0 * N[ArcTan[N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], If[LessEqual[C, 4.8e-115], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(180.0 * N[(N[ArcTan[N[(N[(B / C), $MachinePrecision] * -0.5), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;C \leq -5 \cdot 10^{-73}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B}\right)}{\pi}\\
\mathbf{elif}\;C \leq -3.5 \cdot 10^{-306}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(-1 - \frac{A}{B}\right)}{\pi}\\
\mathbf{elif}\;C \leq 4.8 \cdot 10^{-115}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{C} \cdot -0.5\right)}{\pi}\\
\end{array}
\end{array}
if C < -4.9999999999999998e-73Initial program 73.9%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites92.2%
Taylor expanded in B around inf
associate--r+N/A
lower--.f64N/A
lower--.f64N/A
lift-/.f64N/A
lower-/.f6473.0
Applied rewrites73.0%
Taylor expanded in C around inf
lift-/.f6460.8
Applied rewrites60.8%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6460.8
Applied rewrites60.8%
if -4.9999999999999998e-73 < C < -3.50000000000000018e-306Initial program 59.3%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites83.1%
Taylor expanded in B around inf
associate--r+N/A
lower--.f64N/A
lower--.f64N/A
lift-/.f64N/A
lower-/.f6452.1
Applied rewrites52.1%
Taylor expanded in B around inf
Applied rewrites49.0%
if -3.50000000000000018e-306 < C < 4.80000000000000042e-115Initial program 56.5%
Taylor expanded in B around -inf
Applied rewrites29.5%
if 4.80000000000000042e-115 < C Initial program 31.6%
Taylor expanded in C around inf
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
mul-1-negN/A
lower-neg.f64N/A
lower-/.f64N/A
distribute-rgt1-inN/A
metadata-evalN/A
lower-*.f6456.2
Applied rewrites56.2%
Taylor expanded in A around 0
*-commutativeN/A
lower-*.f64N/A
lift-/.f6456.2
Applied rewrites56.2%
(FPCore (A B C)
:precision binary64
(if (<= B -3.2e-23)
(* 180.0 (/ (atan 1.0) PI))
(if (<= B -1.75e-283)
(* 180.0 (/ (atan (/ C B)) PI))
(if (<= B 2.9e-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 <= -3.2e-23) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else if (B <= -1.75e-283) {
tmp = 180.0 * (atan((C / B)) / ((double) M_PI));
} else if (B <= 2.9e-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 <= -3.2e-23) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else if (B <= -1.75e-283) {
tmp = 180.0 * (Math.atan((C / B)) / Math.PI);
} else if (B <= 2.9e-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 <= -3.2e-23: tmp = 180.0 * (math.atan(1.0) / math.pi) elif B <= -1.75e-283: tmp = 180.0 * (math.atan((C / B)) / math.pi) elif B <= 2.9e-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 <= -3.2e-23) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); elseif (B <= -1.75e-283) tmp = Float64(180.0 * Float64(atan(Float64(C / B)) / pi)); elseif (B <= 2.9e-123) tmp = Float64(Float64(180.0 * 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 <= -3.2e-23) tmp = 180.0 * (atan(1.0) / pi); elseif (B <= -1.75e-283) tmp = 180.0 * (atan((C / B)) / pi); elseif (B <= 2.9e-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, -3.2e-23], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, -1.75e-283], N[(180.0 * N[(N[ArcTan[N[(C / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 2.9e-123], N[(N[(180.0 * N[ArcTan[N[(0.0 / B), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision], N[(180.0 * N[(N[ArcTan[-1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;B \leq -3.2 \cdot 10^{-23}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{elif}\;B \leq -1.75 \cdot 10^{-283}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B}\right)}{\pi}\\
\mathbf{elif}\;B \leq 2.9 \cdot 10^{-123}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(\frac{0}{B}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
\end{array}
\end{array}
if B < -3.19999999999999976e-23Initial program 49.8%
Taylor expanded in B around -inf
Applied rewrites61.7%
if -3.19999999999999976e-23 < B < -1.7499999999999999e-283Initial program 57.9%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites74.8%
Taylor expanded in B around inf
associate--r+N/A
lower--.f64N/A
lower--.f64N/A
lift-/.f64N/A
lower-/.f6445.2
Applied rewrites45.2%
Taylor expanded in C around inf
lift-/.f6431.4
Applied rewrites31.4%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6431.4
Applied rewrites31.4%
if -1.7499999999999999e-283 < B < 2.90000000000000004e-123Initial program 59.1%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites81.3%
Taylor expanded in C around inf
distribute-rgt1-inN/A
metadata-evalN/A
lift-*.f64N/A
associate-*r/N/A
lift-*.f64N/A
mul0-lftN/A
metadata-evalN/A
mul0-lftN/A
lift-*.f64N/A
lift-/.f6430.9
lift-*.f64N/A
mul0-lft30.9
Applied rewrites30.9%
if 2.90000000000000004e-123 < B Initial program 51.3%
Taylor expanded in B around inf
Applied rewrites50.3%
(FPCore (A B C)
:precision binary64
(if (<= A -2.1e-18)
(* 180.0 (/ (atan (* (/ B A) 0.5)) PI))
(if (<= A -8.5e-123)
(* 180.0 (/ (atan (* (/ B C) -0.5)) PI))
(/ (* 180.0 (atan (+ 1.0 (/ (- C A) B)))) PI))))
double code(double A, double B, double C) {
double tmp;
if (A <= -2.1e-18) {
tmp = 180.0 * (atan(((B / A) * 0.5)) / ((double) M_PI));
} else if (A <= -8.5e-123) {
tmp = 180.0 * (atan(((B / C) * -0.5)) / ((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.1e-18) {
tmp = 180.0 * (Math.atan(((B / A) * 0.5)) / Math.PI);
} else if (A <= -8.5e-123) {
tmp = 180.0 * (Math.atan(((B / C) * -0.5)) / 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.1e-18: tmp = 180.0 * (math.atan(((B / A) * 0.5)) / math.pi) elif A <= -8.5e-123: tmp = 180.0 * (math.atan(((B / C) * -0.5)) / 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.1e-18) tmp = Float64(180.0 * Float64(atan(Float64(Float64(B / A) * 0.5)) / pi)); elseif (A <= -8.5e-123) tmp = Float64(180.0 * Float64(atan(Float64(Float64(B / C) * -0.5)) / 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 <= -2.1e-18) tmp = 180.0 * (atan(((B / A) * 0.5)) / pi); elseif (A <= -8.5e-123) tmp = 180.0 * (atan(((B / C) * -0.5)) / 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.1e-18], N[(180.0 * N[(N[ArcTan[N[(N[(B / A), $MachinePrecision] * 0.5), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -8.5e-123], N[(180.0 * N[(N[ArcTan[N[(N[(B / C), $MachinePrecision] * -0.5), $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 -2.1 \cdot 10^{-18}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A} \cdot 0.5\right)}{\pi}\\
\mathbf{elif}\;A \leq -8.5 \cdot 10^{-123}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{C} \cdot -0.5\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
\end{array}
\end{array}
if A < -2.1e-18Initial program 25.8%
Taylor expanded in A around -inf
*-commutativeN/A
lower-*.f64N/A
lower-/.f6463.7
Applied rewrites63.7%
if -2.1e-18 < A < -8.4999999999999995e-123Initial program 47.0%
Taylor expanded in C around inf
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
mul-1-negN/A
lower-neg.f64N/A
lower-/.f64N/A
distribute-rgt1-inN/A
metadata-evalN/A
lower-*.f6427.2
Applied rewrites27.2%
Taylor expanded in A around 0
*-commutativeN/A
lower-*.f64N/A
lift-/.f6427.2
Applied rewrites27.2%
if -8.4999999999999995e-123 < A Initial program 66.0%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites87.0%
Taylor expanded in B around -inf
associate--l+N/A
div-subN/A
lower-+.f64N/A
lower-/.f64N/A
lift--.f6463.0
Applied rewrites63.0%
(FPCore (A B C)
:precision binary64
(if (<= A -2.1e-18)
(* 180.0 (/ (atan (* (/ B A) 0.5)) PI))
(if (<= A -8.5e-123)
(* 180.0 (/ (atan (* (/ B C) -0.5)) PI))
(* 180.0 (/ (atan (+ 1.0 (/ (- C A) B))) PI)))))
double code(double A, double B, double C) {
double tmp;
if (A <= -2.1e-18) {
tmp = 180.0 * (atan(((B / A) * 0.5)) / ((double) M_PI));
} else if (A <= -8.5e-123) {
tmp = 180.0 * (atan(((B / C) * -0.5)) / ((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.1e-18) {
tmp = 180.0 * (Math.atan(((B / A) * 0.5)) / Math.PI);
} else if (A <= -8.5e-123) {
tmp = 180.0 * (Math.atan(((B / C) * -0.5)) / 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.1e-18: tmp = 180.0 * (math.atan(((B / A) * 0.5)) / math.pi) elif A <= -8.5e-123: tmp = 180.0 * (math.atan(((B / C) * -0.5)) / 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.1e-18) tmp = Float64(180.0 * Float64(atan(Float64(Float64(B / A) * 0.5)) / pi)); elseif (A <= -8.5e-123) tmp = Float64(180.0 * Float64(atan(Float64(Float64(B / C) * -0.5)) / 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.1e-18) tmp = 180.0 * (atan(((B / A) * 0.5)) / pi); elseif (A <= -8.5e-123) tmp = 180.0 * (atan(((B / C) * -0.5)) / 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.1e-18], N[(180.0 * N[(N[ArcTan[N[(N[(B / A), $MachinePrecision] * 0.5), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[A, -8.5e-123], N[(180.0 * N[(N[ArcTan[N[(N[(B / C), $MachinePrecision] * -0.5), $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.1 \cdot 10^{-18}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{A} \cdot 0.5\right)}{\pi}\\
\mathbf{elif}\;A \leq -8.5 \cdot 10^{-123}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{B}{C} \cdot -0.5\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(1 + \frac{C - A}{B}\right)}{\pi}\\
\end{array}
\end{array}
if A < -2.1e-18Initial program 25.8%
Taylor expanded in A around -inf
*-commutativeN/A
lower-*.f64N/A
lower-/.f6463.7
Applied rewrites63.7%
if -2.1e-18 < A < -8.4999999999999995e-123Initial program 47.0%
Taylor expanded in C around inf
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
mul-1-negN/A
lower-neg.f64N/A
lower-/.f64N/A
distribute-rgt1-inN/A
metadata-evalN/A
lower-*.f6427.2
Applied rewrites27.2%
Taylor expanded in A around 0
*-commutativeN/A
lower-*.f64N/A
lift-/.f6427.2
Applied rewrites27.2%
if -8.4999999999999995e-123 < A Initial program 66.0%
Taylor expanded in B around -inf
associate--l+N/A
div-subN/A
lower-+.f64N/A
lower-/.f64N/A
lift--.f6463.0
Applied rewrites63.0%
(FPCore (A B C)
:precision binary64
(if (<= B -3.2e-23)
(* 180.0 (/ (atan 1.0) PI))
(if (<= B 8.2e-256)
(* 180.0 (/ (atan (/ C B)) PI))
(/ (* 180.0 (atan (- -1.0 (/ A B)))) PI))))
double code(double A, double B, double C) {
double tmp;
if (B <= -3.2e-23) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else if (B <= 8.2e-256) {
tmp = 180.0 * (atan((C / B)) / ((double) M_PI));
} else {
tmp = (180.0 * atan((-1.0 - (A / B)))) / ((double) M_PI);
}
return tmp;
}
public static double code(double A, double B, double C) {
double tmp;
if (B <= -3.2e-23) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else if (B <= 8.2e-256) {
tmp = 180.0 * (Math.atan((C / B)) / Math.PI);
} else {
tmp = (180.0 * Math.atan((-1.0 - (A / B)))) / Math.PI;
}
return tmp;
}
def code(A, B, C): tmp = 0 if B <= -3.2e-23: tmp = 180.0 * (math.atan(1.0) / math.pi) elif B <= 8.2e-256: tmp = 180.0 * (math.atan((C / B)) / math.pi) else: tmp = (180.0 * math.atan((-1.0 - (A / B)))) / math.pi return tmp
function code(A, B, C) tmp = 0.0 if (B <= -3.2e-23) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); elseif (B <= 8.2e-256) tmp = Float64(180.0 * Float64(atan(Float64(C / B)) / pi)); else tmp = Float64(Float64(180.0 * atan(Float64(-1.0 - Float64(A / B)))) / pi); end return tmp end
function tmp_2 = code(A, B, C) tmp = 0.0; if (B <= -3.2e-23) tmp = 180.0 * (atan(1.0) / pi); elseif (B <= 8.2e-256) tmp = 180.0 * (atan((C / B)) / pi); else tmp = (180.0 * atan((-1.0 - (A / B)))) / pi; end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[B, -3.2e-23], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 8.2e-256], N[(180.0 * N[(N[ArcTan[N[(C / B), $MachinePrecision]], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], N[(N[(180.0 * N[ArcTan[N[(-1.0 - N[(A / B), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / Pi), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;B \leq -3.2 \cdot 10^{-23}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{elif}\;B \leq 8.2 \cdot 10^{-256}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;\frac{180 \cdot \tan^{-1} \left(-1 - \frac{A}{B}\right)}{\pi}\\
\end{array}
\end{array}
if B < -3.19999999999999976e-23Initial program 49.8%
Taylor expanded in B around -inf
Applied rewrites61.7%
if -3.19999999999999976e-23 < B < 8.2e-256Initial program 58.7%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites76.6%
Taylor expanded in B around inf
associate--r+N/A
lower--.f64N/A
lower--.f64N/A
lift-/.f64N/A
lower-/.f6445.1
Applied rewrites45.1%
Taylor expanded in C around inf
lift-/.f6432.5
Applied rewrites32.5%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6432.5
Applied rewrites32.5%
if 8.2e-256 < B Initial program 52.8%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites76.3%
Taylor expanded in B around inf
associate--r+N/A
lower--.f64N/A
lower--.f64N/A
lift-/.f64N/A
lower-/.f6466.6
Applied rewrites66.6%
Taylor expanded in B around inf
Applied rewrites57.1%
(FPCore (A B C)
:precision binary64
(if (<= B -3.2e-23)
(* 180.0 (/ (atan 1.0) PI))
(if (<= B 4.8e-22)
(* 180.0 (/ (atan (/ C B)) PI))
(* 180.0 (/ (atan -1.0) PI)))))
double code(double A, double B, double C) {
double tmp;
if (B <= -3.2e-23) {
tmp = 180.0 * (atan(1.0) / ((double) M_PI));
} else if (B <= 4.8e-22) {
tmp = 180.0 * (atan((C / 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 <= -3.2e-23) {
tmp = 180.0 * (Math.atan(1.0) / Math.PI);
} else if (B <= 4.8e-22) {
tmp = 180.0 * (Math.atan((C / B)) / Math.PI);
} else {
tmp = 180.0 * (Math.atan(-1.0) / Math.PI);
}
return tmp;
}
def code(A, B, C): tmp = 0 if B <= -3.2e-23: tmp = 180.0 * (math.atan(1.0) / math.pi) elif B <= 4.8e-22: tmp = 180.0 * (math.atan((C / 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 <= -3.2e-23) tmp = Float64(180.0 * Float64(atan(1.0) / pi)); elseif (B <= 4.8e-22) tmp = Float64(180.0 * Float64(atan(Float64(C / 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 <= -3.2e-23) tmp = 180.0 * (atan(1.0) / pi); elseif (B <= 4.8e-22) tmp = 180.0 * (atan((C / B)) / pi); else tmp = 180.0 * (atan(-1.0) / pi); end tmp_2 = tmp; end
code[A_, B_, C_] := If[LessEqual[B, -3.2e-23], N[(180.0 * N[(N[ArcTan[1.0], $MachinePrecision] / Pi), $MachinePrecision]), $MachinePrecision], If[LessEqual[B, 4.8e-22], N[(180.0 * N[(N[ArcTan[N[(C / 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 -3.2 \cdot 10^{-23}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} 1}{\pi}\\
\mathbf{elif}\;B \leq 4.8 \cdot 10^{-22}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} \left(\frac{C}{B}\right)}{\pi}\\
\mathbf{else}:\\
\;\;\;\;180 \cdot \frac{\tan^{-1} -1}{\pi}\\
\end{array}
\end{array}
if B < -3.19999999999999976e-23Initial program 49.8%
Taylor expanded in B around -inf
Applied rewrites61.7%
if -3.19999999999999976e-23 < B < 4.80000000000000005e-22Initial program 58.7%
lift-*.f64N/A
lift-PI.f64N/A
lift-/.f64N/A
Applied rewrites75.9%
Taylor expanded in B around inf
associate--r+N/A
lower--.f64N/A
lower--.f64N/A
lift-/.f64N/A
lower-/.f6449.0
Applied rewrites49.0%
Taylor expanded in C around inf
lift-/.f6431.8
Applied rewrites31.8%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6431.8
Applied rewrites31.8%
if 4.80000000000000005e-22 < B Initial program 48.8%
Taylor expanded in B around inf
Applied rewrites58.0%
(FPCore (A B C) :precision binary64 (if (<= B -2e-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 <= -2e-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 <= -2e-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 <= -2e-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 <= -2e-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 <= -2e-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, -2e-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 -2 \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 < -1.999999999999994e-310Initial program 53.7%
Taylor expanded in B around -inf
Applied rewrites41.1%
if -1.999999999999994e-310 < B Initial program 53.5%
Taylor expanded in B around inf
Applied rewrites39.5%
(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
Applied rewrites20.7%
herbie shell --seed 2025095
(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)))