ab-angle->ABCF B

Percentage Accurate: 53.1% → 67.5%
Time: 18.6s
Alternatives: 20
Speedup: 32.2×

Specification

?
\[\begin{array}{l} \\ \begin{array}{l} t_0 := \pi \cdot \frac{angle}{180}\\ \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin t\_0\right) \cdot \cos t\_0 \end{array} \end{array} \]
(FPCore (a b angle)
 :precision binary64
 (let* ((t_0 (* PI (/ angle 180.0))))
   (* (* (* 2.0 (- (pow b 2.0) (pow a 2.0))) (sin t_0)) (cos t_0))))
double code(double a, double b, double angle) {
	double t_0 = ((double) M_PI) * (angle / 180.0);
	return ((2.0 * (pow(b, 2.0) - pow(a, 2.0))) * sin(t_0)) * cos(t_0);
}
public static double code(double a, double b, double angle) {
	double t_0 = Math.PI * (angle / 180.0);
	return ((2.0 * (Math.pow(b, 2.0) - Math.pow(a, 2.0))) * Math.sin(t_0)) * Math.cos(t_0);
}
def code(a, b, angle):
	t_0 = math.pi * (angle / 180.0)
	return ((2.0 * (math.pow(b, 2.0) - math.pow(a, 2.0))) * math.sin(t_0)) * math.cos(t_0)
function code(a, b, angle)
	t_0 = Float64(pi * Float64(angle / 180.0))
	return Float64(Float64(Float64(2.0 * Float64((b ^ 2.0) - (a ^ 2.0))) * sin(t_0)) * cos(t_0))
end
function tmp = code(a, b, angle)
	t_0 = pi * (angle / 180.0);
	tmp = ((2.0 * ((b ^ 2.0) - (a ^ 2.0))) * sin(t_0)) * cos(t_0);
end
code[a_, b_, angle_] := Block[{t$95$0 = N[(Pi * N[(angle / 180.0), $MachinePrecision]), $MachinePrecision]}, N[(N[(N[(2.0 * N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision] * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \pi \cdot \frac{angle}{180}\\
\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin t\_0\right) \cdot \cos t\_0
\end{array}
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 20 alternatives:

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

Initial Program: 53.1% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \pi \cdot \frac{angle}{180}\\ \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin t\_0\right) \cdot \cos t\_0 \end{array} \end{array} \]
(FPCore (a b angle)
 :precision binary64
 (let* ((t_0 (* PI (/ angle 180.0))))
   (* (* (* 2.0 (- (pow b 2.0) (pow a 2.0))) (sin t_0)) (cos t_0))))
double code(double a, double b, double angle) {
	double t_0 = ((double) M_PI) * (angle / 180.0);
	return ((2.0 * (pow(b, 2.0) - pow(a, 2.0))) * sin(t_0)) * cos(t_0);
}
public static double code(double a, double b, double angle) {
	double t_0 = Math.PI * (angle / 180.0);
	return ((2.0 * (Math.pow(b, 2.0) - Math.pow(a, 2.0))) * Math.sin(t_0)) * Math.cos(t_0);
}
def code(a, b, angle):
	t_0 = math.pi * (angle / 180.0)
	return ((2.0 * (math.pow(b, 2.0) - math.pow(a, 2.0))) * math.sin(t_0)) * math.cos(t_0)
function code(a, b, angle)
	t_0 = Float64(pi * Float64(angle / 180.0))
	return Float64(Float64(Float64(2.0 * Float64((b ^ 2.0) - (a ^ 2.0))) * sin(t_0)) * cos(t_0))
end
function tmp = code(a, b, angle)
	t_0 = pi * (angle / 180.0);
	tmp = ((2.0 * ((b ^ 2.0) - (a ^ 2.0))) * sin(t_0)) * cos(t_0);
end
code[a_, b_, angle_] := Block[{t$95$0 = N[(Pi * N[(angle / 180.0), $MachinePrecision]), $MachinePrecision]}, N[(N[(N[(2.0 * N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision] * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \pi \cdot \frac{angle}{180}\\
\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin t\_0\right) \cdot \cos t\_0
\end{array}
\end{array}

Alternative 1: 67.5% accurate, 0.7× speedup?

\[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\\ t_1 := \frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle\_m}}\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+98}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin t\_0\right)\\ \mathbf{elif}\;\frac{angle\_m}{180} \leq 10^{+135}:\\ \;\;\;\;\frac{2 \cdot \sin \left(e^{0 - \log \left(\frac{180}{angle\_m \cdot \pi}\right)}\right)}{\frac{1}{b \cdot b - a \cdot a}} \cdot \cos \left(\frac{angle\_m}{180} \cdot \pi\right)\\ \mathbf{elif}\;\frac{angle\_m}{180} \leq 10^{+163}:\\ \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot t\_0\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b + a\right) \cdot \left(2 \cdot \sin t\_1\right)\right) \cdot \left(\left(b - a\right) \cdot \cos t\_1\right)\\ \end{array} \end{array} \end{array} \]
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a b angle_m)
 :precision binary64
 (let* ((t_0 (* (* angle_m PI) 0.011111111111111112))
        (t_1 (/ (pow (sqrt PI) 2.0) (/ 180.0 angle_m))))
   (*
    angle_s
    (if (<= (/ angle_m 180.0) 1e+98)
      (* (- b a) (* (+ b a) (sin t_0)))
      (if (<= (/ angle_m 180.0) 1e+135)
        (*
         (/
          (* 2.0 (sin (exp (- 0.0 (log (/ 180.0 (* angle_m PI)))))))
          (/ 1.0 (- (* b b) (* a a))))
         (cos (* (/ angle_m 180.0) PI)))
        (if (<= (/ angle_m 180.0) 1e+163)
          (* (+ b a) (* (- b a) t_0))
          (* (* (+ b a) (* 2.0 (sin t_1))) (* (- b a) (cos t_1)))))))))
angle\_m = fabs(angle);
angle\_s = copysign(1.0, angle);
double code(double angle_s, double a, double b, double angle_m) {
	double t_0 = (angle_m * ((double) M_PI)) * 0.011111111111111112;
	double t_1 = pow(sqrt(((double) M_PI)), 2.0) / (180.0 / angle_m);
	double tmp;
	if ((angle_m / 180.0) <= 1e+98) {
		tmp = (b - a) * ((b + a) * sin(t_0));
	} else if ((angle_m / 180.0) <= 1e+135) {
		tmp = ((2.0 * sin(exp((0.0 - log((180.0 / (angle_m * ((double) M_PI)))))))) / (1.0 / ((b * b) - (a * a)))) * cos(((angle_m / 180.0) * ((double) M_PI)));
	} else if ((angle_m / 180.0) <= 1e+163) {
		tmp = (b + a) * ((b - a) * t_0);
	} else {
		tmp = ((b + a) * (2.0 * sin(t_1))) * ((b - a) * cos(t_1));
	}
	return angle_s * tmp;
}
angle\_m = Math.abs(angle);
angle\_s = Math.copySign(1.0, angle);
public static double code(double angle_s, double a, double b, double angle_m) {
	double t_0 = (angle_m * Math.PI) * 0.011111111111111112;
	double t_1 = Math.pow(Math.sqrt(Math.PI), 2.0) / (180.0 / angle_m);
	double tmp;
	if ((angle_m / 180.0) <= 1e+98) {
		tmp = (b - a) * ((b + a) * Math.sin(t_0));
	} else if ((angle_m / 180.0) <= 1e+135) {
		tmp = ((2.0 * Math.sin(Math.exp((0.0 - Math.log((180.0 / (angle_m * Math.PI))))))) / (1.0 / ((b * b) - (a * a)))) * Math.cos(((angle_m / 180.0) * Math.PI));
	} else if ((angle_m / 180.0) <= 1e+163) {
		tmp = (b + a) * ((b - a) * t_0);
	} else {
		tmp = ((b + a) * (2.0 * Math.sin(t_1))) * ((b - a) * Math.cos(t_1));
	}
	return angle_s * tmp;
}
angle\_m = math.fabs(angle)
angle\_s = math.copysign(1.0, angle)
def code(angle_s, a, b, angle_m):
	t_0 = (angle_m * math.pi) * 0.011111111111111112
	t_1 = math.pow(math.sqrt(math.pi), 2.0) / (180.0 / angle_m)
	tmp = 0
	if (angle_m / 180.0) <= 1e+98:
		tmp = (b - a) * ((b + a) * math.sin(t_0))
	elif (angle_m / 180.0) <= 1e+135:
		tmp = ((2.0 * math.sin(math.exp((0.0 - math.log((180.0 / (angle_m * math.pi))))))) / (1.0 / ((b * b) - (a * a)))) * math.cos(((angle_m / 180.0) * math.pi))
	elif (angle_m / 180.0) <= 1e+163:
		tmp = (b + a) * ((b - a) * t_0)
	else:
		tmp = ((b + a) * (2.0 * math.sin(t_1))) * ((b - a) * math.cos(t_1))
	return angle_s * tmp
angle\_m = abs(angle)
angle\_s = copysign(1.0, angle)
function code(angle_s, a, b, angle_m)
	t_0 = Float64(Float64(angle_m * pi) * 0.011111111111111112)
	t_1 = Float64((sqrt(pi) ^ 2.0) / Float64(180.0 / angle_m))
	tmp = 0.0
	if (Float64(angle_m / 180.0) <= 1e+98)
		tmp = Float64(Float64(b - a) * Float64(Float64(b + a) * sin(t_0)));
	elseif (Float64(angle_m / 180.0) <= 1e+135)
		tmp = Float64(Float64(Float64(2.0 * sin(exp(Float64(0.0 - log(Float64(180.0 / Float64(angle_m * pi))))))) / Float64(1.0 / Float64(Float64(b * b) - Float64(a * a)))) * cos(Float64(Float64(angle_m / 180.0) * pi)));
	elseif (Float64(angle_m / 180.0) <= 1e+163)
		tmp = Float64(Float64(b + a) * Float64(Float64(b - a) * t_0));
	else
		tmp = Float64(Float64(Float64(b + a) * Float64(2.0 * sin(t_1))) * Float64(Float64(b - a) * cos(t_1)));
	end
	return Float64(angle_s * tmp)
end
angle\_m = abs(angle);
angle\_s = sign(angle) * abs(1.0);
function tmp_2 = code(angle_s, a, b, angle_m)
	t_0 = (angle_m * pi) * 0.011111111111111112;
	t_1 = (sqrt(pi) ^ 2.0) / (180.0 / angle_m);
	tmp = 0.0;
	if ((angle_m / 180.0) <= 1e+98)
		tmp = (b - a) * ((b + a) * sin(t_0));
	elseif ((angle_m / 180.0) <= 1e+135)
		tmp = ((2.0 * sin(exp((0.0 - log((180.0 / (angle_m * pi))))))) / (1.0 / ((b * b) - (a * a)))) * cos(((angle_m / 180.0) * pi));
	elseif ((angle_m / 180.0) <= 1e+163)
		tmp = (b + a) * ((b - a) * t_0);
	else
		tmp = ((b + a) * (2.0 * sin(t_1))) * ((b - a) * cos(t_1));
	end
	tmp_2 = angle_s * tmp;
end
angle\_m = N[Abs[angle], $MachinePrecision]
angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]}, Block[{t$95$1 = N[(N[Power[N[Sqrt[Pi], $MachinePrecision], 2.0], $MachinePrecision] / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 1e+98], N[(N[(b - a), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 1e+135], N[(N[(N[(2.0 * N[Sin[N[Exp[N[(0.0 - N[Log[N[(180.0 / N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / N[(1.0 / N[(N[(b * b), $MachinePrecision] - N[(a * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Cos[N[(N[(angle$95$m / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 1e+163], N[(N[(b + a), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * t$95$0), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b + a), $MachinePrecision] * N[(2.0 * N[Sin[t$95$1], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[Cos[t$95$1], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]), $MachinePrecision]]]
\begin{array}{l}
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

\\
\begin{array}{l}
t_0 := \left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\\
t_1 := \frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle\_m}}\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+98}:\\
\;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin t\_0\right)\\

\mathbf{elif}\;\frac{angle\_m}{180} \leq 10^{+135}:\\
\;\;\;\;\frac{2 \cdot \sin \left(e^{0 - \log \left(\frac{180}{angle\_m \cdot \pi}\right)}\right)}{\frac{1}{b \cdot b - a \cdot a}} \cdot \cos \left(\frac{angle\_m}{180} \cdot \pi\right)\\

\mathbf{elif}\;\frac{angle\_m}{180} \leq 10^{+163}:\\
\;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot t\_0\right)\\

\mathbf{else}:\\
\;\;\;\;\left(\left(b + a\right) \cdot \left(2 \cdot \sin t\_1\right)\right) \cdot \left(\left(b - a\right) \cdot \cos t\_1\right)\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (/.f64 angle #s(literal 180 binary64)) < 9.99999999999999998e97

    1. Initial program 58.9%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. Step-by-step derivation
      1. associate-*l*N/A

        \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
      2. *-commutativeN/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
      3. associate-*l*N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
      5. sin-lowering-sin.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      6. associate-*r/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      8. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      9. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      10. *-commutativeN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      11. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
    3. Simplified59.1%

      \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
      2. *-commutativeN/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right) \cdot \color{blue}{\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)}\right) \]
      3. associate-*r*N/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)} \]
      4. associate-*r/N/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \]
      5. associate-*r*N/A

        \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot 2\right) \cdot \color{blue}{\left(b \cdot b - a \cdot a\right)} \]
      6. *-commutativeN/A

        \[\leadsto \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - a \cdot a\right) \]
      7. *-commutativeN/A

        \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right)} \]
      8. difference-of-squaresN/A

        \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\color{blue}{2} \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
    6. Applied egg-rr75.3%

      \[\leadsto \color{blue}{\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)\right)} \]

    if 9.99999999999999998e97 < (/.f64 angle #s(literal 180 binary64)) < 9.99999999999999962e134

    1. Initial program 24.1%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \mathsf{*.f64}\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right), \mathsf{cos.f64}\left(\color{blue}{\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)}\right)\right) \]
      2. pow2N/A

        \[\leadsto \mathsf{*.f64}\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left(b \cdot b - {a}^{2}\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      3. pow2N/A

        \[\leadsto \mathsf{*.f64}\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      4. associate-*r*N/A

        \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b \cdot b - a \cdot a\right)\right), \mathsf{cos.f64}\left(\color{blue}{\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)}\right)\right) \]
      5. flip--N/A

        \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \frac{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}{b \cdot b + a \cdot a}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \color{blue}{\mathsf{/.f64}\left(angle, 180\right)}\right)\right)\right) \]
      6. clear-numN/A

        \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \frac{1}{\frac{b \cdot b + a \cdot a}{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \color{blue}{\mathsf{/.f64}\left(angle, 180\right)}\right)\right)\right) \]
      7. un-div-invN/A

        \[\leadsto \mathsf{*.f64}\left(\left(\frac{\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2}{\frac{b \cdot b + a \cdot a}{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}}\right), \mathsf{cos.f64}\left(\color{blue}{\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)}\right)\right) \]
      8. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right), \left(\frac{b \cdot b + a \cdot a}{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}\right)\right), \mathsf{cos.f64}\left(\color{blue}{\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)}\right)\right) \]
    4. Applied egg-rr31.9%

      \[\leadsto \color{blue}{\frac{2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)}{\frac{1}{b \cdot b - a \cdot a}}} \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    5. Step-by-step derivation
      1. associate-/r/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{180} \cdot angle\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      2. associate-*l/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      3. clear-numN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{1}{\frac{180}{\mathsf{PI}\left(\right) \cdot angle}}\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      4. inv-powN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left({\left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right)}^{-1}\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      5. pow-to-expN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(e^{\log \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right) \cdot -1}\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      6. exp-lowering-exp.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{exp.f64}\left(\left(\log \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right) \cdot -1\right)\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      7. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{exp.f64}\left(\mathsf{*.f64}\left(\log \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right), -1\right)\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      8. log-lowering-log.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{exp.f64}\left(\mathsf{*.f64}\left(\mathsf{log.f64}\left(\left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right)\right), -1\right)\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      9. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{exp.f64}\left(\mathsf{*.f64}\left(\mathsf{log.f64}\left(\mathsf{/.f64}\left(180, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), -1\right)\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      10. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{exp.f64}\left(\mathsf{*.f64}\left(\mathsf{log.f64}\left(\mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right), -1\right)\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
      11. PI-lowering-PI.f6434.3%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{exp.f64}\left(\mathsf{*.f64}\left(\mathsf{log.f64}\left(\mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right), -1\right)\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
    6. Applied egg-rr34.3%

      \[\leadsto \frac{2 \cdot \sin \color{blue}{\left(e^{\log \left(\frac{180}{\pi \cdot angle}\right) \cdot -1}\right)}}{\frac{1}{b \cdot b - a \cdot a}} \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]

    if 9.99999999999999962e134 < (/.f64 angle #s(literal 180 binary64)) < 9.9999999999999994e162

    1. Initial program 33.8%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. Step-by-step derivation
      1. associate-*l*N/A

        \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
      2. *-commutativeN/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
      3. associate-*l*N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
      5. sin-lowering-sin.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      6. associate-*r/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      8. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      9. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      10. *-commutativeN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      11. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
    3. Simplified17.1%

      \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in angle around 0

      \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
    6. Step-by-step derivation
      1. associate-*r*N/A

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
      2. associate-*r*N/A

        \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
      3. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
      5. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
      6. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
      7. --lowering--.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
      8. unpow2N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
      9. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
      10. unpow2N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
      11. *-lowering-*.f6468.3%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
    7. Simplified68.3%

      \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
    8. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
      2. difference-of-squaresN/A

        \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \]
      3. associate-*l*N/A

        \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)} \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\left(b + a\right), \color{blue}{\left(\left(b - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)}\right) \]
      5. +-lowering-+.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \left(\color{blue}{\left(b - a\right)} \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
      6. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\left(b - a\right), \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right)\right) \]
      7. --lowering--.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
      8. *-commutativeN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{angle}\right)\right)\right)\right) \]
      9. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \color{blue}{\left(\mathsf{PI}\left(\right) \cdot angle\right)}\right)\right)\right) \]
      10. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), \color{blue}{angle}\right)\right)\right)\right) \]
      11. PI-lowering-PI.f6468.3%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right)\right) \]
    9. Applied egg-rr68.3%

      \[\leadsto \color{blue}{\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right)} \]

    if 9.9999999999999994e162 < (/.f64 angle #s(literal 180 binary64))

    1. Initial program 29.4%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. Step-by-step derivation
      1. associate-*l*N/A

        \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
      2. *-commutativeN/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
      3. associate-*l*N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
      5. sin-lowering-sin.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      6. associate-*r/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      8. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      9. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      10. *-commutativeN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      11. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
    3. Simplified36.8%

      \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
      2. associate-*l*N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
      3. associate-*r*N/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
      4. difference-of-squaresN/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
      5. associate-*l*N/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
      6. associate-*r*N/A

        \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
      7. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
    6. Applied egg-rr32.7%

      \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
    7. Step-by-step derivation
      1. add-sqr-sqrtN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      2. pow2N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left({\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      3. pow-lowering-pow.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      4. sqrt-lowering-sqrt.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      5. PI-lowering-PI.f6434.6%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
    8. Applied egg-rr34.6%

      \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\color{blue}{{\left(\sqrt{\pi}\right)}^{2}}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
    9. Step-by-step derivation
      1. add-sqr-sqrtN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      2. unpow2N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\left({\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      3. pow-lowering-pow.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      4. sqrt-lowering-sqrt.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      5. PI-lowering-PI.f6449.5%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
    10. Applied egg-rr49.5%

      \[\leadsto \left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\color{blue}{{\left(\sqrt{\pi}\right)}^{2}}}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
  3. Recombined 4 regimes into one program.
  4. Final simplification71.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 10^{+98}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+135}:\\ \;\;\;\;\frac{2 \cdot \sin \left(e^{0 - \log \left(\frac{180}{angle \cdot \pi}\right)}\right)}{\frac{1}{b \cdot b - a \cdot a}} \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+163}:\\ \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right)\right) \cdot \left(\left(b - a\right) \cdot \cos \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 67.3% accurate, 0.6× speedup?

\[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \frac{angle\_m}{180} \cdot \pi\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\cos t\_0 \cdot \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin t\_0\right) \leq -\infty:\\ \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle\_m \cdot \sqrt[3]{\pi \cdot \left(\pi \cdot \pi\right)}}}\right)\right)\right) \cdot \left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)\\ \end{array} \end{array} \end{array} \]
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a b angle_m)
 :precision binary64
 (let* ((t_0 (* (/ angle_m 180.0) PI)))
   (*
    angle_s
    (if (<=
         (* (cos t_0) (* (* 2.0 (- (pow b 2.0) (pow a 2.0))) (sin t_0)))
         (- INFINITY))
      (* (+ b a) (* (- b a) (* (* angle_m PI) 0.011111111111111112)))
      (*
       (*
        (+ b a)
        (* 2.0 (sin (/ 1.0 (/ 180.0 (* angle_m (cbrt (* PI (* PI PI)))))))))
       (* (- b a) (cos (/ PI (/ 180.0 angle_m)))))))))
angle\_m = fabs(angle);
angle\_s = copysign(1.0, angle);
double code(double angle_s, double a, double b, double angle_m) {
	double t_0 = (angle_m / 180.0) * ((double) M_PI);
	double tmp;
	if ((cos(t_0) * ((2.0 * (pow(b, 2.0) - pow(a, 2.0))) * sin(t_0))) <= -((double) INFINITY)) {
		tmp = (b + a) * ((b - a) * ((angle_m * ((double) M_PI)) * 0.011111111111111112));
	} else {
		tmp = ((b + a) * (2.0 * sin((1.0 / (180.0 / (angle_m * cbrt((((double) M_PI) * (((double) M_PI) * ((double) M_PI)))))))))) * ((b - a) * cos((((double) M_PI) / (180.0 / angle_m))));
	}
	return angle_s * tmp;
}
angle\_m = Math.abs(angle);
angle\_s = Math.copySign(1.0, angle);
public static double code(double angle_s, double a, double b, double angle_m) {
	double t_0 = (angle_m / 180.0) * Math.PI;
	double tmp;
	if ((Math.cos(t_0) * ((2.0 * (Math.pow(b, 2.0) - Math.pow(a, 2.0))) * Math.sin(t_0))) <= -Double.POSITIVE_INFINITY) {
		tmp = (b + a) * ((b - a) * ((angle_m * Math.PI) * 0.011111111111111112));
	} else {
		tmp = ((b + a) * (2.0 * Math.sin((1.0 / (180.0 / (angle_m * Math.cbrt((Math.PI * (Math.PI * Math.PI))))))))) * ((b - a) * Math.cos((Math.PI / (180.0 / angle_m))));
	}
	return angle_s * tmp;
}
angle\_m = abs(angle)
angle\_s = copysign(1.0, angle)
function code(angle_s, a, b, angle_m)
	t_0 = Float64(Float64(angle_m / 180.0) * pi)
	tmp = 0.0
	if (Float64(cos(t_0) * Float64(Float64(2.0 * Float64((b ^ 2.0) - (a ^ 2.0))) * sin(t_0))) <= Float64(-Inf))
		tmp = Float64(Float64(b + a) * Float64(Float64(b - a) * Float64(Float64(angle_m * pi) * 0.011111111111111112)));
	else
		tmp = Float64(Float64(Float64(b + a) * Float64(2.0 * sin(Float64(1.0 / Float64(180.0 / Float64(angle_m * cbrt(Float64(pi * Float64(pi * pi))))))))) * Float64(Float64(b - a) * cos(Float64(pi / Float64(180.0 / angle_m)))));
	end
	return Float64(angle_s * tmp)
end
angle\_m = N[Abs[angle], $MachinePrecision]
angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(N[(angle$95$m / 180.0), $MachinePrecision] * Pi), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[N[(N[Cos[t$95$0], $MachinePrecision] * N[(N[(2.0 * N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], (-Infinity)], N[(N[(b + a), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b + a), $MachinePrecision] * N[(2.0 * N[Sin[N[(1.0 / N[(180.0 / N[(angle$95$m * N[Power[N[(Pi * N[(Pi * Pi), $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[Cos[N[(Pi / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
\begin{array}{l}
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

\\
\begin{array}{l}
t_0 := \frac{angle\_m}{180} \cdot \pi\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;\cos t\_0 \cdot \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin t\_0\right) \leq -\infty:\\
\;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle\_m \cdot \sqrt[3]{\pi \cdot \left(\pi \cdot \pi\right)}}}\right)\right)\right) \cdot \left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))) (sin.f64 (*.f64 (PI.f64) (/.f64 angle #s(literal 180 binary64))))) (cos.f64 (*.f64 (PI.f64) (/.f64 angle #s(literal 180 binary64))))) < -inf.0

    1. Initial program 53.8%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. Step-by-step derivation
      1. associate-*l*N/A

        \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
      2. *-commutativeN/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
      3. associate-*l*N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
      5. sin-lowering-sin.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      6. associate-*r/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      8. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      9. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      10. *-commutativeN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      11. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
    3. Simplified53.8%

      \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in angle around 0

      \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
    6. Step-by-step derivation
      1. associate-*r*N/A

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
      2. associate-*r*N/A

        \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
      3. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
      5. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
      6. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
      7. --lowering--.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
      8. unpow2N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
      9. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
      10. unpow2N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
      11. *-lowering-*.f6450.4%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
    7. Simplified50.4%

      \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
    8. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
      2. difference-of-squaresN/A

        \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \]
      3. associate-*l*N/A

        \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)} \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\left(b + a\right), \color{blue}{\left(\left(b - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)}\right) \]
      5. +-lowering-+.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \left(\color{blue}{\left(b - a\right)} \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
      6. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\left(b - a\right), \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right)\right) \]
      7. --lowering--.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
      8. *-commutativeN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{angle}\right)\right)\right)\right) \]
      9. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \color{blue}{\left(\mathsf{PI}\left(\right) \cdot angle\right)}\right)\right)\right) \]
      10. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), \color{blue}{angle}\right)\right)\right)\right) \]
      11. PI-lowering-PI.f6479.1%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right)\right) \]
    9. Applied egg-rr79.1%

      \[\leadsto \color{blue}{\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right)} \]

    if -inf.0 < (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))) (sin.f64 (*.f64 (PI.f64) (/.f64 angle #s(literal 180 binary64))))) (cos.f64 (*.f64 (PI.f64) (/.f64 angle #s(literal 180 binary64)))))

    1. Initial program 54.8%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. Step-by-step derivation
      1. associate-*l*N/A

        \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
      2. *-commutativeN/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
      3. associate-*l*N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
      5. sin-lowering-sin.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      6. associate-*r/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      8. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      9. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      10. *-commutativeN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      11. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
    3. Simplified54.9%

      \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
      2. associate-*l*N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
      3. associate-*r*N/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
      4. difference-of-squaresN/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
      5. associate-*l*N/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
      6. associate-*r*N/A

        \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
      7. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
    6. Applied egg-rr65.0%

      \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
    7. Step-by-step derivation
      1. associate-/r/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{180} \cdot angle\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      2. associate-*l/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      3. clear-numN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{1}{\frac{180}{\mathsf{PI}\left(\right) \cdot angle}}\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      4. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      5. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      6. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      7. PI-lowering-PI.f6466.3%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
    8. Applied egg-rr66.3%

      \[\leadsto \left(\left(2 \cdot \sin \color{blue}{\left(\frac{1}{\frac{180}{\pi \cdot angle}}\right)}\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
    9. Step-by-step derivation
      1. add-cbrt-cubeN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      2. cbrt-lowering-cbrt.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{cbrt.f64}\left(\left(\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)\right)\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      3. associate-*l*N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{cbrt.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)\right)\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{cbrt.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), \left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)\right)\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      5. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{cbrt.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)\right)\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      6. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{cbrt.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(\mathsf{PI}\left(\right), \mathsf{PI}\left(\right)\right)\right)\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      7. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{cbrt.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{PI}\left(\right)\right)\right)\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      8. PI-lowering-PI.f6467.9%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{cbrt.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{PI.f64}\left(\right)\right)\right)\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
    10. Applied egg-rr67.9%

      \[\leadsto \left(\left(2 \cdot \sin \left(\frac{1}{\frac{180}{\color{blue}{\sqrt[3]{\pi \cdot \left(\pi \cdot \pi\right)}} \cdot angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification70.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\cos \left(\frac{angle}{180} \cdot \pi\right) \cdot \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right) \leq -\infty:\\ \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle \cdot \sqrt[3]{\pi \cdot \left(\pi \cdot \pi\right)}}}\right)\right)\right) \cdot \left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{\frac{180}{angle}}\right)\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 67.5% accurate, 1.0× speedup?

\[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle\_m}}\right)\right)\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+98}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{elif}\;\frac{angle\_m}{180} \leq 2 \cdot 10^{+224}:\\ \;\;\;\;\left(b - a\right) \cdot t\_0\\ \mathbf{else}:\\ \;\;\;\;t\_0 \cdot \left(\left(b - a\right) \cdot \cos \left(\frac{1}{\frac{180}{angle\_m \cdot \pi}}\right)\right)\\ \end{array} \end{array} \end{array} \]
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a b angle_m)
 :precision binary64
 (let* ((t_0
         (* (+ b a) (* 2.0 (sin (/ (pow (sqrt PI) 2.0) (/ 180.0 angle_m)))))))
   (*
    angle_s
    (if (<= (/ angle_m 180.0) 1e+98)
      (* (- b a) (* (+ b a) (sin (* (* angle_m PI) 0.011111111111111112))))
      (if (<= (/ angle_m 180.0) 2e+224)
        (* (- b a) t_0)
        (* t_0 (* (- b a) (cos (/ 1.0 (/ 180.0 (* angle_m PI)))))))))))
angle\_m = fabs(angle);
angle\_s = copysign(1.0, angle);
double code(double angle_s, double a, double b, double angle_m) {
	double t_0 = (b + a) * (2.0 * sin((pow(sqrt(((double) M_PI)), 2.0) / (180.0 / angle_m))));
	double tmp;
	if ((angle_m / 180.0) <= 1e+98) {
		tmp = (b - a) * ((b + a) * sin(((angle_m * ((double) M_PI)) * 0.011111111111111112)));
	} else if ((angle_m / 180.0) <= 2e+224) {
		tmp = (b - a) * t_0;
	} else {
		tmp = t_0 * ((b - a) * cos((1.0 / (180.0 / (angle_m * ((double) M_PI))))));
	}
	return angle_s * tmp;
}
angle\_m = Math.abs(angle);
angle\_s = Math.copySign(1.0, angle);
public static double code(double angle_s, double a, double b, double angle_m) {
	double t_0 = (b + a) * (2.0 * Math.sin((Math.pow(Math.sqrt(Math.PI), 2.0) / (180.0 / angle_m))));
	double tmp;
	if ((angle_m / 180.0) <= 1e+98) {
		tmp = (b - a) * ((b + a) * Math.sin(((angle_m * Math.PI) * 0.011111111111111112)));
	} else if ((angle_m / 180.0) <= 2e+224) {
		tmp = (b - a) * t_0;
	} else {
		tmp = t_0 * ((b - a) * Math.cos((1.0 / (180.0 / (angle_m * Math.PI)))));
	}
	return angle_s * tmp;
}
angle\_m = math.fabs(angle)
angle\_s = math.copysign(1.0, angle)
def code(angle_s, a, b, angle_m):
	t_0 = (b + a) * (2.0 * math.sin((math.pow(math.sqrt(math.pi), 2.0) / (180.0 / angle_m))))
	tmp = 0
	if (angle_m / 180.0) <= 1e+98:
		tmp = (b - a) * ((b + a) * math.sin(((angle_m * math.pi) * 0.011111111111111112)))
	elif (angle_m / 180.0) <= 2e+224:
		tmp = (b - a) * t_0
	else:
		tmp = t_0 * ((b - a) * math.cos((1.0 / (180.0 / (angle_m * math.pi)))))
	return angle_s * tmp
angle\_m = abs(angle)
angle\_s = copysign(1.0, angle)
function code(angle_s, a, b, angle_m)
	t_0 = Float64(Float64(b + a) * Float64(2.0 * sin(Float64((sqrt(pi) ^ 2.0) / Float64(180.0 / angle_m)))))
	tmp = 0.0
	if (Float64(angle_m / 180.0) <= 1e+98)
		tmp = Float64(Float64(b - a) * Float64(Float64(b + a) * sin(Float64(Float64(angle_m * pi) * 0.011111111111111112))));
	elseif (Float64(angle_m / 180.0) <= 2e+224)
		tmp = Float64(Float64(b - a) * t_0);
	else
		tmp = Float64(t_0 * Float64(Float64(b - a) * cos(Float64(1.0 / Float64(180.0 / Float64(angle_m * pi))))));
	end
	return Float64(angle_s * tmp)
end
angle\_m = abs(angle);
angle\_s = sign(angle) * abs(1.0);
function tmp_2 = code(angle_s, a, b, angle_m)
	t_0 = (b + a) * (2.0 * sin(((sqrt(pi) ^ 2.0) / (180.0 / angle_m))));
	tmp = 0.0;
	if ((angle_m / 180.0) <= 1e+98)
		tmp = (b - a) * ((b + a) * sin(((angle_m * pi) * 0.011111111111111112)));
	elseif ((angle_m / 180.0) <= 2e+224)
		tmp = (b - a) * t_0;
	else
		tmp = t_0 * ((b - a) * cos((1.0 / (180.0 / (angle_m * pi)))));
	end
	tmp_2 = angle_s * tmp;
end
angle\_m = N[Abs[angle], $MachinePrecision]
angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(N[(b + a), $MachinePrecision] * N[(2.0 * N[Sin[N[(N[Power[N[Sqrt[Pi], $MachinePrecision], 2.0], $MachinePrecision] / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 1e+98], N[(N[(b - a), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[Sin[N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 2e+224], N[(N[(b - a), $MachinePrecision] * t$95$0), $MachinePrecision], N[(t$95$0 * N[(N[(b - a), $MachinePrecision] * N[Cos[N[(1.0 / N[(180.0 / N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
\begin{array}{l}
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

\\
\begin{array}{l}
t_0 := \left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle\_m}}\right)\right)\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+98}:\\
\;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\

\mathbf{elif}\;\frac{angle\_m}{180} \leq 2 \cdot 10^{+224}:\\
\;\;\;\;\left(b - a\right) \cdot t\_0\\

\mathbf{else}:\\
\;\;\;\;t\_0 \cdot \left(\left(b - a\right) \cdot \cos \left(\frac{1}{\frac{180}{angle\_m \cdot \pi}}\right)\right)\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 angle #s(literal 180 binary64)) < 9.99999999999999998e97

    1. Initial program 58.9%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. Step-by-step derivation
      1. associate-*l*N/A

        \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
      2. *-commutativeN/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
      3. associate-*l*N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
      5. sin-lowering-sin.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      6. associate-*r/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      8. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      9. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      10. *-commutativeN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      11. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
    3. Simplified59.1%

      \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
      2. *-commutativeN/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right) \cdot \color{blue}{\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)}\right) \]
      3. associate-*r*N/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)} \]
      4. associate-*r/N/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \]
      5. associate-*r*N/A

        \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot 2\right) \cdot \color{blue}{\left(b \cdot b - a \cdot a\right)} \]
      6. *-commutativeN/A

        \[\leadsto \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - a \cdot a\right) \]
      7. *-commutativeN/A

        \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right)} \]
      8. difference-of-squaresN/A

        \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\color{blue}{2} \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
    6. Applied egg-rr75.3%

      \[\leadsto \color{blue}{\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)\right)} \]

    if 9.99999999999999998e97 < (/.f64 angle #s(literal 180 binary64)) < 1.99999999999999994e224

    1. Initial program 25.9%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. Step-by-step derivation
      1. associate-*l*N/A

        \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
      2. *-commutativeN/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
      3. associate-*l*N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
      5. sin-lowering-sin.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      6. associate-*r/N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      8. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      9. PI-lowering-PI.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
      10. *-commutativeN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      11. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
    3. Simplified16.4%

      \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
      2. associate-*l*N/A

        \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
      3. associate-*r*N/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
      4. difference-of-squaresN/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
      5. associate-*l*N/A

        \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
      6. associate-*r*N/A

        \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
      7. *-lowering-*.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
    6. Applied egg-rr25.5%

      \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
    7. Step-by-step derivation
      1. add-sqr-sqrtN/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      2. pow2N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left({\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      3. pow-lowering-pow.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      4. sqrt-lowering-sqrt.f64N/A

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      5. PI-lowering-PI.f6421.9%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
    8. Applied egg-rr21.9%

      \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\color{blue}{{\left(\sqrt{\pi}\right)}^{2}}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
    9. Taylor expanded in angle around 0

      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
    10. Step-by-step derivation
      1. Simplified34.7%

        \[\leadsto \left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\color{blue}{1} \cdot \left(b - a\right)\right) \]

      if 1.99999999999999994e224 < (/.f64 angle #s(literal 180 binary64))

      1. Initial program 34.4%

        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
      2. Step-by-step derivation
        1. associate-*l*N/A

          \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
        2. *-commutativeN/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
        3. associate-*l*N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
        5. sin-lowering-sin.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        6. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        7. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        9. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        10. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        11. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      3. Simplified48.4%

        \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
      4. Add Preprocessing
      5. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
        2. associate-*l*N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        3. associate-*r*N/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
        4. difference-of-squaresN/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
        5. associate-*l*N/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        6. associate-*r*N/A

          \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
        7. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
      6. Applied egg-rr40.0%

        \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
      7. Step-by-step derivation
        1. add-sqr-sqrtN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        2. pow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left({\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        3. pow-lowering-pow.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        4. sqrt-lowering-sqrt.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        5. PI-lowering-PI.f6447.8%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      8. Applied egg-rr47.8%

        \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\color{blue}{{\left(\sqrt{\pi}\right)}^{2}}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
      9. Step-by-step derivation
        1. associate-/r/N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{180} \cdot angle\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        2. associate-*l/N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        3. clear-numN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{1}{\frac{180}{\mathsf{PI}\left(\right) \cdot angle}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        4. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(1, \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        6. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        7. PI-lowering-PI.f6448.2%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      10. Applied egg-rr48.2%

        \[\leadsto \left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \color{blue}{\left(\frac{1}{\frac{180}{\pi \cdot angle}}\right)} \cdot \left(b - a\right)\right) \]
    11. Recombined 3 regimes into one program.
    12. Final simplification70.2%

      \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 10^{+98}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{elif}\;\frac{angle}{180} \leq 2 \cdot 10^{+224}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right)\right) \cdot \left(\left(b - a\right) \cdot \cos \left(\frac{1}{\frac{180}{angle \cdot \pi}}\right)\right)\\ \end{array} \]
    13. Add Preprocessing

    Alternative 4: 67.4% accurate, 1.3× speedup?

    \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+98}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle\_m}}\right)\right)\right)\\ \end{array} \end{array} \]
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a b angle_m)
     :precision binary64
     (*
      angle_s
      (if (<= (/ angle_m 180.0) 1e+98)
        (* (- b a) (* (+ b a) (sin (* (* angle_m PI) 0.011111111111111112))))
        (*
         (- b a)
         (* (+ b a) (* 2.0 (sin (/ (pow (sqrt PI) 2.0) (/ 180.0 angle_m)))))))))
    angle\_m = fabs(angle);
    angle\_s = copysign(1.0, angle);
    double code(double angle_s, double a, double b, double angle_m) {
    	double tmp;
    	if ((angle_m / 180.0) <= 1e+98) {
    		tmp = (b - a) * ((b + a) * sin(((angle_m * ((double) M_PI)) * 0.011111111111111112)));
    	} else {
    		tmp = (b - a) * ((b + a) * (2.0 * sin((pow(sqrt(((double) M_PI)), 2.0) / (180.0 / angle_m)))));
    	}
    	return angle_s * tmp;
    }
    
    angle\_m = Math.abs(angle);
    angle\_s = Math.copySign(1.0, angle);
    public static double code(double angle_s, double a, double b, double angle_m) {
    	double tmp;
    	if ((angle_m / 180.0) <= 1e+98) {
    		tmp = (b - a) * ((b + a) * Math.sin(((angle_m * Math.PI) * 0.011111111111111112)));
    	} else {
    		tmp = (b - a) * ((b + a) * (2.0 * Math.sin((Math.pow(Math.sqrt(Math.PI), 2.0) / (180.0 / angle_m)))));
    	}
    	return angle_s * tmp;
    }
    
    angle\_m = math.fabs(angle)
    angle\_s = math.copysign(1.0, angle)
    def code(angle_s, a, b, angle_m):
    	tmp = 0
    	if (angle_m / 180.0) <= 1e+98:
    		tmp = (b - a) * ((b + a) * math.sin(((angle_m * math.pi) * 0.011111111111111112)))
    	else:
    		tmp = (b - a) * ((b + a) * (2.0 * math.sin((math.pow(math.sqrt(math.pi), 2.0) / (180.0 / angle_m)))))
    	return angle_s * tmp
    
    angle\_m = abs(angle)
    angle\_s = copysign(1.0, angle)
    function code(angle_s, a, b, angle_m)
    	tmp = 0.0
    	if (Float64(angle_m / 180.0) <= 1e+98)
    		tmp = Float64(Float64(b - a) * Float64(Float64(b + a) * sin(Float64(Float64(angle_m * pi) * 0.011111111111111112))));
    	else
    		tmp = Float64(Float64(b - a) * Float64(Float64(b + a) * Float64(2.0 * sin(Float64((sqrt(pi) ^ 2.0) / Float64(180.0 / angle_m))))));
    	end
    	return Float64(angle_s * tmp)
    end
    
    angle\_m = abs(angle);
    angle\_s = sign(angle) * abs(1.0);
    function tmp_2 = code(angle_s, a, b, angle_m)
    	tmp = 0.0;
    	if ((angle_m / 180.0) <= 1e+98)
    		tmp = (b - a) * ((b + a) * sin(((angle_m * pi) * 0.011111111111111112)));
    	else
    		tmp = (b - a) * ((b + a) * (2.0 * sin(((sqrt(pi) ^ 2.0) / (180.0 / angle_m)))));
    	end
    	tmp_2 = angle_s * tmp;
    end
    
    angle\_m = N[Abs[angle], $MachinePrecision]
    angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
    code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 1e+98], N[(N[(b - a), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[Sin[N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b - a), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[(2.0 * N[Sin[N[(N[Power[N[Sqrt[Pi], $MachinePrecision], 2.0], $MachinePrecision] / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
    
    \begin{array}{l}
    angle\_m = \left|angle\right|
    \\
    angle\_s = \mathsf{copysign}\left(1, angle\right)
    
    \\
    angle\_s \cdot \begin{array}{l}
    \mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+98}:\\
    \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\
    
    \mathbf{else}:\\
    \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle\_m}}\right)\right)\right)\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if (/.f64 angle #s(literal 180 binary64)) < 9.99999999999999998e97

      1. Initial program 58.9%

        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
      2. Step-by-step derivation
        1. associate-*l*N/A

          \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
        2. *-commutativeN/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
        3. associate-*l*N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
        5. sin-lowering-sin.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        6. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        7. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        9. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        10. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        11. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      3. Simplified59.1%

        \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
      4. Add Preprocessing
      5. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
        2. *-commutativeN/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right) \cdot \color{blue}{\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)}\right) \]
        3. associate-*r*N/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)} \]
        4. associate-*r/N/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \]
        5. associate-*r*N/A

          \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot 2\right) \cdot \color{blue}{\left(b \cdot b - a \cdot a\right)} \]
        6. *-commutativeN/A

          \[\leadsto \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - a \cdot a\right) \]
        7. *-commutativeN/A

          \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right)} \]
        8. difference-of-squaresN/A

          \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\color{blue}{2} \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
      6. Applied egg-rr75.3%

        \[\leadsto \color{blue}{\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)\right)} \]

      if 9.99999999999999998e97 < (/.f64 angle #s(literal 180 binary64))

      1. Initial program 29.1%

        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
      2. Step-by-step derivation
        1. associate-*l*N/A

          \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
        2. *-commutativeN/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
        3. associate-*l*N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
        5. sin-lowering-sin.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        6. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        7. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        9. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        10. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        11. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      3. Simplified28.5%

        \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
      4. Add Preprocessing
      5. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
        2. associate-*l*N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        3. associate-*r*N/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
        4. difference-of-squaresN/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
        5. associate-*l*N/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        6. associate-*r*N/A

          \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
        7. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
      6. Applied egg-rr31.0%

        \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
      7. Step-by-step derivation
        1. add-sqr-sqrtN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        2. pow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left({\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        3. pow-lowering-pow.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        4. sqrt-lowering-sqrt.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        5. PI-lowering-PI.f6431.7%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      8. Applied egg-rr31.7%

        \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\color{blue}{{\left(\sqrt{\pi}\right)}^{2}}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
      9. Taylor expanded in angle around 0

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      10. Step-by-step derivation
        1. Simplified40.1%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\color{blue}{1} \cdot \left(b - a\right)\right) \]
      11. Recombined 2 regimes into one program.
      12. Final simplification70.2%

        \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 10^{+98}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right)\right)\\ \end{array} \]
      13. Add Preprocessing

      Alternative 5: 67.6% accurate, 1.8× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \frac{\pi}{\frac{180}{angle\_m}}\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;a \leq 4 \cdot 10^{+186}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \cos t\_0\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle\_m \cdot \pi}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b + a\right) \cdot \left(2 \cdot \sin t\_0\right)\right) \cdot \left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{-1} \cdot \frac{0.005555555555555556}{\frac{-1}{angle\_m}}\right)\right)\\ \end{array} \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (let* ((t_0 (/ PI (/ 180.0 angle_m))))
         (*
          angle_s
          (if (<= a 4e+186)
            (*
             (* (- b a) (cos t_0))
             (* (+ b a) (* 2.0 (sin (/ 1.0 (/ 180.0 (* angle_m PI)))))))
            (*
             (* (+ b a) (* 2.0 (sin t_0)))
             (*
              (- b a)
              (cos (* (/ PI -1.0) (/ 0.005555555555555556 (/ -1.0 angle_m))))))))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = ((double) M_PI) / (180.0 / angle_m);
      	double tmp;
      	if (a <= 4e+186) {
      		tmp = ((b - a) * cos(t_0)) * ((b + a) * (2.0 * sin((1.0 / (180.0 / (angle_m * ((double) M_PI)))))));
      	} else {
      		tmp = ((b + a) * (2.0 * sin(t_0))) * ((b - a) * cos(((((double) M_PI) / -1.0) * (0.005555555555555556 / (-1.0 / angle_m)))));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = Math.PI / (180.0 / angle_m);
      	double tmp;
      	if (a <= 4e+186) {
      		tmp = ((b - a) * Math.cos(t_0)) * ((b + a) * (2.0 * Math.sin((1.0 / (180.0 / (angle_m * Math.PI))))));
      	} else {
      		tmp = ((b + a) * (2.0 * Math.sin(t_0))) * ((b - a) * Math.cos(((Math.PI / -1.0) * (0.005555555555555556 / (-1.0 / angle_m)))));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	t_0 = math.pi / (180.0 / angle_m)
      	tmp = 0
      	if a <= 4e+186:
      		tmp = ((b - a) * math.cos(t_0)) * ((b + a) * (2.0 * math.sin((1.0 / (180.0 / (angle_m * math.pi))))))
      	else:
      		tmp = ((b + a) * (2.0 * math.sin(t_0))) * ((b - a) * math.cos(((math.pi / -1.0) * (0.005555555555555556 / (-1.0 / angle_m)))))
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	t_0 = Float64(pi / Float64(180.0 / angle_m))
      	tmp = 0.0
      	if (a <= 4e+186)
      		tmp = Float64(Float64(Float64(b - a) * cos(t_0)) * Float64(Float64(b + a) * Float64(2.0 * sin(Float64(1.0 / Float64(180.0 / Float64(angle_m * pi)))))));
      	else
      		tmp = Float64(Float64(Float64(b + a) * Float64(2.0 * sin(t_0))) * Float64(Float64(b - a) * cos(Float64(Float64(pi / -1.0) * Float64(0.005555555555555556 / Float64(-1.0 / angle_m))))));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	t_0 = pi / (180.0 / angle_m);
      	tmp = 0.0;
      	if (a <= 4e+186)
      		tmp = ((b - a) * cos(t_0)) * ((b + a) * (2.0 * sin((1.0 / (180.0 / (angle_m * pi))))));
      	else
      		tmp = ((b + a) * (2.0 * sin(t_0))) * ((b - a) * cos(((pi / -1.0) * (0.005555555555555556 / (-1.0 / angle_m)))));
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(Pi / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[a, 4e+186], N[(N[(N[(b - a), $MachinePrecision] * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[(2.0 * N[Sin[N[(1.0 / N[(180.0 / N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b + a), $MachinePrecision] * N[(2.0 * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[Cos[N[(N[(Pi / -1.0), $MachinePrecision] * N[(0.005555555555555556 / N[(-1.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      \begin{array}{l}
      t_0 := \frac{\pi}{\frac{180}{angle\_m}}\\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;a \leq 4 \cdot 10^{+186}:\\
      \;\;\;\;\left(\left(b - a\right) \cdot \cos t\_0\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle\_m \cdot \pi}}\right)\right)\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;\left(\left(b + a\right) \cdot \left(2 \cdot \sin t\_0\right)\right) \cdot \left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{-1} \cdot \frac{0.005555555555555556}{\frac{-1}{angle\_m}}\right)\right)\\
      
      
      \end{array}
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < 3.99999999999999992e186

        1. Initial program 55.6%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified55.7%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
          2. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          3. associate-*r*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          4. difference-of-squaresN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
          5. associate-*l*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          6. associate-*r*N/A

            \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        6. Applied egg-rr67.5%

          \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
        7. Step-by-step derivation
          1. associate-/r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{180} \cdot angle\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. associate-*l/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. clear-numN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{1}{\frac{180}{\mathsf{PI}\left(\right) \cdot angle}}\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          7. PI-lowering-PI.f6469.4%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. Applied egg-rr69.4%

          \[\leadsto \left(\left(2 \cdot \sin \color{blue}{\left(\frac{1}{\frac{180}{\pi \cdot angle}}\right)}\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]

        if 3.99999999999999992e186 < a

        1. Initial program 41.6%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified41.6%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
          2. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          3. associate-*r*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          4. difference-of-squaresN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
          5. associate-*l*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          6. associate-*r*N/A

            \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        6. Applied egg-rr83.2%

          \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
        7. Step-by-step derivation
          1. clear-numN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{\frac{1}{\frac{angle}{180}}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. add-sqr-sqrtN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\frac{angle}{180}}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. frac-2negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\frac{\mathsf{neg}\left(angle\right)}{\mathsf{neg}\left(180\right)}}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. associate-/r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\mathsf{neg}\left(angle\right)} \cdot \left(\mathsf{neg}\left(180\right)\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. times-fracN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\mathsf{neg}\left(angle\right)}} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\mathsf{neg}\left(angle\right)}}\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{1}{\mathsf{neg}\left(angle\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          8. sqrt-lowering-sqrt.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\frac{1}{\mathsf{neg}\left(angle\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{1}{\mathsf{neg}\left(angle\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          10. frac-2negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{\mathsf{neg}\left(1\right)}{\mathsf{neg}\left(\left(\mathsf{neg}\left(angle\right)\right)\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          11. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{-1}{\mathsf{neg}\left(\left(\mathsf{neg}\left(angle\right)\right)\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          12. remove-double-negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{-1}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          13. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          14. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\mathsf{neg}\left(180\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          15. sqrt-lowering-sqrt.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\mathsf{neg}\left(180\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          16. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\mathsf{neg}\left(180\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          17. metadata-eval83.2%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), -180\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. Applied egg-rr83.2%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \color{blue}{\left(\frac{\sqrt{\pi}}{\frac{-1}{angle}} \cdot \frac{\sqrt{\pi}}{-180}\right)} \cdot \left(b - a\right)\right) \]
        9. Step-by-step derivation
          1. frac-2negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{neg}\left(\sqrt{\mathsf{PI}\left(\right)}\right)}{\mathsf{neg}\left(\frac{-1}{angle}\right)} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{-180}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. frac-2negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{neg}\left(\sqrt{\mathsf{PI}\left(\right)}\right)}{\mathsf{neg}\left(\frac{-1}{angle}\right)} \cdot \frac{\mathsf{neg}\left(\sqrt{\mathsf{PI}\left(\right)}\right)}{\mathsf{neg}\left(-180\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{neg}\left(\sqrt{\mathsf{PI}\left(\right)}\right)}{\mathsf{neg}\left(\frac{-1}{angle}\right)} \cdot \frac{\mathsf{neg}\left(\sqrt{\mathsf{PI}\left(\right)}\right)}{180}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. frac-timesN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\left(\mathsf{neg}\left(\sqrt{\mathsf{PI}\left(\right)}\right)\right) \cdot \left(\mathsf{neg}\left(\sqrt{\mathsf{PI}\left(\right)}\right)\right)}{\left(\mathsf{neg}\left(\frac{-1}{angle}\right)\right) \cdot 180}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. sqr-negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\left(\mathsf{neg}\left(\frac{-1}{angle}\right)\right) \cdot 180}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          6. add-sqr-sqrtN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{\left(\mathsf{neg}\left(\frac{-1}{angle}\right)\right) \cdot 180}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          7. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{180 \cdot \left(\mathsf{neg}\left(\frac{-1}{angle}\right)\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          8. associate-/r*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\frac{\mathsf{PI}\left(\right)}{180}}{\mathsf{neg}\left(\frac{-1}{angle}\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          9. div-invN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot \frac{1}{180}}{\mathsf{neg}\left(\frac{-1}{angle}\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          10. neg-mul-1N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot \frac{1}{180}}{-1 \cdot \frac{-1}{angle}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          11. times-fracN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{-1} \cdot \frac{\frac{1}{180}}{\frac{-1}{angle}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          12. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{-1}\right), \left(\frac{\frac{1}{180}}{\frac{-1}{angle}}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          13. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{PI}\left(\right), -1\right), \left(\frac{\frac{1}{180}}{\frac{-1}{angle}}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          14. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), -1\right), \left(\frac{\frac{1}{180}}{\frac{-1}{angle}}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          15. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), -1\right), \mathsf{/.f64}\left(\left(\frac{1}{180}\right), \left(\frac{-1}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          16. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), -1\right), \mathsf{/.f64}\left(\frac{1}{180}, \left(\frac{-1}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          17. /-lowering-/.f6483.2%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), -1\right), \mathsf{/.f64}\left(\frac{1}{180}, \mathsf{/.f64}\left(-1, angle\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        10. Applied egg-rr83.2%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \color{blue}{\left(\frac{\pi}{-1} \cdot \frac{0.005555555555555556}{\frac{-1}{angle}}\right)} \cdot \left(b - a\right)\right) \]
      3. Recombined 2 regimes into one program.
      4. Final simplification70.3%

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 4 \cdot 10^{+186}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle \cdot \pi}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right)\right) \cdot \left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{-1} \cdot \frac{0.005555555555555556}{\frac{-1}{angle}}\right)\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 6: 67.6% accurate, 1.8× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \frac{\pi}{\frac{180}{angle\_m}}\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;a \leq 2.5 \cdot 10^{+192}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \cos t\_0\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle\_m \cdot \pi}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\cos \left(\frac{angle\_m}{180} \cdot \pi\right) \cdot \left(\left(\left(b + a\right) \cdot 2\right) \cdot \frac{\sin t\_0}{\frac{1}{b - a}}\right)\\ \end{array} \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (let* ((t_0 (/ PI (/ 180.0 angle_m))))
         (*
          angle_s
          (if (<= a 2.5e+192)
            (*
             (* (- b a) (cos t_0))
             (* (+ b a) (* 2.0 (sin (/ 1.0 (/ 180.0 (* angle_m PI)))))))
            (*
             (cos (* (/ angle_m 180.0) PI))
             (* (* (+ b a) 2.0) (/ (sin t_0) (/ 1.0 (- b a)))))))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = ((double) M_PI) / (180.0 / angle_m);
      	double tmp;
      	if (a <= 2.5e+192) {
      		tmp = ((b - a) * cos(t_0)) * ((b + a) * (2.0 * sin((1.0 / (180.0 / (angle_m * ((double) M_PI)))))));
      	} else {
      		tmp = cos(((angle_m / 180.0) * ((double) M_PI))) * (((b + a) * 2.0) * (sin(t_0) / (1.0 / (b - a))));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = Math.PI / (180.0 / angle_m);
      	double tmp;
      	if (a <= 2.5e+192) {
      		tmp = ((b - a) * Math.cos(t_0)) * ((b + a) * (2.0 * Math.sin((1.0 / (180.0 / (angle_m * Math.PI))))));
      	} else {
      		tmp = Math.cos(((angle_m / 180.0) * Math.PI)) * (((b + a) * 2.0) * (Math.sin(t_0) / (1.0 / (b - a))));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	t_0 = math.pi / (180.0 / angle_m)
      	tmp = 0
      	if a <= 2.5e+192:
      		tmp = ((b - a) * math.cos(t_0)) * ((b + a) * (2.0 * math.sin((1.0 / (180.0 / (angle_m * math.pi))))))
      	else:
      		tmp = math.cos(((angle_m / 180.0) * math.pi)) * (((b + a) * 2.0) * (math.sin(t_0) / (1.0 / (b - a))))
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	t_0 = Float64(pi / Float64(180.0 / angle_m))
      	tmp = 0.0
      	if (a <= 2.5e+192)
      		tmp = Float64(Float64(Float64(b - a) * cos(t_0)) * Float64(Float64(b + a) * Float64(2.0 * sin(Float64(1.0 / Float64(180.0 / Float64(angle_m * pi)))))));
      	else
      		tmp = Float64(cos(Float64(Float64(angle_m / 180.0) * pi)) * Float64(Float64(Float64(b + a) * 2.0) * Float64(sin(t_0) / Float64(1.0 / Float64(b - a)))));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	t_0 = pi / (180.0 / angle_m);
      	tmp = 0.0;
      	if (a <= 2.5e+192)
      		tmp = ((b - a) * cos(t_0)) * ((b + a) * (2.0 * sin((1.0 / (180.0 / (angle_m * pi))))));
      	else
      		tmp = cos(((angle_m / 180.0) * pi)) * (((b + a) * 2.0) * (sin(t_0) / (1.0 / (b - a))));
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(Pi / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[a, 2.5e+192], N[(N[(N[(b - a), $MachinePrecision] * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[(2.0 * N[Sin[N[(1.0 / N[(180.0 / N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Cos[N[(N[(angle$95$m / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision] * N[(N[(N[(b + a), $MachinePrecision] * 2.0), $MachinePrecision] * N[(N[Sin[t$95$0], $MachinePrecision] / N[(1.0 / N[(b - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      \begin{array}{l}
      t_0 := \frac{\pi}{\frac{180}{angle\_m}}\\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;a \leq 2.5 \cdot 10^{+192}:\\
      \;\;\;\;\left(\left(b - a\right) \cdot \cos t\_0\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle\_m \cdot \pi}}\right)\right)\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;\cos \left(\frac{angle\_m}{180} \cdot \pi\right) \cdot \left(\left(\left(b + a\right) \cdot 2\right) \cdot \frac{\sin t\_0}{\frac{1}{b - a}}\right)\\
      
      
      \end{array}
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < 2.50000000000000017e192

        1. Initial program 55.4%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified55.4%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
          2. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          3. associate-*r*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          4. difference-of-squaresN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
          5. associate-*l*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          6. associate-*r*N/A

            \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        6. Applied egg-rr67.9%

          \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
        7. Step-by-step derivation
          1. associate-/r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{180} \cdot angle\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. associate-*l/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. clear-numN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{1}{\frac{180}{\mathsf{PI}\left(\right) \cdot angle}}\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          7. PI-lowering-PI.f6469.7%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. Applied egg-rr69.7%

          \[\leadsto \left(\left(2 \cdot \sin \color{blue}{\left(\frac{1}{\frac{180}{\pi \cdot angle}}\right)}\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]

        if 2.50000000000000017e192 < a

        1. Initial program 42.7%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Add Preprocessing
        3. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right), \mathsf{cos.f64}\left(\color{blue}{\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)}\right)\right) \]
          2. pow2N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left(b \cdot b - {a}^{2}\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
          3. pow2N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
          4. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b \cdot b - a \cdot a\right)\right), \mathsf{cos.f64}\left(\color{blue}{\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)}\right)\right) \]
          5. flip--N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \frac{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}{b \cdot b + a \cdot a}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \color{blue}{\mathsf{/.f64}\left(angle, 180\right)}\right)\right)\right) \]
          6. clear-numN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \frac{1}{\frac{b \cdot b + a \cdot a}{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \color{blue}{\mathsf{/.f64}\left(angle, 180\right)}\right)\right)\right) \]
          7. un-div-invN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2}{\frac{b \cdot b + a \cdot a}{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}}\right), \mathsf{cos.f64}\left(\color{blue}{\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)}\right)\right) \]
          8. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right), \left(\frac{b \cdot b + a \cdot a}{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}\right)\right), \mathsf{cos.f64}\left(\color{blue}{\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)}\right)\right) \]
        4. Applied egg-rr42.7%

          \[\leadsto \color{blue}{\frac{2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)}{\frac{1}{b \cdot b - a \cdot a}}} \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        5. Step-by-step derivation
          1. difference-of-squaresN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{\left(b + a\right) \cdot \left(b - a\right)}}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, \color{blue}{180}\right)\right)\right)\right) \]
          2. associate-/r*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{\frac{1}{b + a}}{b - a}}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \color{blue}{\mathsf{/.f64}\left(angle, 180\right)}\right)\right)\right) \]
          3. div-invN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{b + a} \cdot \frac{1}{b - a}}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \color{blue}{\mathsf{/.f64}\left(angle, 180\right)}\right)\right)\right) \]
          4. times-fracN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{2}{\frac{1}{b + a}} \cdot \frac{\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right), \mathsf{cos.f64}\left(\color{blue}{\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)}\right)\right) \]
          5. un-div-invN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(2 \cdot \frac{1}{\frac{1}{b + a}}\right) \cdot \frac{\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\color{blue}{\mathsf{PI.f64}\left(\right)}, \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
          6. flip-+N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(2 \cdot \frac{1}{\frac{1}{\frac{b \cdot b - a \cdot a}{b - a}}}\right) \cdot \frac{\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
          7. clear-numN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(2 \cdot \frac{1}{\frac{b - a}{b \cdot b - a \cdot a}}\right) \cdot \frac{\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
          8. clear-numN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(2 \cdot \frac{b \cdot b - a \cdot a}{b - a}\right) \cdot \frac{\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
          9. flip-+N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(2 \cdot \left(b + a\right)\right) \cdot \frac{\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
          10. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(2 \cdot \left(b + a\right)\right), \left(\frac{\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right)\right), \mathsf{cos.f64}\left(\color{blue}{\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \left(b + a\right)\right), \left(\frac{\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\color{blue}{\mathsf{PI.f64}\left(\right)}, \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
          12. +-lowering-+.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{+.f64}\left(b, a\right)\right), \left(\frac{\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(angle, 180\right)\right)\right)\right) \]
          13. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{+.f64}\left(b, a\right)\right), \mathsf{/.f64}\left(\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right), \left(\frac{1}{b - a}\right)\right)\right), \mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \color{blue}{\mathsf{/.f64}\left(angle, 180\right)}\right)\right)\right) \]
        6. Applied egg-rr79.7%

          \[\leadsto \color{blue}{\left(\left(2 \cdot \left(b + a\right)\right) \cdot \frac{\sin \left(\frac{\pi}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right)} \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
      3. Recombined 2 regimes into one program.
      4. Final simplification70.3%

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 2.5 \cdot 10^{+192}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle \cdot \pi}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\cos \left(\frac{angle}{180} \cdot \pi\right) \cdot \left(\left(\left(b + a\right) \cdot 2\right) \cdot \frac{\sin \left(\frac{\pi}{\frac{180}{angle}}\right)}{\frac{1}{b - a}}\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 7: 67.7% accurate, 1.8× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \frac{angle\_m}{\frac{180}{\pi}}\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;a \leq 4.1 \cdot 10^{+186}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle\_m \cdot \pi}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(2 \cdot \sin t\_0\right) \cdot \left(\left(b + a\right) \cdot \cos t\_0\right)\right)\\ \end{array} \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (let* ((t_0 (/ angle_m (/ 180.0 PI))))
         (*
          angle_s
          (if (<= a 4.1e+186)
            (*
             (* (- b a) (cos (/ PI (/ 180.0 angle_m))))
             (* (+ b a) (* 2.0 (sin (/ 1.0 (/ 180.0 (* angle_m PI)))))))
            (* (- b a) (* (* 2.0 (sin t_0)) (* (+ b a) (cos t_0))))))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = angle_m / (180.0 / ((double) M_PI));
      	double tmp;
      	if (a <= 4.1e+186) {
      		tmp = ((b - a) * cos((((double) M_PI) / (180.0 / angle_m)))) * ((b + a) * (2.0 * sin((1.0 / (180.0 / (angle_m * ((double) M_PI)))))));
      	} else {
      		tmp = (b - a) * ((2.0 * sin(t_0)) * ((b + a) * cos(t_0)));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = angle_m / (180.0 / Math.PI);
      	double tmp;
      	if (a <= 4.1e+186) {
      		tmp = ((b - a) * Math.cos((Math.PI / (180.0 / angle_m)))) * ((b + a) * (2.0 * Math.sin((1.0 / (180.0 / (angle_m * Math.PI))))));
      	} else {
      		tmp = (b - a) * ((2.0 * Math.sin(t_0)) * ((b + a) * Math.cos(t_0)));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	t_0 = angle_m / (180.0 / math.pi)
      	tmp = 0
      	if a <= 4.1e+186:
      		tmp = ((b - a) * math.cos((math.pi / (180.0 / angle_m)))) * ((b + a) * (2.0 * math.sin((1.0 / (180.0 / (angle_m * math.pi))))))
      	else:
      		tmp = (b - a) * ((2.0 * math.sin(t_0)) * ((b + a) * math.cos(t_0)))
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	t_0 = Float64(angle_m / Float64(180.0 / pi))
      	tmp = 0.0
      	if (a <= 4.1e+186)
      		tmp = Float64(Float64(Float64(b - a) * cos(Float64(pi / Float64(180.0 / angle_m)))) * Float64(Float64(b + a) * Float64(2.0 * sin(Float64(1.0 / Float64(180.0 / Float64(angle_m * pi)))))));
      	else
      		tmp = Float64(Float64(b - a) * Float64(Float64(2.0 * sin(t_0)) * Float64(Float64(b + a) * cos(t_0))));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	t_0 = angle_m / (180.0 / pi);
      	tmp = 0.0;
      	if (a <= 4.1e+186)
      		tmp = ((b - a) * cos((pi / (180.0 / angle_m)))) * ((b + a) * (2.0 * sin((1.0 / (180.0 / (angle_m * pi))))));
      	else
      		tmp = (b - a) * ((2.0 * sin(t_0)) * ((b + a) * cos(t_0)));
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(angle$95$m / N[(180.0 / Pi), $MachinePrecision]), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[a, 4.1e+186], N[(N[(N[(b - a), $MachinePrecision] * N[Cos[N[(Pi / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[(2.0 * N[Sin[N[(1.0 / N[(180.0 / N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b - a), $MachinePrecision] * N[(N[(2.0 * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      \begin{array}{l}
      t_0 := \frac{angle\_m}{\frac{180}{\pi}}\\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;a \leq 4.1 \cdot 10^{+186}:\\
      \;\;\;\;\left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle\_m \cdot \pi}}\right)\right)\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;\left(b - a\right) \cdot \left(\left(2 \cdot \sin t\_0\right) \cdot \left(\left(b + a\right) \cdot \cos t\_0\right)\right)\\
      
      
      \end{array}
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < 4.1e186

        1. Initial program 55.6%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified55.7%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
          2. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          3. associate-*r*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          4. difference-of-squaresN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
          5. associate-*l*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          6. associate-*r*N/A

            \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        6. Applied egg-rr67.5%

          \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
        7. Step-by-step derivation
          1. associate-/r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{180} \cdot angle\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. associate-*l/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. clear-numN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\left(\frac{1}{\frac{180}{\mathsf{PI}\left(\right) \cdot angle}}\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(\color{blue}{180}, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          7. PI-lowering-PI.f6469.4%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(180, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. Applied egg-rr69.4%

          \[\leadsto \left(\left(2 \cdot \sin \color{blue}{\left(\frac{1}{\frac{180}{\pi \cdot angle}}\right)}\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]

        if 4.1e186 < a

        1. Initial program 41.6%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified41.6%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
          2. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          3. associate-*r*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          4. difference-of-squaresN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
          5. associate-*l*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          6. associate-*r*N/A

            \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        6. Applied egg-rr83.2%

          \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
        7. Step-by-step derivation
          1. add-sqr-sqrtN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. pow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left({\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. pow-lowering-pow.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. sqrt-lowering-sqrt.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. PI-lowering-PI.f6471.8%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. Applied egg-rr71.8%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\color{blue}{{\left(\sqrt{\pi}\right)}^{2}}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
        9. Step-by-step derivation
          1. add-sqr-sqrtN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\left({\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. pow-lowering-pow.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. sqrt-lowering-sqrt.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. PI-lowering-PI.f6488.4%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        10. Applied egg-rr88.4%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\color{blue}{{\left(\sqrt{\pi}\right)}^{2}}}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
        11. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \left(\left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \color{blue}{\left(b - a\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(b - a\right) \cdot \color{blue}{\left(\left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(b - a\right), \color{blue}{\left(\left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right)}\right) \]
          4. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\color{blue}{\left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right)} \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right)\right) \]
          5. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\left(2 \cdot \left(\sin \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right) \cdot \left(b + a\right)\right)\right) \cdot \cos \color{blue}{\left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)}\right)\right) \]
          6. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\left(2 \cdot \left(\sin \left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{180}{angle}}\right) \cdot \left(b + a\right)\right)\right) \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right)\right) \]
          7. add-sqr-sqrtN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\left(2 \cdot \left(\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right) \cdot \left(b + a\right)\right)\right) \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right)\right) \]
          8. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\left(\left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \cos \color{blue}{\left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)}\right)\right) \]
        12. Applied egg-rr83.2%

          \[\leadsto \color{blue}{\left(b - a\right) \cdot \left(\left(2 \cdot \sin \left(\frac{angle}{\frac{180}{\pi}}\right)\right) \cdot \left(\left(b + a\right) \cdot \cos \left(\frac{angle}{\frac{180}{\pi}}\right)\right)\right)} \]
      3. Recombined 2 regimes into one program.
      4. Final simplification70.3%

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 4.1 \cdot 10^{+186}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \cos \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{1}{\frac{180}{angle \cdot \pi}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(2 \cdot \sin \left(\frac{angle}{\frac{180}{\pi}}\right)\right) \cdot \left(\left(b + a\right) \cdot \cos \left(\frac{angle}{\frac{180}{\pi}}\right)\right)\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 8: 67.7% accurate, 1.8× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \frac{angle\_m}{\frac{180}{\pi}}\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+156}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(2 \cdot \sin t\_0\right) \cdot \left(\left(b + a\right) \cdot \cos t\_0\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)\right)\\ \end{array} \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (let* ((t_0 (/ angle_m (/ 180.0 PI))))
         (*
          angle_s
          (if (<= (/ angle_m 180.0) 1e+156)
            (* (- b a) (* (* 2.0 (sin t_0)) (* (+ b a) (cos t_0))))
            (* (- b a) (* (+ b a) (* 2.0 (sin (/ PI (/ 180.0 angle_m))))))))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = angle_m / (180.0 / ((double) M_PI));
      	double tmp;
      	if ((angle_m / 180.0) <= 1e+156) {
      		tmp = (b - a) * ((2.0 * sin(t_0)) * ((b + a) * cos(t_0)));
      	} else {
      		tmp = (b - a) * ((b + a) * (2.0 * sin((((double) M_PI) / (180.0 / angle_m)))));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = angle_m / (180.0 / Math.PI);
      	double tmp;
      	if ((angle_m / 180.0) <= 1e+156) {
      		tmp = (b - a) * ((2.0 * Math.sin(t_0)) * ((b + a) * Math.cos(t_0)));
      	} else {
      		tmp = (b - a) * ((b + a) * (2.0 * Math.sin((Math.PI / (180.0 / angle_m)))));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	t_0 = angle_m / (180.0 / math.pi)
      	tmp = 0
      	if (angle_m / 180.0) <= 1e+156:
      		tmp = (b - a) * ((2.0 * math.sin(t_0)) * ((b + a) * math.cos(t_0)))
      	else:
      		tmp = (b - a) * ((b + a) * (2.0 * math.sin((math.pi / (180.0 / angle_m)))))
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	t_0 = Float64(angle_m / Float64(180.0 / pi))
      	tmp = 0.0
      	if (Float64(angle_m / 180.0) <= 1e+156)
      		tmp = Float64(Float64(b - a) * Float64(Float64(2.0 * sin(t_0)) * Float64(Float64(b + a) * cos(t_0))));
      	else
      		tmp = Float64(Float64(b - a) * Float64(Float64(b + a) * Float64(2.0 * sin(Float64(pi / Float64(180.0 / angle_m))))));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	t_0 = angle_m / (180.0 / pi);
      	tmp = 0.0;
      	if ((angle_m / 180.0) <= 1e+156)
      		tmp = (b - a) * ((2.0 * sin(t_0)) * ((b + a) * cos(t_0)));
      	else
      		tmp = (b - a) * ((b + a) * (2.0 * sin((pi / (180.0 / angle_m)))));
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(angle$95$m / N[(180.0 / Pi), $MachinePrecision]), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 1e+156], N[(N[(b - a), $MachinePrecision] * N[(N[(2.0 * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b - a), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[(2.0 * N[Sin[N[(Pi / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      \begin{array}{l}
      t_0 := \frac{angle\_m}{\frac{180}{\pi}}\\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+156}:\\
      \;\;\;\;\left(b - a\right) \cdot \left(\left(2 \cdot \sin t\_0\right) \cdot \left(\left(b + a\right) \cdot \cos t\_0\right)\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)\right)\\
      
      
      \end{array}
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if (/.f64 angle #s(literal 180 binary64)) < 9.9999999999999998e155

        1. Initial program 57.0%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified56.8%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
          2. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          3. associate-*r*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          4. difference-of-squaresN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
          5. associate-*l*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          6. associate-*r*N/A

            \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        6. Applied egg-rr72.2%

          \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
        7. Step-by-step derivation
          1. add-sqr-sqrtN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. pow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left({\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. pow-lowering-pow.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. sqrt-lowering-sqrt.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. PI-lowering-PI.f6473.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. Applied egg-rr73.0%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\color{blue}{{\left(\sqrt{\pi}\right)}^{2}}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
        9. Step-by-step derivation
          1. add-sqr-sqrtN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\left({\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. pow-lowering-pow.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. sqrt-lowering-sqrt.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. PI-lowering-PI.f6473.2%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{/.f64}\left(\mathsf{pow.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), 2\right), \mathsf{/.f64}\left(180, angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        10. Applied egg-rr73.2%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\pi}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\color{blue}{{\left(\sqrt{\pi}\right)}^{2}}}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right) \]
        11. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \left(\left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \color{blue}{\left(b - a\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(b - a\right) \cdot \color{blue}{\left(\left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(b - a\right), \color{blue}{\left(\left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right)}\right) \]
          4. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\color{blue}{\left(\left(2 \cdot \sin \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right)} \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right)\right) \]
          5. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\left(2 \cdot \left(\sin \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right) \cdot \left(b + a\right)\right)\right) \cdot \cos \color{blue}{\left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)}\right)\right) \]
          6. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\left(2 \cdot \left(\sin \left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{180}{angle}}\right) \cdot \left(b + a\right)\right)\right) \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right)\right) \]
          7. add-sqr-sqrtN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\left(2 \cdot \left(\sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right) \cdot \left(b + a\right)\right)\right) \cdot \cos \left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)\right)\right) \]
          8. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\left(\left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \cos \color{blue}{\left(\frac{{\left(\sqrt{\mathsf{PI}\left(\right)}\right)}^{2}}{\frac{180}{angle}}\right)}\right)\right) \]
        12. Applied egg-rr72.9%

          \[\leadsto \color{blue}{\left(b - a\right) \cdot \left(\left(2 \cdot \sin \left(\frac{angle}{\frac{180}{\pi}}\right)\right) \cdot \left(\left(b + a\right) \cdot \cos \left(\frac{angle}{\frac{180}{\pi}}\right)\right)\right)} \]

        if 9.9999999999999998e155 < (/.f64 angle #s(literal 180 binary64))

        1. Initial program 32.2%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified35.3%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
          2. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          3. associate-*r*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          4. difference-of-squaresN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
          5. associate-*l*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          6. associate-*r*N/A

            \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        6. Applied egg-rr35.4%

          \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
        7. Step-by-step derivation
          1. clear-numN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{\frac{1}{\frac{angle}{180}}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. add-sqr-sqrtN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\frac{angle}{180}}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. frac-2negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\frac{\mathsf{neg}\left(angle\right)}{\mathsf{neg}\left(180\right)}}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. associate-/r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\mathsf{neg}\left(angle\right)} \cdot \left(\mathsf{neg}\left(180\right)\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. times-fracN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\mathsf{neg}\left(angle\right)}} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\mathsf{neg}\left(angle\right)}}\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{1}{\mathsf{neg}\left(angle\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          8. sqrt-lowering-sqrt.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\frac{1}{\mathsf{neg}\left(angle\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{1}{\mathsf{neg}\left(angle\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          10. frac-2negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{\mathsf{neg}\left(1\right)}{\mathsf{neg}\left(\left(\mathsf{neg}\left(angle\right)\right)\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          11. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{-1}{\mathsf{neg}\left(\left(\mathsf{neg}\left(angle\right)\right)\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          12. remove-double-negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{-1}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          13. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          14. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\mathsf{neg}\left(180\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          15. sqrt-lowering-sqrt.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\mathsf{neg}\left(180\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          16. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\mathsf{neg}\left(180\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          17. metadata-eval48.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), -180\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. Applied egg-rr48.0%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \color{blue}{\left(\frac{\sqrt{\pi}}{\frac{-1}{angle}} \cdot \frac{\sqrt{\pi}}{-180}\right)} \cdot \left(b - a\right)\right) \]
        9. Taylor expanded in angle around 0

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \color{blue}{\left(b - a\right)}\right) \]
        10. Step-by-step derivation
          1. --lowering--.f6439.7%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{\_.f64}\left(b, \color{blue}{a}\right)\right) \]
        11. Simplified39.7%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(b - a\right)} \]
      3. Recombined 2 regimes into one program.
      4. Final simplification69.7%

        \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 10^{+156}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(2 \cdot \sin \left(\frac{angle}{\frac{180}{\pi}}\right)\right) \cdot \left(\left(b + a\right) \cdot \cos \left(\frac{angle}{\frac{180}{\pi}}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right)\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 9: 67.1% accurate, 3.2× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+109}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin t\_0\right)\\ \mathbf{elif}\;\frac{angle\_m}{180} \leq 10^{+156}:\\ \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot t\_0\\ \mathbf{else}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)\right)\\ \end{array} \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (let* ((t_0 (* (* angle_m PI) 0.011111111111111112)))
         (*
          angle_s
          (if (<= (/ angle_m 180.0) 5e+109)
            (* (- b a) (* (+ b a) (sin t_0)))
            (if (<= (/ angle_m 180.0) 1e+156)
              (* (- (* b b) (* a a)) t_0)
              (* (- b a) (* (+ b a) (* 2.0 (sin (/ PI (/ 180.0 angle_m)))))))))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = (angle_m * ((double) M_PI)) * 0.011111111111111112;
      	double tmp;
      	if ((angle_m / 180.0) <= 5e+109) {
      		tmp = (b - a) * ((b + a) * sin(t_0));
      	} else if ((angle_m / 180.0) <= 1e+156) {
      		tmp = ((b * b) - (a * a)) * t_0;
      	} else {
      		tmp = (b - a) * ((b + a) * (2.0 * sin((((double) M_PI) / (180.0 / angle_m)))));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = (angle_m * Math.PI) * 0.011111111111111112;
      	double tmp;
      	if ((angle_m / 180.0) <= 5e+109) {
      		tmp = (b - a) * ((b + a) * Math.sin(t_0));
      	} else if ((angle_m / 180.0) <= 1e+156) {
      		tmp = ((b * b) - (a * a)) * t_0;
      	} else {
      		tmp = (b - a) * ((b + a) * (2.0 * Math.sin((Math.PI / (180.0 / angle_m)))));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	t_0 = (angle_m * math.pi) * 0.011111111111111112
      	tmp = 0
      	if (angle_m / 180.0) <= 5e+109:
      		tmp = (b - a) * ((b + a) * math.sin(t_0))
      	elif (angle_m / 180.0) <= 1e+156:
      		tmp = ((b * b) - (a * a)) * t_0
      	else:
      		tmp = (b - a) * ((b + a) * (2.0 * math.sin((math.pi / (180.0 / angle_m)))))
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	t_0 = Float64(Float64(angle_m * pi) * 0.011111111111111112)
      	tmp = 0.0
      	if (Float64(angle_m / 180.0) <= 5e+109)
      		tmp = Float64(Float64(b - a) * Float64(Float64(b + a) * sin(t_0)));
      	elseif (Float64(angle_m / 180.0) <= 1e+156)
      		tmp = Float64(Float64(Float64(b * b) - Float64(a * a)) * t_0);
      	else
      		tmp = Float64(Float64(b - a) * Float64(Float64(b + a) * Float64(2.0 * sin(Float64(pi / Float64(180.0 / angle_m))))));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	t_0 = (angle_m * pi) * 0.011111111111111112;
      	tmp = 0.0;
      	if ((angle_m / 180.0) <= 5e+109)
      		tmp = (b - a) * ((b + a) * sin(t_0));
      	elseif ((angle_m / 180.0) <= 1e+156)
      		tmp = ((b * b) - (a * a)) * t_0;
      	else
      		tmp = (b - a) * ((b + a) * (2.0 * sin((pi / (180.0 / angle_m)))));
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 5e+109], N[(N[(b - a), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 1e+156], N[(N[(N[(b * b), $MachinePrecision] - N[(a * a), $MachinePrecision]), $MachinePrecision] * t$95$0), $MachinePrecision], N[(N[(b - a), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[(2.0 * N[Sin[N[(Pi / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      \begin{array}{l}
      t_0 := \left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+109}:\\
      \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin t\_0\right)\\
      
      \mathbf{elif}\;\frac{angle\_m}{180} \leq 10^{+156}:\\
      \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot t\_0\\
      
      \mathbf{else}:\\
      \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)\right)\\
      
      
      \end{array}
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 3 regimes
      2. if (/.f64 angle #s(literal 180 binary64)) < 5.0000000000000001e109

        1. Initial program 58.1%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified58.3%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
          2. *-commutativeN/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right) \cdot \color{blue}{\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)}\right) \]
          3. associate-*r*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)} \]
          4. associate-*r/N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \]
          5. associate-*r*N/A

            \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot 2\right) \cdot \color{blue}{\left(b \cdot b - a \cdot a\right)} \]
          6. *-commutativeN/A

            \[\leadsto \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - a \cdot a\right) \]
          7. *-commutativeN/A

            \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right)} \]
          8. difference-of-squaresN/A

            \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\color{blue}{2} \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
        6. Applied egg-rr74.2%

          \[\leadsto \color{blue}{\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)\right)} \]

        if 5.0000000000000001e109 < (/.f64 angle #s(literal 180 binary64)) < 9.9999999999999998e155

        1. Initial program 27.6%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified15.1%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6451.9%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified51.9%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]

        if 9.9999999999999998e155 < (/.f64 angle #s(literal 180 binary64))

        1. Initial program 32.2%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified35.3%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
          2. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          3. associate-*r*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          4. difference-of-squaresN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \cos \color{blue}{\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)}\right) \]
          5. associate-*l*N/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
          6. associate-*r*N/A

            \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)} \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot 2\right) \cdot \left(b + a\right)\right), \color{blue}{\left(\left(b - a\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)}\right) \]
        6. Applied egg-rr35.4%

          \[\leadsto \color{blue}{\left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \left(\frac{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\right)\right)} \]
        7. Step-by-step derivation
          1. clear-numN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\mathsf{PI}\left(\right)}{\frac{1}{\frac{angle}{180}}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          2. add-sqr-sqrtN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\frac{angle}{180}}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          3. frac-2negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\frac{\mathsf{neg}\left(angle\right)}{\mathsf{neg}\left(180\right)}}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          4. associate-/r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\mathsf{neg}\left(angle\right)} \cdot \left(\mathsf{neg}\left(180\right)\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          5. times-fracN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\mathsf{neg}\left(angle\right)}} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{\mathsf{neg}\left(angle\right)}}\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{1}{\mathsf{neg}\left(angle\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          8. sqrt-lowering-sqrt.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\frac{1}{\mathsf{neg}\left(angle\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{1}{\mathsf{neg}\left(angle\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          10. frac-2negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{\mathsf{neg}\left(1\right)}{\mathsf{neg}\left(\left(\mathsf{neg}\left(angle\right)\right)\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          11. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{-1}{\mathsf{neg}\left(\left(\mathsf{neg}\left(angle\right)\right)\right)}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          12. remove-double-negN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{-1}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          13. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(180\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          14. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\mathsf{neg}\left(180\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          15. sqrt-lowering-sqrt.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\mathsf{neg}\left(180\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          16. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\mathsf{neg}\left(180\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
          17. metadata-eval48.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(-1, angle\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), -180\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. Applied egg-rr48.0%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \left(\cos \color{blue}{\left(\frac{\sqrt{\pi}}{\frac{-1}{angle}} \cdot \frac{\sqrt{\pi}}{-180}\right)} \cdot \left(b - a\right)\right) \]
        9. Taylor expanded in angle around 0

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \color{blue}{\left(b - a\right)}\right) \]
        10. Step-by-step derivation
          1. --lowering--.f6439.7%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{+.f64}\left(b, a\right)\right), \mathsf{\_.f64}\left(b, \color{blue}{a}\right)\right) \]
        11. Simplified39.7%

          \[\leadsto \left(\left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right) \cdot \left(b + a\right)\right) \cdot \color{blue}{\left(b - a\right)} \]
      3. Recombined 3 regimes into one program.
      4. Final simplification70.1%

        \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 5 \cdot 10^{+109}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+156}:\\ \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right)\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 10: 66.0% accurate, 3.6× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;angle\_m \leq 85:\\ \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \sin \left(\pi \cdot \left(angle\_m \cdot 0.011111111111111112\right)\right)\\ \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (*
        angle_s
        (if (<= angle_m 85.0)
          (* (+ b a) (* (- b a) (* (* angle_m PI) 0.011111111111111112)))
          (* (- (* b b) (* a a)) (sin (* PI (* angle_m 0.011111111111111112)))))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (angle_m <= 85.0) {
      		tmp = (b + a) * ((b - a) * ((angle_m * ((double) M_PI)) * 0.011111111111111112));
      	} else {
      		tmp = ((b * b) - (a * a)) * sin((((double) M_PI) * (angle_m * 0.011111111111111112)));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (angle_m <= 85.0) {
      		tmp = (b + a) * ((b - a) * ((angle_m * Math.PI) * 0.011111111111111112));
      	} else {
      		tmp = ((b * b) - (a * a)) * Math.sin((Math.PI * (angle_m * 0.011111111111111112)));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	tmp = 0
      	if angle_m <= 85.0:
      		tmp = (b + a) * ((b - a) * ((angle_m * math.pi) * 0.011111111111111112))
      	else:
      		tmp = ((b * b) - (a * a)) * math.sin((math.pi * (angle_m * 0.011111111111111112)))
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	tmp = 0.0
      	if (angle_m <= 85.0)
      		tmp = Float64(Float64(b + a) * Float64(Float64(b - a) * Float64(Float64(angle_m * pi) * 0.011111111111111112)));
      	else
      		tmp = Float64(Float64(Float64(b * b) - Float64(a * a)) * sin(Float64(pi * Float64(angle_m * 0.011111111111111112))));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	tmp = 0.0;
      	if (angle_m <= 85.0)
      		tmp = (b + a) * ((b - a) * ((angle_m * pi) * 0.011111111111111112));
      	else
      		tmp = ((b * b) - (a * a)) * sin((pi * (angle_m * 0.011111111111111112)));
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[angle$95$m, 85.0], N[(N[(b + a), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * b), $MachinePrecision] - N[(a * a), $MachinePrecision]), $MachinePrecision] * N[Sin[N[(Pi * N[(angle$95$m * 0.011111111111111112), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;angle\_m \leq 85:\\
      \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \sin \left(\pi \cdot \left(angle\_m \cdot 0.011111111111111112\right)\right)\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if angle < 85

        1. Initial program 61.3%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified61.4%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6458.1%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified58.1%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
          2. difference-of-squaresN/A

            \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \]
          3. associate-*l*N/A

            \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(b + a\right), \color{blue}{\left(\left(b - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)}\right) \]
          5. +-lowering-+.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \left(\color{blue}{\left(b - a\right)} \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\left(b - a\right), \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
          8. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{angle}\right)\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \color{blue}{\left(\mathsf{PI}\left(\right) \cdot angle\right)}\right)\right)\right) \]
          10. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), \color{blue}{angle}\right)\right)\right)\right) \]
          11. PI-lowering-PI.f6475.7%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right)\right) \]
        9. Applied egg-rr75.7%

          \[\leadsto \color{blue}{\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right)} \]

        if 85 < angle

        1. Initial program 32.4%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified32.3%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Applied egg-rr5.3%

          \[\leadsto \color{blue}{\frac{\left(b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)}{b \cdot b + a \cdot a}} \]
        6. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \frac{\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right) \cdot \left(b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)\right)}{\color{blue}{b \cdot b} + a \cdot a} \]
          2. associate-/l*N/A

            \[\leadsto \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right) \cdot \color{blue}{\frac{b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)}{b \cdot b + a \cdot a}} \]
          3. associate-*r*N/A

            \[\leadsto \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right) \cdot \frac{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)}{\color{blue}{b} \cdot b + a \cdot a} \]
          4. associate-*r*N/A

            \[\leadsto \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right) \cdot \frac{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}{b \cdot \color{blue}{b} + a \cdot a} \]
          5. flip--N/A

            \[\leadsto \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right), \color{blue}{\left(b \cdot b - a \cdot a\right)}\right) \]
          7. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right)\right), \left(\color{blue}{b \cdot b} - a \cdot a\right)\right) \]
          8. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{90}\right)\right)\right), \left(\color{blue}{b} \cdot b - a \cdot a\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), \left(angle \cdot \frac{1}{90}\right)\right)\right), \left(\color{blue}{b} \cdot b - a \cdot a\right)\right) \]
          10. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \left(angle \cdot \frac{1}{90}\right)\right)\right), \left(b \cdot b - a \cdot a\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(angle, \frac{1}{90}\right)\right)\right), \left(b \cdot b - a \cdot a\right)\right) \]
          12. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(angle, \frac{1}{90}\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \color{blue}{\left(a \cdot a\right)}\right)\right) \]
          13. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(angle, \frac{1}{90}\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(\color{blue}{a} \cdot a\right)\right)\right) \]
          14. *-lowering-*.f6433.5%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(angle, \frac{1}{90}\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Applied egg-rr33.5%

          \[\leadsto \color{blue}{\sin \left(\pi \cdot \left(angle \cdot 0.011111111111111112\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
      3. Recombined 2 regimes into one program.
      4. Final simplification66.0%

        \[\leadsto \begin{array}{l} \mathbf{if}\;angle \leq 85:\\ \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \sin \left(\pi \cdot \left(angle \cdot 0.011111111111111112\right)\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 11: 49.6% accurate, 3.7× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;a \leq 4.5 \cdot 10^{-118}:\\ \;\;\;\;\left(b \cdot b\right) \cdot \sin t\_0\\ \mathbf{else}:\\ \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot t\_0\right)\\ \end{array} \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (let* ((t_0 (* (* angle_m PI) 0.011111111111111112)))
         (*
          angle_s
          (if (<= a 4.5e-118) (* (* b b) (sin t_0)) (* (+ b a) (* (- b a) t_0))))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = (angle_m * ((double) M_PI)) * 0.011111111111111112;
      	double tmp;
      	if (a <= 4.5e-118) {
      		tmp = (b * b) * sin(t_0);
      	} else {
      		tmp = (b + a) * ((b - a) * t_0);
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double t_0 = (angle_m * Math.PI) * 0.011111111111111112;
      	double tmp;
      	if (a <= 4.5e-118) {
      		tmp = (b * b) * Math.sin(t_0);
      	} else {
      		tmp = (b + a) * ((b - a) * t_0);
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	t_0 = (angle_m * math.pi) * 0.011111111111111112
      	tmp = 0
      	if a <= 4.5e-118:
      		tmp = (b * b) * math.sin(t_0)
      	else:
      		tmp = (b + a) * ((b - a) * t_0)
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	t_0 = Float64(Float64(angle_m * pi) * 0.011111111111111112)
      	tmp = 0.0
      	if (a <= 4.5e-118)
      		tmp = Float64(Float64(b * b) * sin(t_0));
      	else
      		tmp = Float64(Float64(b + a) * Float64(Float64(b - a) * t_0));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	t_0 = (angle_m * pi) * 0.011111111111111112;
      	tmp = 0.0;
      	if (a <= 4.5e-118)
      		tmp = (b * b) * sin(t_0);
      	else
      		tmp = (b + a) * ((b - a) * t_0);
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[a, 4.5e-118], N[(N[(b * b), $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision], N[(N[(b + a), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * t$95$0), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      \begin{array}{l}
      t_0 := \left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;a \leq 4.5 \cdot 10^{-118}:\\
      \;\;\;\;\left(b \cdot b\right) \cdot \sin t\_0\\
      
      \mathbf{else}:\\
      \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot t\_0\right)\\
      
      
      \end{array}
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < 4.5e-118

        1. Initial program 58.6%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified58.0%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Applied egg-rr20.1%

          \[\leadsto \color{blue}{\frac{\left(b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)}{b \cdot b + a \cdot a}} \]
        6. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \frac{\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right) \cdot \left(b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)\right)}{\color{blue}{b \cdot b} + a \cdot a} \]
          2. flip-+N/A

            \[\leadsto \frac{\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right) \cdot \left(b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)\right)}{\frac{\left(b \cdot b\right) \cdot \left(b \cdot b\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}{\color{blue}{b \cdot b - a \cdot a}}} \]
          3. associate-*r*N/A

            \[\leadsto \frac{\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right) \cdot \left(b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)\right)}{\frac{b \cdot \left(b \cdot \left(b \cdot b\right)\right) - \left(a \cdot a\right) \cdot \left(a \cdot a\right)}{\color{blue}{b} \cdot b - a \cdot a}} \]
          4. associate-*r*N/A

            \[\leadsto \frac{\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right) \cdot \left(b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)\right)}{\frac{b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)}{b \cdot \color{blue}{b} - a \cdot a}} \]
          5. div-invN/A

            \[\leadsto \frac{\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right) \cdot \left(b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)\right)}{\left(b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)\right) \cdot \color{blue}{\frac{1}{b \cdot b - a \cdot a}}} \]
          6. times-fracN/A

            \[\leadsto \frac{\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right)}{b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)} \cdot \color{blue}{\frac{b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)}{\frac{1}{b \cdot b - a \cdot a}}} \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right)}{b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)}\right), \color{blue}{\left(\frac{b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)}{\frac{1}{b \cdot b - a \cdot a}}\right)}\right) \]
        7. Applied egg-rr7.8%

          \[\leadsto \color{blue}{\frac{\sin \left(\pi \cdot \left(angle \cdot 0.011111111111111112\right)\right)}{b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)} \cdot \frac{b \cdot \left(b \cdot \left(b \cdot b\right)\right) - a \cdot \left(a \cdot \left(a \cdot a\right)\right)}{\frac{1}{b \cdot b - a \cdot a}}} \]
        8. Taylor expanded in b around inf

          \[\leadsto \color{blue}{{b}^{2} \cdot \sin \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
        9. Step-by-step derivation
          1. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left({b}^{2}\right), \color{blue}{\sin \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
          2. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\left(b \cdot b\right), \sin \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \sin \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
          4. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \sin \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{1}{90}\right)\right) \]
          5. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \sin \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{90}\right)\right)\right) \]
          6. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \sin \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          7. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{sin.f64}\left(\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
          8. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{sin.f64}\left(\left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{90}\right)\right)\right)\right) \]
          9. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{sin.f64}\left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{1}{90}\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{sin.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{sin.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
          12. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{sin.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
          13. PI-lowering-PI.f6445.6%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{sin.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right)\right)\right) \]
        10. Simplified45.6%

          \[\leadsto \color{blue}{\left(b \cdot b\right) \cdot \sin \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right)} \]

        if 4.5e-118 < a

        1. Initial program 46.1%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified47.6%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6445.8%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified45.8%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
          2. difference-of-squaresN/A

            \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \]
          3. associate-*l*N/A

            \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(b + a\right), \color{blue}{\left(\left(b - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)}\right) \]
          5. +-lowering-+.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \left(\color{blue}{\left(b - a\right)} \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\left(b - a\right), \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
          8. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{angle}\right)\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \color{blue}{\left(\mathsf{PI}\left(\right) \cdot angle\right)}\right)\right)\right) \]
          10. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), \color{blue}{angle}\right)\right)\right)\right) \]
          11. PI-lowering-PI.f6467.4%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right)\right) \]
        9. Applied egg-rr67.4%

          \[\leadsto \color{blue}{\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right)} \]
      3. Recombined 2 regimes into one program.
      4. Final simplification52.6%

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 4.5 \cdot 10^{-118}:\\ \;\;\;\;\left(b \cdot b\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 12: 67.8% accurate, 3.7× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\right) \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (*
        angle_s
        (* (- b a) (* (+ b a) (sin (* (* angle_m PI) 0.011111111111111112))))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	return angle_s * ((b - a) * ((b + a) * sin(((angle_m * ((double) M_PI)) * 0.011111111111111112))));
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	return angle_s * ((b - a) * ((b + a) * Math.sin(((angle_m * Math.PI) * 0.011111111111111112))));
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	return angle_s * ((b - a) * ((b + a) * math.sin(((angle_m * math.pi) * 0.011111111111111112))))
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	return Float64(angle_s * Float64(Float64(b - a) * Float64(Float64(b + a) * sin(Float64(Float64(angle_m * pi) * 0.011111111111111112)))))
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp = code(angle_s, a, b, angle_m)
      	tmp = angle_s * ((b - a) * ((b + a) * sin(((angle_m * pi) * 0.011111111111111112))));
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * N[(N[(b - a), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[Sin[N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      angle\_s \cdot \left(\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\right)
      \end{array}
      
      Derivation
      1. Initial program 54.6%

        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
      2. Step-by-step derivation
        1. associate-*l*N/A

          \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
        2. *-commutativeN/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
        3. associate-*l*N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
        5. sin-lowering-sin.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        6. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        7. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        9. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        10. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        11. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      3. Simplified54.7%

        \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
      4. Add Preprocessing
      5. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\left(\color{blue}{2} \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \]
        2. *-commutativeN/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right) \cdot \color{blue}{\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)}\right) \]
        3. associate-*r*N/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right)} \]
        4. associate-*r/N/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \]
        5. associate-*r*N/A

          \[\leadsto \left(\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot 2\right) \cdot \color{blue}{\left(b \cdot b - a \cdot a\right)} \]
        6. *-commutativeN/A

          \[\leadsto \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - a \cdot a\right) \]
        7. *-commutativeN/A

          \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right)} \]
        8. difference-of-squaresN/A

          \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\color{blue}{2} \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
      6. Applied egg-rr68.2%

        \[\leadsto \color{blue}{\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)\right)} \]
      7. Final simplification68.2%

        \[\leadsto \left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right) \]
      8. Add Preprocessing

      Alternative 13: 54.2% accurate, 23.3× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;a \leq 1.35 \cdot 10^{+154}:\\ \;\;\;\;\left(angle\_m \cdot \pi\right) \cdot \left(0.011111111111111112 \cdot \left(b \cdot b - a \cdot a\right)\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(\left(a \cdot \left(angle\_m \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\ \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (*
        angle_s
        (if (<= a 1.35e+154)
          (* (* angle_m PI) (* 0.011111111111111112 (- (* b b) (* a a))))
          (* a (* (* a (* angle_m PI)) -0.011111111111111112)))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (a <= 1.35e+154) {
      		tmp = (angle_m * ((double) M_PI)) * (0.011111111111111112 * ((b * b) - (a * a)));
      	} else {
      		tmp = a * ((a * (angle_m * ((double) M_PI))) * -0.011111111111111112);
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (a <= 1.35e+154) {
      		tmp = (angle_m * Math.PI) * (0.011111111111111112 * ((b * b) - (a * a)));
      	} else {
      		tmp = a * ((a * (angle_m * Math.PI)) * -0.011111111111111112);
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	tmp = 0
      	if a <= 1.35e+154:
      		tmp = (angle_m * math.pi) * (0.011111111111111112 * ((b * b) - (a * a)))
      	else:
      		tmp = a * ((a * (angle_m * math.pi)) * -0.011111111111111112)
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	tmp = 0.0
      	if (a <= 1.35e+154)
      		tmp = Float64(Float64(angle_m * pi) * Float64(0.011111111111111112 * Float64(Float64(b * b) - Float64(a * a))));
      	else
      		tmp = Float64(a * Float64(Float64(a * Float64(angle_m * pi)) * -0.011111111111111112));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	tmp = 0.0;
      	if (a <= 1.35e+154)
      		tmp = (angle_m * pi) * (0.011111111111111112 * ((b * b) - (a * a)));
      	else
      		tmp = a * ((a * (angle_m * pi)) * -0.011111111111111112);
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[a, 1.35e+154], N[(N[(angle$95$m * Pi), $MachinePrecision] * N[(0.011111111111111112 * N[(N[(b * b), $MachinePrecision] - N[(a * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * N[(N[(a * N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision] * -0.011111111111111112), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;a \leq 1.35 \cdot 10^{+154}:\\
      \;\;\;\;\left(angle\_m \cdot \pi\right) \cdot \left(0.011111111111111112 \cdot \left(b \cdot b - a \cdot a\right)\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;a \cdot \left(\left(a \cdot \left(angle\_m \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < 1.35000000000000003e154

        1. Initial program 56.7%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified56.8%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6453.6%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified53.6%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{angle}\right)\right) \]
          3. associate-*r*N/A

            \[\leadsto \left(\left(b \cdot b - a \cdot a\right) \cdot \frac{1}{90}\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot angle\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(b \cdot b - a \cdot a\right) \cdot \frac{1}{90}\right), \color{blue}{\left(\mathsf{PI}\left(\right) \cdot angle\right)}\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(b \cdot b - a \cdot a\right), \frac{1}{90}\right), \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot angle\right)\right) \]
          6. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{\_.f64}\left(\left(b \cdot b\right), \left(a \cdot a\right)\right), \frac{1}{90}\right), \left(\mathsf{PI}\left(\right) \cdot angle\right)\right) \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot a\right)\right), \frac{1}{90}\right), \left(\mathsf{PI}\left(\right) \cdot angle\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right), \frac{1}{90}\right), \left(\mathsf{PI}\left(\right) \cdot angle\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right), \frac{1}{90}\right), \mathsf{*.f64}\left(\mathsf{PI}\left(\right), \color{blue}{angle}\right)\right) \]
          10. PI-lowering-PI.f6454.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right), \frac{1}{90}\right), \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right) \]
        9. Applied egg-rr54.0%

          \[\leadsto \color{blue}{\left(\left(b \cdot b - a \cdot a\right) \cdot 0.011111111111111112\right) \cdot \left(\pi \cdot angle\right)} \]

        if 1.35000000000000003e154 < a

        1. Initial program 35.5%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified35.5%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6431.5%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified31.5%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Taylor expanded in b around 0

          \[\leadsto \color{blue}{\frac{-1}{90} \cdot \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
        9. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\frac{-1}{90}} \]
          2. associate-*r*N/A

            \[\leadsto {a}^{2} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)} \]
          3. *-commutativeN/A

            \[\leadsto {a}^{2} \cdot \left(\frac{-1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left({a}^{2}\right), \color{blue}{\left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
          5. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          7. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\frac{-1}{90}}\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\left(angle \cdot \mathsf{PI}\left(\right)\right), \color{blue}{\frac{-1}{90}}\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right), \frac{-1}{90}\right)\right) \]
          10. PI-lowering-PI.f6435.5%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right), \frac{-1}{90}\right)\right) \]
        10. Simplified35.5%

          \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot -0.011111111111111112\right)} \]
        11. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto a \cdot \color{blue}{\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right) \cdot \color{blue}{a} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), \color{blue}{a}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), a\right) \]
          5. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right), a\right) \]
          6. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right), a\right) \]
          9. PI-lowering-PI.f6467.8%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right), a\right) \]
        12. Applied egg-rr67.8%

          \[\leadsto \color{blue}{\left(a \cdot \left(-0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right) \cdot a} \]
        13. Step-by-step derivation
          1. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\frac{-1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), \color{blue}{a}\right) \]
          2. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{-1}{90}\right)\right), a\right) \]
          3. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right) \cdot \frac{-1}{90}\right), a\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right), \frac{-1}{90}\right), a\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right), \frac{-1}{90}\right), a\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right), \frac{-1}{90}\right), a\right) \]
          7. PI-lowering-PI.f6467.9%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right), \frac{-1}{90}\right), a\right) \]
        14. Applied egg-rr67.9%

          \[\leadsto \color{blue}{\left(\left(a \cdot \left(\pi \cdot angle\right)\right) \cdot -0.011111111111111112\right) \cdot a} \]
      3. Recombined 2 regimes into one program.
      4. Final simplification55.3%

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 1.35 \cdot 10^{+154}:\\ \;\;\;\;\left(angle \cdot \pi\right) \cdot \left(0.011111111111111112 \cdot \left(b \cdot b - a \cdot a\right)\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(\left(a \cdot \left(angle \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 14: 54.2% accurate, 23.3× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;a \leq 1.32 \cdot 10^{+154}:\\ \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \left(\pi \cdot \left(angle\_m \cdot 0.011111111111111112\right)\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(\left(a \cdot \left(angle\_m \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\ \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (*
        angle_s
        (if (<= a 1.32e+154)
          (* (- (* b b) (* a a)) (* PI (* angle_m 0.011111111111111112)))
          (* a (* (* a (* angle_m PI)) -0.011111111111111112)))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (a <= 1.32e+154) {
      		tmp = ((b * b) - (a * a)) * (((double) M_PI) * (angle_m * 0.011111111111111112));
      	} else {
      		tmp = a * ((a * (angle_m * ((double) M_PI))) * -0.011111111111111112);
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (a <= 1.32e+154) {
      		tmp = ((b * b) - (a * a)) * (Math.PI * (angle_m * 0.011111111111111112));
      	} else {
      		tmp = a * ((a * (angle_m * Math.PI)) * -0.011111111111111112);
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	tmp = 0
      	if a <= 1.32e+154:
      		tmp = ((b * b) - (a * a)) * (math.pi * (angle_m * 0.011111111111111112))
      	else:
      		tmp = a * ((a * (angle_m * math.pi)) * -0.011111111111111112)
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	tmp = 0.0
      	if (a <= 1.32e+154)
      		tmp = Float64(Float64(Float64(b * b) - Float64(a * a)) * Float64(pi * Float64(angle_m * 0.011111111111111112)));
      	else
      		tmp = Float64(a * Float64(Float64(a * Float64(angle_m * pi)) * -0.011111111111111112));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	tmp = 0.0;
      	if (a <= 1.32e+154)
      		tmp = ((b * b) - (a * a)) * (pi * (angle_m * 0.011111111111111112));
      	else
      		tmp = a * ((a * (angle_m * pi)) * -0.011111111111111112);
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[a, 1.32e+154], N[(N[(N[(b * b), $MachinePrecision] - N[(a * a), $MachinePrecision]), $MachinePrecision] * N[(Pi * N[(angle$95$m * 0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * N[(N[(a * N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision] * -0.011111111111111112), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;a \leq 1.32 \cdot 10^{+154}:\\
      \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \left(\pi \cdot \left(angle\_m \cdot 0.011111111111111112\right)\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;a \cdot \left(\left(a \cdot \left(angle\_m \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < 1.31999999999999998e154

        1. Initial program 56.7%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified56.8%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6453.6%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified53.6%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{90} \cdot angle\right) \cdot \mathsf{PI}\left(\right)\right), \mathsf{\_.f64}\left(\color{blue}{\mathsf{*.f64}\left(b, b\right)}, \mathsf{*.f64}\left(a, a\right)\right)\right) \]
          2. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(\frac{1}{90} \cdot angle\right), \mathsf{PI}\left(\right)\right), \mathsf{\_.f64}\left(\color{blue}{\mathsf{*.f64}\left(b, b\right)}, \mathsf{*.f64}\left(a, a\right)\right)\right) \]
          3. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(angle \cdot \frac{1}{90}\right), \mathsf{PI}\left(\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(\color{blue}{b}, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \frac{1}{90}\right), \mathsf{PI}\left(\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(\color{blue}{b}, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right) \]
          5. PI-lowering-PI.f6453.6%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \frac{1}{90}\right), \mathsf{PI.f64}\left(\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, \color{blue}{b}\right), \mathsf{*.f64}\left(a, a\right)\right)\right) \]
        9. Applied egg-rr53.6%

          \[\leadsto \color{blue}{\left(\left(angle \cdot 0.011111111111111112\right) \cdot \pi\right)} \cdot \left(b \cdot b - a \cdot a\right) \]

        if 1.31999999999999998e154 < a

        1. Initial program 35.5%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified35.5%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6431.5%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified31.5%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Taylor expanded in b around 0

          \[\leadsto \color{blue}{\frac{-1}{90} \cdot \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
        9. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\frac{-1}{90}} \]
          2. associate-*r*N/A

            \[\leadsto {a}^{2} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)} \]
          3. *-commutativeN/A

            \[\leadsto {a}^{2} \cdot \left(\frac{-1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left({a}^{2}\right), \color{blue}{\left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
          5. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          7. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\frac{-1}{90}}\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\left(angle \cdot \mathsf{PI}\left(\right)\right), \color{blue}{\frac{-1}{90}}\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right), \frac{-1}{90}\right)\right) \]
          10. PI-lowering-PI.f6435.5%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right), \frac{-1}{90}\right)\right) \]
        10. Simplified35.5%

          \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot -0.011111111111111112\right)} \]
        11. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto a \cdot \color{blue}{\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right) \cdot \color{blue}{a} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), \color{blue}{a}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), a\right) \]
          5. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right), a\right) \]
          6. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right), a\right) \]
          9. PI-lowering-PI.f6467.8%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right), a\right) \]
        12. Applied egg-rr67.8%

          \[\leadsto \color{blue}{\left(a \cdot \left(-0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right) \cdot a} \]
        13. Step-by-step derivation
          1. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\frac{-1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), \color{blue}{a}\right) \]
          2. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{-1}{90}\right)\right), a\right) \]
          3. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right) \cdot \frac{-1}{90}\right), a\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right), \frac{-1}{90}\right), a\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right), \frac{-1}{90}\right), a\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right), \frac{-1}{90}\right), a\right) \]
          7. PI-lowering-PI.f6467.9%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right), \frac{-1}{90}\right), a\right) \]
        14. Applied egg-rr67.9%

          \[\leadsto \color{blue}{\left(\left(a \cdot \left(\pi \cdot angle\right)\right) \cdot -0.011111111111111112\right) \cdot a} \]
      3. Recombined 2 regimes into one program.
      4. Final simplification55.0%

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 1.32 \cdot 10^{+154}:\\ \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \left(\pi \cdot \left(angle \cdot 0.011111111111111112\right)\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(\left(a \cdot \left(angle \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 15: 54.2% accurate, 23.3× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;a \leq 1.3 \cdot 10^{+154}:\\ \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(\left(a \cdot \left(angle\_m \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\ \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (*
        angle_s
        (if (<= a 1.3e+154)
          (* (- (* b b) (* a a)) (* (* angle_m PI) 0.011111111111111112))
          (* a (* (* a (* angle_m PI)) -0.011111111111111112)))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (a <= 1.3e+154) {
      		tmp = ((b * b) - (a * a)) * ((angle_m * ((double) M_PI)) * 0.011111111111111112);
      	} else {
      		tmp = a * ((a * (angle_m * ((double) M_PI))) * -0.011111111111111112);
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (a <= 1.3e+154) {
      		tmp = ((b * b) - (a * a)) * ((angle_m * Math.PI) * 0.011111111111111112);
      	} else {
      		tmp = a * ((a * (angle_m * Math.PI)) * -0.011111111111111112);
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	tmp = 0
      	if a <= 1.3e+154:
      		tmp = ((b * b) - (a * a)) * ((angle_m * math.pi) * 0.011111111111111112)
      	else:
      		tmp = a * ((a * (angle_m * math.pi)) * -0.011111111111111112)
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	tmp = 0.0
      	if (a <= 1.3e+154)
      		tmp = Float64(Float64(Float64(b * b) - Float64(a * a)) * Float64(Float64(angle_m * pi) * 0.011111111111111112));
      	else
      		tmp = Float64(a * Float64(Float64(a * Float64(angle_m * pi)) * -0.011111111111111112));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	tmp = 0.0;
      	if (a <= 1.3e+154)
      		tmp = ((b * b) - (a * a)) * ((angle_m * pi) * 0.011111111111111112);
      	else
      		tmp = a * ((a * (angle_m * pi)) * -0.011111111111111112);
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[a, 1.3e+154], N[(N[(N[(b * b), $MachinePrecision] - N[(a * a), $MachinePrecision]), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision], N[(a * N[(N[(a * N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision] * -0.011111111111111112), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;a \leq 1.3 \cdot 10^{+154}:\\
      \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;a \cdot \left(\left(a \cdot \left(angle\_m \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < 1.29999999999999994e154

        1. Initial program 56.7%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified56.8%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6453.6%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified53.6%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]

        if 1.29999999999999994e154 < a

        1. Initial program 35.5%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified35.5%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6431.5%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified31.5%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Taylor expanded in b around 0

          \[\leadsto \color{blue}{\frac{-1}{90} \cdot \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
        9. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\frac{-1}{90}} \]
          2. associate-*r*N/A

            \[\leadsto {a}^{2} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)} \]
          3. *-commutativeN/A

            \[\leadsto {a}^{2} \cdot \left(\frac{-1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left({a}^{2}\right), \color{blue}{\left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
          5. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          7. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\frac{-1}{90}}\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\left(angle \cdot \mathsf{PI}\left(\right)\right), \color{blue}{\frac{-1}{90}}\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right), \frac{-1}{90}\right)\right) \]
          10. PI-lowering-PI.f6435.5%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right), \frac{-1}{90}\right)\right) \]
        10. Simplified35.5%

          \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot -0.011111111111111112\right)} \]
        11. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto a \cdot \color{blue}{\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right) \cdot \color{blue}{a} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), \color{blue}{a}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), a\right) \]
          5. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right), a\right) \]
          6. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right), a\right) \]
          9. PI-lowering-PI.f6467.8%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right), a\right) \]
        12. Applied egg-rr67.8%

          \[\leadsto \color{blue}{\left(a \cdot \left(-0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right) \cdot a} \]
        13. Step-by-step derivation
          1. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\frac{-1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), \color{blue}{a}\right) \]
          2. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{-1}{90}\right)\right), a\right) \]
          3. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right) \cdot \frac{-1}{90}\right), a\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right), \frac{-1}{90}\right), a\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right), \frac{-1}{90}\right), a\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right), \frac{-1}{90}\right), a\right) \]
          7. PI-lowering-PI.f6467.9%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right), \frac{-1}{90}\right), a\right) \]
        14. Applied egg-rr67.9%

          \[\leadsto \color{blue}{\left(\left(a \cdot \left(\pi \cdot angle\right)\right) \cdot -0.011111111111111112\right) \cdot a} \]
      3. Recombined 2 regimes into one program.
      4. Final simplification55.0%

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 1.3 \cdot 10^{+154}:\\ \;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(\left(a \cdot \left(angle \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 16: 43.1% accurate, 29.9× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;a \leq 1.75 \cdot 10^{+18}:\\ \;\;\;\;\left(b \cdot b\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(\left(a \cdot \left(angle\_m \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\ \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (*
        angle_s
        (if (<= a 1.75e+18)
          (* (* b b) (* (* angle_m PI) 0.011111111111111112))
          (* a (* (* a (* angle_m PI)) -0.011111111111111112)))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (a <= 1.75e+18) {
      		tmp = (b * b) * ((angle_m * ((double) M_PI)) * 0.011111111111111112);
      	} else {
      		tmp = a * ((a * (angle_m * ((double) M_PI))) * -0.011111111111111112);
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (a <= 1.75e+18) {
      		tmp = (b * b) * ((angle_m * Math.PI) * 0.011111111111111112);
      	} else {
      		tmp = a * ((a * (angle_m * Math.PI)) * -0.011111111111111112);
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	tmp = 0
      	if a <= 1.75e+18:
      		tmp = (b * b) * ((angle_m * math.pi) * 0.011111111111111112)
      	else:
      		tmp = a * ((a * (angle_m * math.pi)) * -0.011111111111111112)
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	tmp = 0.0
      	if (a <= 1.75e+18)
      		tmp = Float64(Float64(b * b) * Float64(Float64(angle_m * pi) * 0.011111111111111112));
      	else
      		tmp = Float64(a * Float64(Float64(a * Float64(angle_m * pi)) * -0.011111111111111112));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	tmp = 0.0;
      	if (a <= 1.75e+18)
      		tmp = (b * b) * ((angle_m * pi) * 0.011111111111111112);
      	else
      		tmp = a * ((a * (angle_m * pi)) * -0.011111111111111112);
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[a, 1.75e+18], N[(N[(b * b), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision], N[(a * N[(N[(a * N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision] * -0.011111111111111112), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;a \leq 1.75 \cdot 10^{+18}:\\
      \;\;\;\;\left(b \cdot b\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;a \cdot \left(\left(a \cdot \left(angle\_m \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < 1.75e18

        1. Initial program 56.8%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified56.8%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6453.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified53.0%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Taylor expanded in b around inf

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left({b}^{2} \cdot \mathsf{PI}\left(\right)\right)\right)} \]
        9. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{{b}^{2}}\right)\right) \]
          2. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{{b}^{2}}\right) \]
          3. associate-*l*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{{b}^{2}} \]
          4. *-commutativeN/A

            \[\leadsto {b}^{2} \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left({b}^{2}\right), \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
          6. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\left(b \cdot b\right), \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(\frac{1}{90}, \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \color{blue}{\mathsf{PI}\left(\right)}\right)\right)\right) \]
          10. PI-lowering-PI.f6442.8%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right)\right) \]
        10. Simplified42.8%

          \[\leadsto \color{blue}{\left(b \cdot b\right) \cdot \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right)} \]

        if 1.75e18 < a

        1. Initial program 45.3%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified45.6%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6444.9%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified44.9%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Taylor expanded in b around 0

          \[\leadsto \color{blue}{\frac{-1}{90} \cdot \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
        9. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\frac{-1}{90}} \]
          2. associate-*r*N/A

            \[\leadsto {a}^{2} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)} \]
          3. *-commutativeN/A

            \[\leadsto {a}^{2} \cdot \left(\frac{-1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left({a}^{2}\right), \color{blue}{\left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
          5. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          7. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\frac{-1}{90}}\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\left(angle \cdot \mathsf{PI}\left(\right)\right), \color{blue}{\frac{-1}{90}}\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right), \frac{-1}{90}\right)\right) \]
          10. PI-lowering-PI.f6440.6%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right), \frac{-1}{90}\right)\right) \]
        10. Simplified40.6%

          \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot -0.011111111111111112\right)} \]
        11. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto a \cdot \color{blue}{\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right) \cdot \color{blue}{a} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), \color{blue}{a}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), a\right) \]
          5. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right), a\right) \]
          6. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right), a\right) \]
          9. PI-lowering-PI.f6457.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right), a\right) \]
        12. Applied egg-rr57.0%

          \[\leadsto \color{blue}{\left(a \cdot \left(-0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right) \cdot a} \]
        13. Step-by-step derivation
          1. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\frac{-1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), \color{blue}{a}\right) \]
          2. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{-1}{90}\right)\right), a\right) \]
          3. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right) \cdot \frac{-1}{90}\right), a\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right), \frac{-1}{90}\right), a\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right), \frac{-1}{90}\right), a\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right), \frac{-1}{90}\right), a\right) \]
          7. PI-lowering-PI.f6457.1%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right), \frac{-1}{90}\right), a\right) \]
        14. Applied egg-rr57.1%

          \[\leadsto \color{blue}{\left(\left(a \cdot \left(\pi \cdot angle\right)\right) \cdot -0.011111111111111112\right) \cdot a} \]
      3. Recombined 2 regimes into one program.
      4. Final simplification45.6%

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 1.75 \cdot 10^{+18}:\\ \;\;\;\;\left(b \cdot b\right) \cdot \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(\left(a \cdot \left(angle \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 17: 43.1% accurate, 29.9× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;a \leq 2.8 \cdot 10^{+18}:\\ \;\;\;\;\left(b \cdot b\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(a \cdot \left(\left(angle\_m \cdot \pi\right) \cdot -0.011111111111111112\right)\right)\\ \end{array} \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (*
        angle_s
        (if (<= a 2.8e+18)
          (* (* b b) (* (* angle_m PI) 0.011111111111111112))
          (* a (* a (* (* angle_m PI) -0.011111111111111112))))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (a <= 2.8e+18) {
      		tmp = (b * b) * ((angle_m * ((double) M_PI)) * 0.011111111111111112);
      	} else {
      		tmp = a * (a * ((angle_m * ((double) M_PI)) * -0.011111111111111112));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	double tmp;
      	if (a <= 2.8e+18) {
      		tmp = (b * b) * ((angle_m * Math.PI) * 0.011111111111111112);
      	} else {
      		tmp = a * (a * ((angle_m * Math.PI) * -0.011111111111111112));
      	}
      	return angle_s * tmp;
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	tmp = 0
      	if a <= 2.8e+18:
      		tmp = (b * b) * ((angle_m * math.pi) * 0.011111111111111112)
      	else:
      		tmp = a * (a * ((angle_m * math.pi) * -0.011111111111111112))
      	return angle_s * tmp
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	tmp = 0.0
      	if (a <= 2.8e+18)
      		tmp = Float64(Float64(b * b) * Float64(Float64(angle_m * pi) * 0.011111111111111112));
      	else
      		tmp = Float64(a * Float64(a * Float64(Float64(angle_m * pi) * -0.011111111111111112)));
      	end
      	return Float64(angle_s * tmp)
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp_2 = code(angle_s, a, b, angle_m)
      	tmp = 0.0;
      	if (a <= 2.8e+18)
      		tmp = (b * b) * ((angle_m * pi) * 0.011111111111111112);
      	else
      		tmp = a * (a * ((angle_m * pi) * -0.011111111111111112));
      	end
      	tmp_2 = angle_s * tmp;
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[a, 2.8e+18], N[(N[(b * b), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision], N[(a * N[(a * N[(N[(angle$95$m * Pi), $MachinePrecision] * -0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      angle\_s \cdot \begin{array}{l}
      \mathbf{if}\;a \leq 2.8 \cdot 10^{+18}:\\
      \;\;\;\;\left(b \cdot b\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;a \cdot \left(a \cdot \left(\left(angle\_m \cdot \pi\right) \cdot -0.011111111111111112\right)\right)\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < 2.8e18

        1. Initial program 56.8%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified56.8%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6453.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified53.0%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Taylor expanded in b around inf

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left({b}^{2} \cdot \mathsf{PI}\left(\right)\right)\right)} \]
        9. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{{b}^{2}}\right)\right) \]
          2. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{{b}^{2}}\right) \]
          3. associate-*l*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{{b}^{2}} \]
          4. *-commutativeN/A

            \[\leadsto {b}^{2} \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left({b}^{2}\right), \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
          6. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\left(b \cdot b\right), \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(\frac{1}{90}, \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \color{blue}{\mathsf{PI}\left(\right)}\right)\right)\right) \]
          10. PI-lowering-PI.f6442.8%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right)\right) \]
        10. Simplified42.8%

          \[\leadsto \color{blue}{\left(b \cdot b\right) \cdot \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right)} \]

        if 2.8e18 < a

        1. Initial program 45.3%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
          3. associate-*l*N/A

            \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
          5. sin-lowering-sin.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          6. associate-*r/N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          7. /-lowering-/.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          9. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        3. Simplified45.6%

          \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
        4. Add Preprocessing
        5. Taylor expanded in angle around 0

          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        6. Step-by-step derivation
          1. associate-*r*N/A

            \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          2. associate-*r*N/A

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
          6. PI-lowering-PI.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
          7. --lowering--.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
          8. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
          10. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
          11. *-lowering-*.f6444.9%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
        7. Simplified44.9%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
        8. Taylor expanded in b around 0

          \[\leadsto \color{blue}{\frac{-1}{90} \cdot \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
        9. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\frac{-1}{90}} \]
          2. associate-*r*N/A

            \[\leadsto {a}^{2} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)} \]
          3. *-commutativeN/A

            \[\leadsto {a}^{2} \cdot \left(\frac{-1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left({a}^{2}\right), \color{blue}{\left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
          5. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
          7. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\frac{-1}{90}}\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\left(angle \cdot \mathsf{PI}\left(\right)\right), \color{blue}{\frac{-1}{90}}\right)\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right), \frac{-1}{90}\right)\right) \]
          10. PI-lowering-PI.f6440.6%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right), \frac{-1}{90}\right)\right) \]
        10. Simplified40.6%

          \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot -0.011111111111111112\right)} \]
        11. Step-by-step derivation
          1. associate-*l*N/A

            \[\leadsto a \cdot \color{blue}{\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto \left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right) \cdot \color{blue}{a} \]
          3. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), \color{blue}{a}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), a\right) \]
          5. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right), a\right) \]
          6. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right), a\right) \]
          9. PI-lowering-PI.f6457.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right), a\right) \]
        12. Applied egg-rr57.0%

          \[\leadsto \color{blue}{\left(a \cdot \left(-0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right) \cdot a} \]
      3. Recombined 2 regimes into one program.
      4. Final simplification45.6%

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 2.8 \cdot 10^{+18}:\\ \;\;\;\;\left(b \cdot b\right) \cdot \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(a \cdot \left(\left(angle \cdot \pi\right) \cdot -0.011111111111111112\right)\right)\\ \end{array} \]
      5. Add Preprocessing

      Alternative 18: 62.9% accurate, 32.2× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\right) \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (* angle_s (* (+ b a) (* (- b a) (* (* angle_m PI) 0.011111111111111112)))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	return angle_s * ((b + a) * ((b - a) * ((angle_m * ((double) M_PI)) * 0.011111111111111112)));
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	return angle_s * ((b + a) * ((b - a) * ((angle_m * Math.PI) * 0.011111111111111112)));
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	return angle_s * ((b + a) * ((b - a) * ((angle_m * math.pi) * 0.011111111111111112)))
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	return Float64(angle_s * Float64(Float64(b + a) * Float64(Float64(b - a) * Float64(Float64(angle_m * pi) * 0.011111111111111112))))
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp = code(angle_s, a, b, angle_m)
      	tmp = angle_s * ((b + a) * ((b - a) * ((angle_m * pi) * 0.011111111111111112)));
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * N[(N[(b + a), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      angle\_s \cdot \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\right)
      \end{array}
      
      Derivation
      1. Initial program 54.6%

        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
      2. Step-by-step derivation
        1. associate-*l*N/A

          \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
        2. *-commutativeN/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
        3. associate-*l*N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
        5. sin-lowering-sin.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        6. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        7. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        9. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        10. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        11. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      3. Simplified54.7%

        \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
      4. Add Preprocessing
      5. Taylor expanded in angle around 0

        \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
      6. Step-by-step derivation
        1. associate-*r*N/A

          \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
        2. associate-*r*N/A

          \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
        3. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
        5. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
        6. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
        7. --lowering--.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
        8. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
        9. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
        10. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
        11. *-lowering-*.f6451.4%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
      7. Simplified51.4%

        \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
      8. Step-by-step derivation
        1. *-commutativeN/A

          \[\leadsto \left(b \cdot b - a \cdot a\right) \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
        2. difference-of-squaresN/A

          \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \]
        3. associate-*l*N/A

          \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)} \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(b + a\right), \color{blue}{\left(\left(b - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)}\right) \]
        5. +-lowering-+.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \left(\color{blue}{\left(b - a\right)} \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
        6. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\left(b - a\right), \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right)\right) \]
        7. --lowering--.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\color{blue}{\frac{1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right) \]
        8. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{angle}\right)\right)\right)\right) \]
        9. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \color{blue}{\left(\mathsf{PI}\left(\right) \cdot angle\right)}\right)\right)\right) \]
        10. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), \color{blue}{angle}\right)\right)\right)\right) \]
        11. PI-lowering-PI.f6464.3%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right)\right) \]
      9. Applied egg-rr64.3%

        \[\leadsto \color{blue}{\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right)} \]
      10. Final simplification64.3%

        \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right) \]
      11. Add Preprocessing

      Alternative 19: 38.0% accurate, 46.6× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(a \cdot \left(a \cdot \left(\left(angle\_m \cdot \pi\right) \cdot -0.011111111111111112\right)\right)\right) \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (* angle_s (* a (* a (* (* angle_m PI) -0.011111111111111112)))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	return angle_s * (a * (a * ((angle_m * ((double) M_PI)) * -0.011111111111111112)));
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	return angle_s * (a * (a * ((angle_m * Math.PI) * -0.011111111111111112)));
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	return angle_s * (a * (a * ((angle_m * math.pi) * -0.011111111111111112)))
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	return Float64(angle_s * Float64(a * Float64(a * Float64(Float64(angle_m * pi) * -0.011111111111111112))))
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp = code(angle_s, a, b, angle_m)
      	tmp = angle_s * (a * (a * ((angle_m * pi) * -0.011111111111111112)));
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * N[(a * N[(a * N[(N[(angle$95$m * Pi), $MachinePrecision] * -0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      angle\_s \cdot \left(a \cdot \left(a \cdot \left(\left(angle\_m \cdot \pi\right) \cdot -0.011111111111111112\right)\right)\right)
      \end{array}
      
      Derivation
      1. Initial program 54.6%

        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
      2. Step-by-step derivation
        1. associate-*l*N/A

          \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
        2. *-commutativeN/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
        3. associate-*l*N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
        5. sin-lowering-sin.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        6. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        7. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        9. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        10. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        11. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      3. Simplified54.7%

        \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
      4. Add Preprocessing
      5. Taylor expanded in angle around 0

        \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
      6. Step-by-step derivation
        1. associate-*r*N/A

          \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
        2. associate-*r*N/A

          \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
        3. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
        5. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
        6. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
        7. --lowering--.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
        8. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
        9. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
        10. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
        11. *-lowering-*.f6451.4%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
      7. Simplified51.4%

        \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
      8. Taylor expanded in b around 0

        \[\leadsto \color{blue}{\frac{-1}{90} \cdot \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
      9. Step-by-step derivation
        1. *-commutativeN/A

          \[\leadsto \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\frac{-1}{90}} \]
        2. associate-*r*N/A

          \[\leadsto {a}^{2} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)} \]
        3. *-commutativeN/A

          \[\leadsto {a}^{2} \cdot \left(\frac{-1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left({a}^{2}\right), \color{blue}{\left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
        5. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\left(a \cdot a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
        6. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
        7. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\frac{-1}{90}}\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\left(angle \cdot \mathsf{PI}\left(\right)\right), \color{blue}{\frac{-1}{90}}\right)\right) \]
        9. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right), \frac{-1}{90}\right)\right) \]
        10. PI-lowering-PI.f6431.0%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right), \frac{-1}{90}\right)\right) \]
      10. Simplified31.0%

        \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot -0.011111111111111112\right)} \]
      11. Step-by-step derivation
        1. associate-*l*N/A

          \[\leadsto a \cdot \color{blue}{\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right)} \]
        2. *-commutativeN/A

          \[\leadsto \left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right) \cdot \color{blue}{a} \]
        3. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), \color{blue}{a}\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)\right), a\right) \]
        5. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right), a\right) \]
        6. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \left(\frac{-1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
        7. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\right), a\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right)\right)\right), a\right) \]
        9. PI-lowering-PI.f6436.4%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(\frac{-1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right)\right)\right), a\right) \]
      12. Applied egg-rr36.4%

        \[\leadsto \color{blue}{\left(a \cdot \left(-0.011111111111111112 \cdot \left(\pi \cdot angle\right)\right)\right) \cdot a} \]
      13. Final simplification36.4%

        \[\leadsto a \cdot \left(a \cdot \left(\left(angle \cdot \pi\right) \cdot -0.011111111111111112\right)\right) \]
      14. Add Preprocessing

      Alternative 20: 34.1% accurate, 46.6× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(a \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot -0.011111111111111112\right)\right) \end{array} \]
      angle\_m = (fabs.f64 angle)
      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
      (FPCore (angle_s a b angle_m)
       :precision binary64
       (* angle_s (* (* a a) (* (* angle_m PI) -0.011111111111111112))))
      angle\_m = fabs(angle);
      angle\_s = copysign(1.0, angle);
      double code(double angle_s, double a, double b, double angle_m) {
      	return angle_s * ((a * a) * ((angle_m * ((double) M_PI)) * -0.011111111111111112));
      }
      
      angle\_m = Math.abs(angle);
      angle\_s = Math.copySign(1.0, angle);
      public static double code(double angle_s, double a, double b, double angle_m) {
      	return angle_s * ((a * a) * ((angle_m * Math.PI) * -0.011111111111111112));
      }
      
      angle\_m = math.fabs(angle)
      angle\_s = math.copysign(1.0, angle)
      def code(angle_s, a, b, angle_m):
      	return angle_s * ((a * a) * ((angle_m * math.pi) * -0.011111111111111112))
      
      angle\_m = abs(angle)
      angle\_s = copysign(1.0, angle)
      function code(angle_s, a, b, angle_m)
      	return Float64(angle_s * Float64(Float64(a * a) * Float64(Float64(angle_m * pi) * -0.011111111111111112)))
      end
      
      angle\_m = abs(angle);
      angle\_s = sign(angle) * abs(1.0);
      function tmp = code(angle_s, a, b, angle_m)
      	tmp = angle_s * ((a * a) * ((angle_m * pi) * -0.011111111111111112));
      end
      
      angle\_m = N[Abs[angle], $MachinePrecision]
      angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
      code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * N[(N[(a * a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * -0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
      
      \begin{array}{l}
      angle\_m = \left|angle\right|
      \\
      angle\_s = \mathsf{copysign}\left(1, angle\right)
      
      \\
      angle\_s \cdot \left(\left(a \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot -0.011111111111111112\right)\right)
      \end{array}
      
      Derivation
      1. Initial program 54.6%

        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
      2. Step-by-step derivation
        1. associate-*l*N/A

          \[\leadsto \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
        2. *-commutativeN/A

          \[\leadsto \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
        3. associate-*l*N/A

          \[\leadsto \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right), \color{blue}{\left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)}\right) \]
        5. sin-lowering-sin.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right), \left(\color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        6. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        7. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{PI}\left(\right) \cdot angle\right), 180\right)\right), \left(\cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        9. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)\right) \]
        10. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
        11. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{sin.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), angle\right), 180\right)\right), \mathsf{*.f64}\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right), \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
      3. Simplified54.7%

        \[\leadsto \color{blue}{\sin \left(\frac{\pi \cdot angle}{180}\right) \cdot \left(\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \cos \left(\frac{\pi \cdot angle}{180}\right)\right)} \]
      4. Add Preprocessing
      5. Taylor expanded in angle around 0

        \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
      6. Step-by-step derivation
        1. associate-*r*N/A

          \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
        2. associate-*r*N/A

          \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)} \]
        3. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \left(angle \cdot \mathsf{PI}\left(\right)\right)\right), \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \]
        5. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right)\right), \left({b}^{\color{blue}{2}} - {a}^{2}\right)\right) \]
        6. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \left({b}^{2} - {a}^{2}\right)\right) \]
        7. --lowering--.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left({b}^{2}\right), \color{blue}{\left({a}^{2}\right)}\right)\right) \]
        8. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\left(b \cdot b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
        9. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left({\color{blue}{a}}^{2}\right)\right)\right) \]
        10. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \left(a \cdot \color{blue}{a}\right)\right)\right) \]
        11. *-lowering-*.f6451.4%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
      7. Simplified51.4%

        \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(b \cdot b - a \cdot a\right)} \]
      8. Taylor expanded in b around 0

        \[\leadsto \color{blue}{\frac{-1}{90} \cdot \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
      9. Step-by-step derivation
        1. *-commutativeN/A

          \[\leadsto \left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\frac{-1}{90}} \]
        2. associate-*r*N/A

          \[\leadsto {a}^{2} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{-1}{90}\right)} \]
        3. *-commutativeN/A

          \[\leadsto {a}^{2} \cdot \left(\frac{-1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left({a}^{2}\right), \color{blue}{\left(\frac{-1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
        5. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\left(a \cdot a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
        6. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\color{blue}{\frac{-1}{90}} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
        7. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\frac{-1}{90}}\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\left(angle \cdot \mathsf{PI}\left(\right)\right), \color{blue}{\frac{-1}{90}}\right)\right) \]
        9. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI}\left(\right)\right), \frac{-1}{90}\right)\right) \]
        10. PI-lowering-PI.f6431.0%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, a\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{PI.f64}\left(\right)\right), \frac{-1}{90}\right)\right) \]
      10. Simplified31.0%

        \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot -0.011111111111111112\right)} \]
      11. Add Preprocessing

      Reproduce

      ?
      herbie shell --seed 2024148 
      (FPCore (a b angle)
        :name "ab-angle->ABCF B"
        :precision binary64
        (* (* (* 2.0 (- (pow b 2.0) (pow a 2.0))) (sin (* PI (/ angle 180.0)))) (cos (* PI (/ angle 180.0)))))