ab-angle->ABCF B

Percentage Accurate: 53.4% → 66.8%
Time: 18.1s
Alternatives: 12
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 12 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.4% 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: 66.8% accurate, 1.0× speedup?

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

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


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

    1. Initial program 50.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. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutativeN/A

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

        \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      3. pow2N/A

        \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      4. associate-*r*N/A

        \[\leadsto \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) \cdot \cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \]
      5. associate-*r/N/A

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

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

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

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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)} \]
      9. difference-of-squaresN/A

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
      10. associate-*l*N/A

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
    4. Applied egg-rr64.1%

      \[\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)} \]
    5. 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.f6468.3%

        \[\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) \]
    6. Applied egg-rr68.3%

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

    if 4.9999999999999998e195 < (/.f64 angle #s(literal 180 binary64))

    1. Initial program 26.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. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutativeN/A

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

        \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      3. pow2N/A

        \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      4. associate-*r*N/A

        \[\leadsto \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) \cdot \cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \]
      5. associate-*r/N/A

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

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

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

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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)} \]
      9. difference-of-squaresN/A

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
      10. associate-*l*N/A

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
    4. Applied egg-rr31.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)} \]
    5. 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{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{180}{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{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(\sqrt{\mathsf{PI}\left(\right)} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{180}{angle}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      3. *-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(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{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{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{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{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(\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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{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(\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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{180}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      7. 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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\frac{180}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      8. 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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{180}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      9. /-lowering-/.f6432.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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
    6. Applied egg-rr32.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(\sqrt{\pi} \cdot \frac{\sqrt{\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(\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{180}{angle}}\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{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      3. 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{\mathsf{PI}\left(\right)}{180} \cdot angle\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      4. 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(\mathsf{PI}\left(\right)\right)}{\mathsf{neg}\left(180\right)} \cdot angle\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      5. 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(\left(\left(\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)\right) \cdot \frac{1}{\mathsf{neg}\left(180\right)}\right) \cdot angle\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      6. 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(\left(\left(\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)\right) \cdot \frac{1}{-180}\right) \cdot angle\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      7. 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(\left(\left(\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)\right) \cdot \frac{-1}{180}\right) \cdot angle\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(\left(\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)\right) \cdot \left(\frac{-1}{180} \cdot angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      9. *-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(\left(\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      10. sub0-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(\left(0 - \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      11. flip--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{0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)}{0 + \mathsf{PI}\left(\right)} \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      12. +-lft-identityN/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{0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)}{\mathsf{PI}\left(\right)} \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      13. associate-*l/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{\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)}{\mathsf{PI}\left(\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      14. 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{1}{\frac{\mathsf{PI}\left(\right)}{\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\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(1, \left(\frac{\mathsf{PI}\left(\right)}{\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      16. /-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(1, \mathsf{/.f64}\left(\mathsf{PI}\left(\right), \left(\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      17. 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(1, \mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \left(\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      18. *-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(1, \mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right), \left(angle \cdot \frac{-1}{180}\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
    8. Applied egg-rr47.1%

      \[\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{1}{\frac{\pi}{\left(0 - \pi \cdot \pi\right) \cdot \left(angle \cdot -0.005555555555555556\right)}}\right)} \cdot \left(b - a\right)\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification66.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 5 \cdot 10^{+195}:\\ \;\;\;\;\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{\pi}{\frac{180}{angle}}\right) \cdot \left(b - a\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{-1}{\frac{\pi}{\left(\pi \cdot \pi\right) \cdot \left(angle \cdot -0.005555555555555556\right)}}\right)\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 65.4% accurate, 1.8× speedup?

\[\begin{array}{l} b_m = \left|b\right| \\ 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 40000000000:\\ \;\;\;\;\left(b\_m - a\right) \cdot \left(\left(b\_m + a\right) \cdot \sin \left(0.011111111111111112 \cdot \left(angle\_m \cdot \pi\right)\right)\right)\\ \mathbf{elif}\;\frac{angle\_m}{180} \leq 2 \cdot 10^{+89}:\\ \;\;\;\;\left(2 \cdot \left(b\_m \cdot b\_m - a \cdot a\right)\right) \cdot \sin \left(\frac{\sqrt[3]{\pi \cdot \left(\pi \cdot \pi\right)}}{\frac{180}{angle\_m}}\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b\_m + a\right) \cdot \left(\pi \cdot \left(b\_m - a\right)\right)\right) \cdot \left(angle\_m \cdot 0.011111111111111112\right)\\ \end{array} \end{array} \]
b_m = (fabs.f64 b)
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a b_m angle_m)
 :precision binary64
 (*
  angle_s
  (if (<= (/ angle_m 180.0) 40000000000.0)
    (* (- b_m a) (* (+ b_m a) (sin (* 0.011111111111111112 (* angle_m PI)))))
    (if (<= (/ angle_m 180.0) 2e+89)
      (*
       (* 2.0 (- (* b_m b_m) (* a a)))
       (sin (/ (cbrt (* PI (* PI PI))) (/ 180.0 angle_m))))
      (* (* (+ b_m a) (* PI (- b_m a))) (* angle_m 0.011111111111111112))))))
b_m = fabs(b);
angle\_m = fabs(angle);
angle\_s = copysign(1.0, angle);
double code(double angle_s, double a, double b_m, double angle_m) {
	double tmp;
	if ((angle_m / 180.0) <= 40000000000.0) {
		tmp = (b_m - a) * ((b_m + a) * sin((0.011111111111111112 * (angle_m * ((double) M_PI)))));
	} else if ((angle_m / 180.0) <= 2e+89) {
		tmp = (2.0 * ((b_m * b_m) - (a * a))) * sin((cbrt((((double) M_PI) * (((double) M_PI) * ((double) M_PI)))) / (180.0 / angle_m)));
	} else {
		tmp = ((b_m + a) * (((double) M_PI) * (b_m - a))) * (angle_m * 0.011111111111111112);
	}
	return angle_s * tmp;
}
b_m = Math.abs(b);
angle\_m = Math.abs(angle);
angle\_s = Math.copySign(1.0, angle);
public static double code(double angle_s, double a, double b_m, double angle_m) {
	double tmp;
	if ((angle_m / 180.0) <= 40000000000.0) {
		tmp = (b_m - a) * ((b_m + a) * Math.sin((0.011111111111111112 * (angle_m * Math.PI))));
	} else if ((angle_m / 180.0) <= 2e+89) {
		tmp = (2.0 * ((b_m * b_m) - (a * a))) * Math.sin((Math.cbrt((Math.PI * (Math.PI * Math.PI))) / (180.0 / angle_m)));
	} else {
		tmp = ((b_m + a) * (Math.PI * (b_m - a))) * (angle_m * 0.011111111111111112);
	}
	return angle_s * tmp;
}
b_m = abs(b)
angle\_m = abs(angle)
angle\_s = copysign(1.0, angle)
function code(angle_s, a, b_m, angle_m)
	tmp = 0.0
	if (Float64(angle_m / 180.0) <= 40000000000.0)
		tmp = Float64(Float64(b_m - a) * Float64(Float64(b_m + a) * sin(Float64(0.011111111111111112 * Float64(angle_m * pi)))));
	elseif (Float64(angle_m / 180.0) <= 2e+89)
		tmp = Float64(Float64(2.0 * Float64(Float64(b_m * b_m) - Float64(a * a))) * sin(Float64(cbrt(Float64(pi * Float64(pi * pi))) / Float64(180.0 / angle_m))));
	else
		tmp = Float64(Float64(Float64(b_m + a) * Float64(pi * Float64(b_m - a))) * Float64(angle_m * 0.011111111111111112));
	end
	return Float64(angle_s * tmp)
end
b_m = N[Abs[b], $MachinePrecision]
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$95$m_, angle$95$m_] := N[(angle$95$s * If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 40000000000.0], N[(N[(b$95$m - a), $MachinePrecision] * N[(N[(b$95$m + a), $MachinePrecision] * N[Sin[N[(0.011111111111111112 * N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 2e+89], N[(N[(2.0 * N[(N[(b$95$m * b$95$m), $MachinePrecision] - N[(a * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sin[N[(N[Power[N[(Pi * N[(Pi * Pi), $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision] / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[(N[(b$95$m + a), $MachinePrecision] * N[(Pi * N[(b$95$m - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(angle$95$m * 0.011111111111111112), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
b_m = \left|b\right|
\\
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 40000000000:\\
\;\;\;\;\left(b\_m - a\right) \cdot \left(\left(b\_m + a\right) \cdot \sin \left(0.011111111111111112 \cdot \left(angle\_m \cdot \pi\right)\right)\right)\\

\mathbf{elif}\;\frac{angle\_m}{180} \leq 2 \cdot 10^{+89}:\\
\;\;\;\;\left(2 \cdot \left(b\_m \cdot b\_m - a \cdot a\right)\right) \cdot \sin \left(\frac{\sqrt[3]{\pi \cdot \left(\pi \cdot \pi\right)}}{\frac{180}{angle\_m}}\right)\\

\mathbf{else}:\\
\;\;\;\;\left(\left(b\_m + a\right) \cdot \left(\pi \cdot \left(b\_m - a\right)\right)\right) \cdot \left(angle\_m \cdot 0.011111111111111112\right)\\


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

    1. Initial program 57.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 \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
      2. associate-*r/N/A

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

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

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

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

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

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

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

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

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

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

    if 4e10 < (/.f64 angle #s(literal 180 binary64)) < 1.99999999999999999e89

    1. Initial program 21.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. associate-*r/N/A

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

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

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

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

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

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

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

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right), \mathsf{sin.f64}\left(\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), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), 1\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right), \mathsf{sin.f64}\left(\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), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), 1\right) \]
        5. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right), \mathsf{sin.f64}\left(\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), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), 1\right) \]
        6. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right), \mathsf{sin.f64}\left(\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), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), 1\right) \]
        7. PI-lowering-PI.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right), \mathsf{sin.f64}\left(\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), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), 1\right) \]
        8. PI-lowering-PI.f6442.8%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, \mathsf{\_.f64}\left(\mathsf{*.f64}\left(b, b\right), \mathsf{*.f64}\left(a, a\right)\right)\right), \mathsf{sin.f64}\left(\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), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), 1\right) \]
      3. Applied egg-rr42.8%

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

      if 1.99999999999999999e89 < (/.f64 angle #s(literal 180 binary64))

      1. Initial program 22.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. Add Preprocessing
      3. 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)} \]
      4. Step-by-step derivation
        1. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \pi\right)\right)} \cdot \left(angle \cdot 0.011111111111111112\right) \]
    7. Recombined 3 regimes into one program.
    8. Final simplification64.0%

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

    Alternative 3: 66.6% accurate, 1.8× speedup?

    \[\begin{array}{l} b_m = \left|b\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;b\_m \leq 9 \cdot 10^{+197}:\\ \;\;\;\;\left(\left(b\_m + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)\right) \cdot \left(\left(b\_m - a\right) \cdot \cos \left(\left(\pi \cdot \pi\right) \cdot \frac{-1}{\pi \cdot \frac{-180}{angle\_m}}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b\_m - a\right) \cdot \left(angle\_m \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(b\_m + a\right)\right)\right)\right)\\ \end{array} \end{array} \]
    b_m = (fabs.f64 b)
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a b_m angle_m)
     :precision binary64
     (*
      angle_s
      (if (<= b_m 9e+197)
        (*
         (* (+ b_m a) (* 2.0 (sin (/ PI (/ 180.0 angle_m)))))
         (* (- b_m a) (cos (* (* PI PI) (/ -1.0 (* PI (/ -180.0 angle_m)))))))
        (* (- b_m a) (* angle_m (* 0.011111111111111112 (* PI (+ b_m a))))))))
    b_m = fabs(b);
    angle\_m = fabs(angle);
    angle\_s = copysign(1.0, angle);
    double code(double angle_s, double a, double b_m, double angle_m) {
    	double tmp;
    	if (b_m <= 9e+197) {
    		tmp = ((b_m + a) * (2.0 * sin((((double) M_PI) / (180.0 / angle_m))))) * ((b_m - a) * cos(((((double) M_PI) * ((double) M_PI)) * (-1.0 / (((double) M_PI) * (-180.0 / angle_m))))));
    	} else {
    		tmp = (b_m - a) * (angle_m * (0.011111111111111112 * (((double) M_PI) * (b_m + a))));
    	}
    	return angle_s * tmp;
    }
    
    b_m = Math.abs(b);
    angle\_m = Math.abs(angle);
    angle\_s = Math.copySign(1.0, angle);
    public static double code(double angle_s, double a, double b_m, double angle_m) {
    	double tmp;
    	if (b_m <= 9e+197) {
    		tmp = ((b_m + a) * (2.0 * Math.sin((Math.PI / (180.0 / angle_m))))) * ((b_m - a) * Math.cos(((Math.PI * Math.PI) * (-1.0 / (Math.PI * (-180.0 / angle_m))))));
    	} else {
    		tmp = (b_m - a) * (angle_m * (0.011111111111111112 * (Math.PI * (b_m + a))));
    	}
    	return angle_s * tmp;
    }
    
    b_m = math.fabs(b)
    angle\_m = math.fabs(angle)
    angle\_s = math.copysign(1.0, angle)
    def code(angle_s, a, b_m, angle_m):
    	tmp = 0
    	if b_m <= 9e+197:
    		tmp = ((b_m + a) * (2.0 * math.sin((math.pi / (180.0 / angle_m))))) * ((b_m - a) * math.cos(((math.pi * math.pi) * (-1.0 / (math.pi * (-180.0 / angle_m))))))
    	else:
    		tmp = (b_m - a) * (angle_m * (0.011111111111111112 * (math.pi * (b_m + a))))
    	return angle_s * tmp
    
    b_m = abs(b)
    angle\_m = abs(angle)
    angle\_s = copysign(1.0, angle)
    function code(angle_s, a, b_m, angle_m)
    	tmp = 0.0
    	if (b_m <= 9e+197)
    		tmp = Float64(Float64(Float64(b_m + a) * Float64(2.0 * sin(Float64(pi / Float64(180.0 / angle_m))))) * Float64(Float64(b_m - a) * cos(Float64(Float64(pi * pi) * Float64(-1.0 / Float64(pi * Float64(-180.0 / angle_m)))))));
    	else
    		tmp = Float64(Float64(b_m - a) * Float64(angle_m * Float64(0.011111111111111112 * Float64(pi * Float64(b_m + a)))));
    	end
    	return Float64(angle_s * tmp)
    end
    
    b_m = abs(b);
    angle\_m = abs(angle);
    angle\_s = sign(angle) * abs(1.0);
    function tmp_2 = code(angle_s, a, b_m, angle_m)
    	tmp = 0.0;
    	if (b_m <= 9e+197)
    		tmp = ((b_m + a) * (2.0 * sin((pi / (180.0 / angle_m))))) * ((b_m - a) * cos(((pi * pi) * (-1.0 / (pi * (-180.0 / angle_m))))));
    	else
    		tmp = (b_m - a) * (angle_m * (0.011111111111111112 * (pi * (b_m + a))));
    	end
    	tmp_2 = angle_s * tmp;
    end
    
    b_m = N[Abs[b], $MachinePrecision]
    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$95$m_, angle$95$m_] := N[(angle$95$s * If[LessEqual[b$95$m, 9e+197], N[(N[(N[(b$95$m + a), $MachinePrecision] * N[(2.0 * N[Sin[N[(Pi / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(b$95$m - a), $MachinePrecision] * N[Cos[N[(N[(Pi * Pi), $MachinePrecision] * N[(-1.0 / N[(Pi * N[(-180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b$95$m - a), $MachinePrecision] * N[(angle$95$m * N[(0.011111111111111112 * N[(Pi * N[(b$95$m + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
    
    \begin{array}{l}
    b_m = \left|b\right|
    \\
    angle\_m = \left|angle\right|
    \\
    angle\_s = \mathsf{copysign}\left(1, angle\right)
    
    \\
    angle\_s \cdot \begin{array}{l}
    \mathbf{if}\;b\_m \leq 9 \cdot 10^{+197}:\\
    \;\;\;\;\left(\left(b\_m + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)\right) \cdot \left(\left(b\_m - a\right) \cdot \cos \left(\left(\pi \cdot \pi\right) \cdot \frac{-1}{\pi \cdot \frac{-180}{angle\_m}}\right)\right)\\
    
    \mathbf{else}:\\
    \;\;\;\;\left(b\_m - a\right) \cdot \left(angle\_m \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(b\_m + a\right)\right)\right)\right)\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if b < 9.0000000000000006e197

      1. Initial program 50.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. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutativeN/A

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

          \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
        3. pow2N/A

          \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
        4. associate-*r*N/A

          \[\leadsto \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) \cdot \cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \]
        5. associate-*r/N/A

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

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

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

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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)} \]
        9. difference-of-squaresN/A

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
        10. associate-*l*N/A

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
      4. Applied egg-rr61.1%

        \[\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)} \]
      5. 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{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{180}{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{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(\sqrt{\mathsf{PI}\left(\right)} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{180}{angle}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        3. *-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(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{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{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{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{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(\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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{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(\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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{180}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        7. 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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\frac{180}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. 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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{180}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        9. /-lowering-/.f6463.9%

          \[\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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      6. Applied egg-rr63.9%

        \[\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(\sqrt{\pi} \cdot \frac{\sqrt{\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(\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{180}{angle}}\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{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\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{\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)}{\mathsf{neg}\left(\frac{180}{angle}\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        4. sub0-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{0 - \mathsf{PI}\left(\right)}{\mathsf{neg}\left(\frac{180}{angle}\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        5. flip--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{0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)}{0 + \mathsf{PI}\left(\right)}}{\mathsf{neg}\left(\frac{180}{angle}\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        6. +-lft-identityN/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{0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)}{\mathsf{PI}\left(\right)}}{\mathsf{neg}\left(\frac{180}{angle}\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        7. associate-/l/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{0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)}{\left(\mathsf{neg}\left(\frac{180}{angle}\right)\right) \cdot \mathsf{PI}\left(\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. 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(\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{1}{\left(\mathsf{neg}\left(\frac{180}{angle}\right)\right) \cdot \mathsf{PI}\left(\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        9. *-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(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right), \left(\frac{1}{\left(\mathsf{neg}\left(\frac{180}{angle}\right)\right) \cdot \mathsf{PI}\left(\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        10. 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(\left(0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right), \left(\frac{1}{\left(\mathsf{neg}\left(\frac{180}{angle}\right)\right) \cdot \mathsf{PI}\left(\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        11. --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(0, \left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)\right), \left(\frac{1}{\left(\mathsf{neg}\left(\frac{180}{angle}\right)\right) \cdot \mathsf{PI}\left(\right)}\right)\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(\mathsf{\_.f64}\left(0, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), \mathsf{PI}\left(\right)\right)\right), \left(\frac{1}{\left(\mathsf{neg}\left(\frac{180}{angle}\right)\right) \cdot \mathsf{PI}\left(\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        13. 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(0, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{PI}\left(\right)\right)\right), \left(\frac{1}{\left(\mathsf{neg}\left(\frac{180}{angle}\right)\right) \cdot \mathsf{PI}\left(\right)}\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(0, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{PI.f64}\left(\right)\right)\right), \left(\frac{1}{\left(\mathsf{neg}\left(\frac{180}{angle}\right)\right) \cdot \mathsf{PI}\left(\right)}\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(0, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{/.f64}\left(1, \left(\left(\mathsf{neg}\left(\frac{180}{angle}\right)\right) \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        16. *-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(0, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{*.f64}\left(\left(\mathsf{neg}\left(\frac{180}{angle}\right)\right), \mathsf{PI}\left(\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        17. distribute-neg-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(\mathsf{*.f64}\left(\mathsf{\_.f64}\left(0, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{*.f64}\left(\left(\frac{\mathsf{neg}\left(180\right)}{angle}\right), \mathsf{PI}\left(\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        18. /-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(0, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\mathsf{neg}\left(180\right)\right), angle\right), \mathsf{PI}\left(\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        19. 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(0, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{*.f64}\left(\mathsf{/.f64}\left(-180, angle\right), \mathsf{PI}\left(\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        20. PI-lowering-PI.f6465.1%

          \[\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(0, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{PI.f64}\left(\right)\right)\right), \mathsf{/.f64}\left(1, \mathsf{*.f64}\left(\mathsf{/.f64}\left(-180, angle\right), \mathsf{PI.f64}\left(\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      8. Applied egg-rr65.1%

        \[\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(\left(0 - \pi \cdot \pi\right) \cdot \frac{1}{\frac{-180}{angle} \cdot \pi}\right)} \cdot \left(b - a\right)\right) \]

      if 9.0000000000000006e197 < b

      1. Initial program 25.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. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutativeN/A

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

          \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
        3. pow2N/A

          \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
        4. associate-*r*N/A

          \[\leadsto \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) \cdot \cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \]
        5. associate-*r/N/A

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

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

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

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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)} \]
        9. difference-of-squaresN/A

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
        10. associate-*l*N/A

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
      4. Applied egg-rr66.6%

        \[\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)} \]
      5. 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. 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}{angle} \cdot 180}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        4. 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}{angle}} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\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{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}{angle}}\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{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(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{1}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        7. 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}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. 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}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        9. /-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)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        10. /-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), 180\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        11. 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), 180\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        12. PI-lowering-PI.f6471.4%

          \[\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) \]
      6. Applied egg-rr71.4%

        \[\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) \]
      7. Taylor expanded in angle around 0

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{+.f64}\left(a, b\right)\right)\right)\right), \left(b - a\right)\right) \]
        12. --lowering--.f6476.0%

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

        \[\leadsto \color{blue}{\left(angle \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(a + b\right)\right)\right)\right) \cdot \left(b - a\right)} \]
    3. Recombined 2 regimes into one program.
    4. Final simplification66.0%

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq 9 \cdot 10^{+197}:\\ \;\;\;\;\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(\left(\pi \cdot \pi\right) \cdot \frac{-1}{\pi \cdot \frac{-180}{angle}}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b - a\right) \cdot \left(angle \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(b + a\right)\right)\right)\right)\\ \end{array} \]
    5. Add Preprocessing

    Alternative 4: 67.1% accurate, 1.8× speedup?

    \[\begin{array}{l} b_m = \left|b\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(\left(b\_m + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)\right) \cdot \left(\left(b\_m - a\right) \cdot \cos \left(\frac{-1}{\frac{\pi}{\left(\pi \cdot \pi\right) \cdot \left(angle\_m \cdot -0.005555555555555556\right)}}\right)\right)\right) \end{array} \]
    b_m = (fabs.f64 b)
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a b_m angle_m)
     :precision binary64
     (*
      angle_s
      (*
       (* (+ b_m a) (* 2.0 (sin (/ PI (/ 180.0 angle_m)))))
       (*
        (- b_m a)
        (cos (/ -1.0 (/ PI (* (* PI PI) (* angle_m -0.005555555555555556)))))))))
    b_m = fabs(b);
    angle\_m = fabs(angle);
    angle\_s = copysign(1.0, angle);
    double code(double angle_s, double a, double b_m, double angle_m) {
    	return angle_s * (((b_m + a) * (2.0 * sin((((double) M_PI) / (180.0 / angle_m))))) * ((b_m - a) * cos((-1.0 / (((double) M_PI) / ((((double) M_PI) * ((double) M_PI)) * (angle_m * -0.005555555555555556)))))));
    }
    
    b_m = Math.abs(b);
    angle\_m = Math.abs(angle);
    angle\_s = Math.copySign(1.0, angle);
    public static double code(double angle_s, double a, double b_m, double angle_m) {
    	return angle_s * (((b_m + a) * (2.0 * Math.sin((Math.PI / (180.0 / angle_m))))) * ((b_m - a) * Math.cos((-1.0 / (Math.PI / ((Math.PI * Math.PI) * (angle_m * -0.005555555555555556)))))));
    }
    
    b_m = math.fabs(b)
    angle\_m = math.fabs(angle)
    angle\_s = math.copysign(1.0, angle)
    def code(angle_s, a, b_m, angle_m):
    	return angle_s * (((b_m + a) * (2.0 * math.sin((math.pi / (180.0 / angle_m))))) * ((b_m - a) * math.cos((-1.0 / (math.pi / ((math.pi * math.pi) * (angle_m * -0.005555555555555556)))))))
    
    b_m = abs(b)
    angle\_m = abs(angle)
    angle\_s = copysign(1.0, angle)
    function code(angle_s, a, b_m, angle_m)
    	return Float64(angle_s * Float64(Float64(Float64(b_m + a) * Float64(2.0 * sin(Float64(pi / Float64(180.0 / angle_m))))) * Float64(Float64(b_m - a) * cos(Float64(-1.0 / Float64(pi / Float64(Float64(pi * pi) * Float64(angle_m * -0.005555555555555556))))))))
    end
    
    b_m = abs(b);
    angle\_m = abs(angle);
    angle\_s = sign(angle) * abs(1.0);
    function tmp = code(angle_s, a, b_m, angle_m)
    	tmp = angle_s * (((b_m + a) * (2.0 * sin((pi / (180.0 / angle_m))))) * ((b_m - a) * cos((-1.0 / (pi / ((pi * pi) * (angle_m * -0.005555555555555556)))))));
    end
    
    b_m = N[Abs[b], $MachinePrecision]
    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$95$m_, angle$95$m_] := N[(angle$95$s * N[(N[(N[(b$95$m + a), $MachinePrecision] * N[(2.0 * N[Sin[N[(Pi / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(b$95$m - a), $MachinePrecision] * N[Cos[N[(-1.0 / N[(Pi / N[(N[(Pi * Pi), $MachinePrecision] * N[(angle$95$m * -0.005555555555555556), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    b_m = \left|b\right|
    \\
    angle\_m = \left|angle\right|
    \\
    angle\_s = \mathsf{copysign}\left(1, angle\right)
    
    \\
    angle\_s \cdot \left(\left(\left(b\_m + a\right) \cdot \left(2 \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)\right) \cdot \left(\left(b\_m - a\right) \cdot \cos \left(\frac{-1}{\frac{\pi}{\left(\pi \cdot \pi\right) \cdot \left(angle\_m \cdot -0.005555555555555556\right)}}\right)\right)\right)
    \end{array}
    
    Derivation
    1. Initial program 48.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. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutativeN/A

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

        \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      3. pow2N/A

        \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      4. associate-*r*N/A

        \[\leadsto \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) \cdot \cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \]
      5. associate-*r/N/A

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

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

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

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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)} \]
      9. difference-of-squaresN/A

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
      10. associate-*l*N/A

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
    4. Applied egg-rr61.6%

      \[\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)} \]
    5. 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{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{180}{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{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(\sqrt{\mathsf{PI}\left(\right)} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{180}{angle}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      3. *-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(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{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{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{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{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(\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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{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(\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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{180}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      7. 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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI}\left(\right)\right), \left(\frac{180}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      8. 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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \left(\frac{180}{angle}\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      9. /-lowering-/.f6464.9%

        \[\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{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(\mathsf{sqrt.f64}\left(\mathsf{PI.f64}\left(\right)\right), \mathsf{/.f64}\left(180, angle\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
    6. Applied egg-rr64.9%

      \[\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(\sqrt{\pi} \cdot \frac{\sqrt{\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(\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{180}{angle}}\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{\mathsf{PI}\left(\right)}{\frac{180}{angle}}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      3. 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{\mathsf{PI}\left(\right)}{180} \cdot angle\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      4. 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(\mathsf{PI}\left(\right)\right)}{\mathsf{neg}\left(180\right)} \cdot angle\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      5. 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(\left(\left(\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)\right) \cdot \frac{1}{\mathsf{neg}\left(180\right)}\right) \cdot angle\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      6. 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(\left(\left(\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)\right) \cdot \frac{1}{-180}\right) \cdot angle\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      7. 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(\left(\left(\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)\right) \cdot \frac{-1}{180}\right) \cdot angle\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(\left(\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)\right) \cdot \left(\frac{-1}{180} \cdot angle\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      9. *-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(\left(\mathsf{neg}\left(\mathsf{PI}\left(\right)\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      10. sub0-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(\left(0 - \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      11. flip--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{0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)}{0 + \mathsf{PI}\left(\right)} \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      12. +-lft-identityN/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{0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)}{\mathsf{PI}\left(\right)} \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      13. associate-*l/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{\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)}{\mathsf{PI}\left(\right)}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      14. 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{1}{\frac{\mathsf{PI}\left(\right)}{\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\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(1, \left(\frac{\mathsf{PI}\left(\right)}{\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      16. /-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(1, \mathsf{/.f64}\left(\mathsf{PI}\left(\right), \left(\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      17. 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(1, \mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \left(\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(angle \cdot \frac{-1}{180}\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      18. *-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(1, \mathsf{/.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(\left(0 \cdot 0 - \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right), \left(angle \cdot \frac{-1}{180}\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
    8. Applied egg-rr66.4%

      \[\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{1}{\frac{\pi}{\left(0 - \pi \cdot \pi\right) \cdot \left(angle \cdot -0.005555555555555556\right)}}\right)} \cdot \left(b - a\right)\right) \]
    9. Final simplification66.4%

      \[\leadsto \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{-1}{\frac{\pi}{\left(\pi \cdot \pi\right) \cdot \left(angle \cdot -0.005555555555555556\right)}}\right)\right) \]
    10. Add Preprocessing

    Alternative 5: 65.6% accurate, 3.5× speedup?

    \[\begin{array}{l} b_m = \left|b\right| \\ 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 2 \cdot 10^{+44}:\\ \;\;\;\;\left(b\_m - a\right) \cdot \left(\left(b\_m + a\right) \cdot \sin \left(0.011111111111111112 \cdot \left(angle\_m \cdot \pi\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b\_m + a\right) \cdot \left(\pi \cdot \left(b\_m - a\right)\right)\right) \cdot \left(angle\_m \cdot 0.011111111111111112\right)\\ \end{array} \end{array} \]
    b_m = (fabs.f64 b)
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a b_m angle_m)
     :precision binary64
     (*
      angle_s
      (if (<= (/ angle_m 180.0) 2e+44)
        (* (- b_m a) (* (+ b_m a) (sin (* 0.011111111111111112 (* angle_m PI)))))
        (* (* (+ b_m a) (* PI (- b_m a))) (* angle_m 0.011111111111111112)))))
    b_m = fabs(b);
    angle\_m = fabs(angle);
    angle\_s = copysign(1.0, angle);
    double code(double angle_s, double a, double b_m, double angle_m) {
    	double tmp;
    	if ((angle_m / 180.0) <= 2e+44) {
    		tmp = (b_m - a) * ((b_m + a) * sin((0.011111111111111112 * (angle_m * ((double) M_PI)))));
    	} else {
    		tmp = ((b_m + a) * (((double) M_PI) * (b_m - a))) * (angle_m * 0.011111111111111112);
    	}
    	return angle_s * tmp;
    }
    
    b_m = Math.abs(b);
    angle\_m = Math.abs(angle);
    angle\_s = Math.copySign(1.0, angle);
    public static double code(double angle_s, double a, double b_m, double angle_m) {
    	double tmp;
    	if ((angle_m / 180.0) <= 2e+44) {
    		tmp = (b_m - a) * ((b_m + a) * Math.sin((0.011111111111111112 * (angle_m * Math.PI))));
    	} else {
    		tmp = ((b_m + a) * (Math.PI * (b_m - a))) * (angle_m * 0.011111111111111112);
    	}
    	return angle_s * tmp;
    }
    
    b_m = math.fabs(b)
    angle\_m = math.fabs(angle)
    angle\_s = math.copysign(1.0, angle)
    def code(angle_s, a, b_m, angle_m):
    	tmp = 0
    	if (angle_m / 180.0) <= 2e+44:
    		tmp = (b_m - a) * ((b_m + a) * math.sin((0.011111111111111112 * (angle_m * math.pi))))
    	else:
    		tmp = ((b_m + a) * (math.pi * (b_m - a))) * (angle_m * 0.011111111111111112)
    	return angle_s * tmp
    
    b_m = abs(b)
    angle\_m = abs(angle)
    angle\_s = copysign(1.0, angle)
    function code(angle_s, a, b_m, angle_m)
    	tmp = 0.0
    	if (Float64(angle_m / 180.0) <= 2e+44)
    		tmp = Float64(Float64(b_m - a) * Float64(Float64(b_m + a) * sin(Float64(0.011111111111111112 * Float64(angle_m * pi)))));
    	else
    		tmp = Float64(Float64(Float64(b_m + a) * Float64(pi * Float64(b_m - a))) * Float64(angle_m * 0.011111111111111112));
    	end
    	return Float64(angle_s * tmp)
    end
    
    b_m = abs(b);
    angle\_m = abs(angle);
    angle\_s = sign(angle) * abs(1.0);
    function tmp_2 = code(angle_s, a, b_m, angle_m)
    	tmp = 0.0;
    	if ((angle_m / 180.0) <= 2e+44)
    		tmp = (b_m - a) * ((b_m + a) * sin((0.011111111111111112 * (angle_m * pi))));
    	else
    		tmp = ((b_m + a) * (pi * (b_m - a))) * (angle_m * 0.011111111111111112);
    	end
    	tmp_2 = angle_s * tmp;
    end
    
    b_m = N[Abs[b], $MachinePrecision]
    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$95$m_, angle$95$m_] := N[(angle$95$s * If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 2e+44], N[(N[(b$95$m - a), $MachinePrecision] * N[(N[(b$95$m + a), $MachinePrecision] * N[Sin[N[(0.011111111111111112 * N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b$95$m + a), $MachinePrecision] * N[(Pi * N[(b$95$m - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(angle$95$m * 0.011111111111111112), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
    
    \begin{array}{l}
    b_m = \left|b\right|
    \\
    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 2 \cdot 10^{+44}:\\
    \;\;\;\;\left(b\_m - a\right) \cdot \left(\left(b\_m + a\right) \cdot \sin \left(0.011111111111111112 \cdot \left(angle\_m \cdot \pi\right)\right)\right)\\
    
    \mathbf{else}:\\
    \;\;\;\;\left(\left(b\_m + a\right) \cdot \left(\pi \cdot \left(b\_m - a\right)\right)\right) \cdot \left(angle\_m \cdot 0.011111111111111112\right)\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if (/.f64 angle #s(literal 180 binary64)) < 2.0000000000000002e44

      1. Initial program 56.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 \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
        2. associate-*r/N/A

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

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

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

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

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

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

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

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

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

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

      if 2.0000000000000002e44 < (/.f64 angle #s(literal 180 binary64))

      1. Initial program 21.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. Add Preprocessing
      3. 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)} \]
      4. Step-by-step derivation
        1. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{+.f64}\left(b, a\right), \mathsf{*.f64}\left(\mathsf{\_.f64}\left(b, a\right), \mathsf{PI}\left(\right)\right)\right), \mathsf{*.f64}\left(angle, \frac{1}{90}\right)\right) \]
        8. PI-lowering-PI.f6428.5%

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

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

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

    Alternative 6: 63.8% accurate, 20.9× speedup?

    \[\begin{array}{l} b_m = \left|b\right| \\ 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 2000:\\ \;\;\;\;\left(b\_m - a\right) \cdot \left(angle\_m \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(b\_m + a\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b\_m + a\right) \cdot \left(\pi \cdot \left(b\_m - a\right)\right)\right) \cdot \left(angle\_m \cdot 0.011111111111111112\right)\\ \end{array} \end{array} \]
    b_m = (fabs.f64 b)
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a b_m angle_m)
     :precision binary64
     (*
      angle_s
      (if (<= (/ angle_m 180.0) 2000.0)
        (* (- b_m a) (* angle_m (* 0.011111111111111112 (* PI (+ b_m a)))))
        (* (* (+ b_m a) (* PI (- b_m a))) (* angle_m 0.011111111111111112)))))
    b_m = fabs(b);
    angle\_m = fabs(angle);
    angle\_s = copysign(1.0, angle);
    double code(double angle_s, double a, double b_m, double angle_m) {
    	double tmp;
    	if ((angle_m / 180.0) <= 2000.0) {
    		tmp = (b_m - a) * (angle_m * (0.011111111111111112 * (((double) M_PI) * (b_m + a))));
    	} else {
    		tmp = ((b_m + a) * (((double) M_PI) * (b_m - a))) * (angle_m * 0.011111111111111112);
    	}
    	return angle_s * tmp;
    }
    
    b_m = Math.abs(b);
    angle\_m = Math.abs(angle);
    angle\_s = Math.copySign(1.0, angle);
    public static double code(double angle_s, double a, double b_m, double angle_m) {
    	double tmp;
    	if ((angle_m / 180.0) <= 2000.0) {
    		tmp = (b_m - a) * (angle_m * (0.011111111111111112 * (Math.PI * (b_m + a))));
    	} else {
    		tmp = ((b_m + a) * (Math.PI * (b_m - a))) * (angle_m * 0.011111111111111112);
    	}
    	return angle_s * tmp;
    }
    
    b_m = math.fabs(b)
    angle\_m = math.fabs(angle)
    angle\_s = math.copysign(1.0, angle)
    def code(angle_s, a, b_m, angle_m):
    	tmp = 0
    	if (angle_m / 180.0) <= 2000.0:
    		tmp = (b_m - a) * (angle_m * (0.011111111111111112 * (math.pi * (b_m + a))))
    	else:
    		tmp = ((b_m + a) * (math.pi * (b_m - a))) * (angle_m * 0.011111111111111112)
    	return angle_s * tmp
    
    b_m = abs(b)
    angle\_m = abs(angle)
    angle\_s = copysign(1.0, angle)
    function code(angle_s, a, b_m, angle_m)
    	tmp = 0.0
    	if (Float64(angle_m / 180.0) <= 2000.0)
    		tmp = Float64(Float64(b_m - a) * Float64(angle_m * Float64(0.011111111111111112 * Float64(pi * Float64(b_m + a)))));
    	else
    		tmp = Float64(Float64(Float64(b_m + a) * Float64(pi * Float64(b_m - a))) * Float64(angle_m * 0.011111111111111112));
    	end
    	return Float64(angle_s * tmp)
    end
    
    b_m = abs(b);
    angle\_m = abs(angle);
    angle\_s = sign(angle) * abs(1.0);
    function tmp_2 = code(angle_s, a, b_m, angle_m)
    	tmp = 0.0;
    	if ((angle_m / 180.0) <= 2000.0)
    		tmp = (b_m - a) * (angle_m * (0.011111111111111112 * (pi * (b_m + a))));
    	else
    		tmp = ((b_m + a) * (pi * (b_m - a))) * (angle_m * 0.011111111111111112);
    	end
    	tmp_2 = angle_s * tmp;
    end
    
    b_m = N[Abs[b], $MachinePrecision]
    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$95$m_, angle$95$m_] := N[(angle$95$s * If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 2000.0], N[(N[(b$95$m - a), $MachinePrecision] * N[(angle$95$m * N[(0.011111111111111112 * N[(Pi * N[(b$95$m + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b$95$m + a), $MachinePrecision] * N[(Pi * N[(b$95$m - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(angle$95$m * 0.011111111111111112), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
    
    \begin{array}{l}
    b_m = \left|b\right|
    \\
    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 2000:\\
    \;\;\;\;\left(b\_m - a\right) \cdot \left(angle\_m \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(b\_m + a\right)\right)\right)\right)\\
    
    \mathbf{else}:\\
    \;\;\;\;\left(\left(b\_m + a\right) \cdot \left(\pi \cdot \left(b\_m - a\right)\right)\right) \cdot \left(angle\_m \cdot 0.011111111111111112\right)\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if (/.f64 angle #s(literal 180 binary64)) < 2e3

      1. Initial program 57.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. Add Preprocessing
      3. Step-by-step derivation
        1. *-commutativeN/A

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

          \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
        3. pow2N/A

          \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
        4. associate-*r*N/A

          \[\leadsto \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) \cdot \cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \]
        5. associate-*r/N/A

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

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

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

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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)} \]
        9. difference-of-squaresN/A

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
        10. associate-*l*N/A

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
      4. Applied egg-rr73.1%

        \[\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)} \]
      5. 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. 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}{angle} \cdot 180}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        4. 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}{angle}} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\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{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}{angle}}\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{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(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{1}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        7. 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}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        8. 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}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        9. /-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)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        10. /-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), 180\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        11. 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), 180\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
        12. PI-lowering-PI.f6475.8%

          \[\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) \]
      6. Applied egg-rr75.8%

        \[\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) \]
      7. Taylor expanded in angle around 0

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{+.f64}\left(a, b\right)\right)\right)\right), \left(b - a\right)\right) \]
        12. --lowering--.f6472.7%

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

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

      if 2e3 < (/.f64 angle #s(literal 180 binary64))

      1. Initial program 23.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. Add Preprocessing
      3. 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)} \]
      4. Step-by-step derivation
        1. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    Alternative 7: 49.9% accurate, 26.2× speedup?

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

      1. Initial program 50.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. Add Preprocessing
      3. 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)} \]
      4. Step-by-step derivation
        1. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\left(\pi \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \left(angle \cdot 0.011111111111111112\right)} \]
      6. 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)} \]
      7. 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.4%

          \[\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) \]
      8. Simplified35.4%

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

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

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

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

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

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

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

          \[\leadsto \mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \frac{-1}{90}\right), \left(a \cdot a\right)\right)\right) \]
        8. *-lowering-*.f6435.4%

          \[\leadsto \mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \frac{-1}{90}\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
      10. Applied egg-rr35.4%

        \[\leadsto \color{blue}{angle \cdot \left(\left(\pi \cdot -0.011111111111111112\right) \cdot \left(a \cdot a\right)\right)} \]
      11. Step-by-step derivation
        1. associate-*r*N/A

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

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

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

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \left(\left(\mathsf{PI}\left(\right) \cdot \frac{-1}{90}\right) \cdot a\right)\right), a\right) \]
        5. associate-*l*N/A

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

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

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \left(\frac{-1}{90} \cdot a\right)\right)\right), a\right) \]
        8. *-lowering-*.f6439.5%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(\frac{-1}{90}, a\right)\right)\right), a\right) \]
      12. Applied egg-rr39.5%

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

      if 0.0040000000000000001 < b

      1. Initial program 39.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 \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)\right) \cdot \cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \]
        2. pow2N/A

          \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
        3. pow2N/A

          \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
        4. associate-*r*N/A

          \[\leadsto \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) \cdot \cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \]
        5. associate-*r/N/A

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

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

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

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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)} \]
        9. difference-of-squaresN/A

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
        10. associate-*l*N/A

          \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
      4. Applied egg-rr61.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)} \]
      5. Taylor expanded in b around inf

        \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(2 \cdot \left(b \cdot \sin \left(\frac{1}{180} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\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. Step-by-step derivation
        1. associate-*r*N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(2 \cdot b\right) \cdot \sin \left(\frac{1}{180} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right), \mathsf{*.f64}\left(\color{blue}{\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. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(2 \cdot b\right), \sin \left(\frac{1}{180} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right), \mathsf{*.f64}\left(\color{blue}{\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. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \sin \left(\frac{1}{180} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right), \mathsf{*.f64}\left(\mathsf{cos.f64}\left(\color{blue}{\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. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \sin \left(\frac{1}{180} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\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. associate-*r*N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \sin \left(\left(\frac{1}{180} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\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. sin-lowering-sin.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \mathsf{sin.f64}\left(\left(\left(\frac{1}{180} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\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. associate-*r*N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \mathsf{sin.f64}\left(\left(\frac{1}{180} \cdot \left(\mathsf{PI}\left(\right) \cdot angle\right)\right)\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. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \mathsf{sin.f64}\left(\left(\frac{1}{180} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\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) \]
        9. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \mathsf{sin.f64}\left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{1}{180}\right)\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. associate-*r*N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \mathsf{sin.f64}\left(\left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{180}\right)\right)\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) \]
        11. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \mathsf{sin.f64}\left(\left(angle \cdot \left(\frac{1}{180} \cdot \mathsf{PI}\left(\right)\right)\right)\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) \]
        12. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \mathsf{sin.f64}\left(\mathsf{*.f64}\left(angle, \left(\frac{1}{180} \cdot \mathsf{PI}\left(\right)\right)\right)\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) \]
        13. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \mathsf{sin.f64}\left(\mathsf{*.f64}\left(angle, \left(\mathsf{PI}\left(\right) \cdot \frac{1}{180}\right)\right)\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) \]
        14. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \mathsf{sin.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), \frac{1}{180}\right)\right)\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) \]
        15. PI-lowering-PI.f6454.1%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(2, b\right), \mathsf{sin.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \frac{1}{180}\right)\right)\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. Simplified54.1%

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

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot angle\right) \cdot \left(b \cdot \left(\pi \cdot \left(b - a\right)\right)\right)} \]
    3. Recombined 2 regimes into one program.
    4. Final simplification41.3%

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq 0.004:\\ \;\;\;\;a \cdot \left(angle \cdot \left(\pi \cdot \left(a \cdot -0.011111111111111112\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(angle \cdot 0.011111111111111112\right) \cdot \left(b \cdot \left(\pi \cdot \left(b - a\right)\right)\right)\\ \end{array} \]
    5. Add Preprocessing

    Alternative 8: 47.8% accurate, 29.9× speedup?

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

      1. Initial program 50.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. Add Preprocessing
      3. 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)} \]
      4. Step-by-step derivation
        1. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\left(\pi \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \left(angle \cdot 0.011111111111111112\right)} \]
      6. 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)} \]
      7. 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.4%

          \[\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) \]
      8. Simplified35.4%

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

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

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

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

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

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

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

          \[\leadsto \mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \frac{-1}{90}\right), \left(a \cdot a\right)\right)\right) \]
        8. *-lowering-*.f6435.4%

          \[\leadsto \mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \frac{-1}{90}\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
      10. Applied egg-rr35.4%

        \[\leadsto \color{blue}{angle \cdot \left(\left(\pi \cdot -0.011111111111111112\right) \cdot \left(a \cdot a\right)\right)} \]
      11. Step-by-step derivation
        1. associate-*r*N/A

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

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

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

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \left(\left(\mathsf{PI}\left(\right) \cdot \frac{-1}{90}\right) \cdot a\right)\right), a\right) \]
        5. associate-*l*N/A

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

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

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \left(\frac{-1}{90} \cdot a\right)\right)\right), a\right) \]
        8. *-lowering-*.f6439.5%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(\frac{-1}{90}, a\right)\right)\right), a\right) \]
      12. Applied egg-rr39.5%

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

      if 0.098000000000000004 < b

      1. Initial program 39.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. 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)} \]
      4. Step-by-step derivation
        1. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\left(\pi \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \left(angle \cdot 0.011111111111111112\right)} \]
      6. Taylor expanded in b around inf

        \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left({b}^{2} \cdot \mathsf{PI}\left(\right)\right)}, \mathsf{*.f64}\left(angle, \frac{1}{90}\right)\right) \]
      7. Step-by-step derivation
        1. *-commutativeN/A

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

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

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

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \left(b \cdot b\right)\right), \mathsf{*.f64}\left(angle, \frac{1}{90}\right)\right) \]
        5. *-lowering-*.f6442.2%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(b, b\right)\right), \mathsf{*.f64}\left(angle, \frac{1}{90}\right)\right) \]
      8. Simplified42.2%

        \[\leadsto \color{blue}{\left(\pi \cdot \left(b \cdot b\right)\right)} \cdot \left(angle \cdot 0.011111111111111112\right) \]
    3. Recombined 2 regimes into one program.
    4. Final simplification40.0%

      \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq 0.098:\\ \;\;\;\;a \cdot \left(angle \cdot \left(\pi \cdot \left(a \cdot -0.011111111111111112\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(angle \cdot 0.011111111111111112\right) \cdot \left(\pi \cdot \left(b \cdot b\right)\right)\\ \end{array} \]
    5. Add Preprocessing

    Alternative 9: 62.2% accurate, 32.2× speedup?

    \[\begin{array}{l} b_m = \left|b\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(b\_m - a\right) \cdot \left(angle\_m \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(b\_m + a\right)\right)\right)\right)\right) \end{array} \]
    b_m = (fabs.f64 b)
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a b_m angle_m)
     :precision binary64
     (*
      angle_s
      (* (- b_m a) (* angle_m (* 0.011111111111111112 (* PI (+ b_m a)))))))
    b_m = fabs(b);
    angle\_m = fabs(angle);
    angle\_s = copysign(1.0, angle);
    double code(double angle_s, double a, double b_m, double angle_m) {
    	return angle_s * ((b_m - a) * (angle_m * (0.011111111111111112 * (((double) M_PI) * (b_m + a)))));
    }
    
    b_m = Math.abs(b);
    angle\_m = Math.abs(angle);
    angle\_s = Math.copySign(1.0, angle);
    public static double code(double angle_s, double a, double b_m, double angle_m) {
    	return angle_s * ((b_m - a) * (angle_m * (0.011111111111111112 * (Math.PI * (b_m + a)))));
    }
    
    b_m = math.fabs(b)
    angle\_m = math.fabs(angle)
    angle\_s = math.copysign(1.0, angle)
    def code(angle_s, a, b_m, angle_m):
    	return angle_s * ((b_m - a) * (angle_m * (0.011111111111111112 * (math.pi * (b_m + a)))))
    
    b_m = abs(b)
    angle\_m = abs(angle)
    angle\_s = copysign(1.0, angle)
    function code(angle_s, a, b_m, angle_m)
    	return Float64(angle_s * Float64(Float64(b_m - a) * Float64(angle_m * Float64(0.011111111111111112 * Float64(pi * Float64(b_m + a))))))
    end
    
    b_m = abs(b);
    angle\_m = abs(angle);
    angle\_s = sign(angle) * abs(1.0);
    function tmp = code(angle_s, a, b_m, angle_m)
    	tmp = angle_s * ((b_m - a) * (angle_m * (0.011111111111111112 * (pi * (b_m + a)))));
    end
    
    b_m = N[Abs[b], $MachinePrecision]
    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$95$m_, angle$95$m_] := N[(angle$95$s * N[(N[(b$95$m - a), $MachinePrecision] * N[(angle$95$m * N[(0.011111111111111112 * N[(Pi * N[(b$95$m + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    b_m = \left|b\right|
    \\
    angle\_m = \left|angle\right|
    \\
    angle\_s = \mathsf{copysign}\left(1, angle\right)
    
    \\
    angle\_s \cdot \left(\left(b\_m - a\right) \cdot \left(angle\_m \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(b\_m + a\right)\right)\right)\right)\right)
    \end{array}
    
    Derivation
    1. Initial program 48.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. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutativeN/A

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

        \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      3. pow2N/A

        \[\leadsto \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) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      4. associate-*r*N/A

        \[\leadsto \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) \cdot \cos \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \]
      5. associate-*r/N/A

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

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

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

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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)} \]
      9. difference-of-squaresN/A

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
      10. associate-*l*N/A

        \[\leadsto \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\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) \]
    4. Applied egg-rr61.6%

      \[\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)} \]
    5. 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. 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}{angle} \cdot 180}\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      4. 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}{angle}} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\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{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}{angle}}\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{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(\mathsf{/.f64}\left(\left(\sqrt{\mathsf{PI}\left(\right)}\right), \left(\frac{1}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      7. 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}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      8. 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}{angle}\right)\right), \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      9. /-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)}}{180}\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      10. /-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), 180\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      11. 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), 180\right)\right)\right), \mathsf{\_.f64}\left(b, a\right)\right)\right) \]
      12. PI-lowering-PI.f6465.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(\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) \]
    6. Applied egg-rr65.7%

      \[\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) \]
    7. Taylor expanded in angle around 0

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\frac{1}{90}, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{+.f64}\left(a, b\right)\right)\right)\right), \left(b - a\right)\right) \]
      12. --lowering--.f6460.9%

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

      \[\leadsto \color{blue}{\left(angle \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(a + b\right)\right)\right)\right) \cdot \left(b - a\right)} \]
    10. Final simplification60.9%

      \[\leadsto \left(b - a\right) \cdot \left(angle \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(b + a\right)\right)\right)\right) \]
    11. Add Preprocessing

    Alternative 10: 37.4% accurate, 46.6× speedup?

    \[\begin{array}{l} b_m = \left|b\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(a \cdot \left(angle\_m \cdot \left(\pi \cdot \left(a \cdot -0.011111111111111112\right)\right)\right)\right) \end{array} \]
    b_m = (fabs.f64 b)
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a b_m angle_m)
     :precision binary64
     (* angle_s (* a (* angle_m (* PI (* a -0.011111111111111112))))))
    b_m = fabs(b);
    angle\_m = fabs(angle);
    angle\_s = copysign(1.0, angle);
    double code(double angle_s, double a, double b_m, double angle_m) {
    	return angle_s * (a * (angle_m * (((double) M_PI) * (a * -0.011111111111111112))));
    }
    
    b_m = Math.abs(b);
    angle\_m = Math.abs(angle);
    angle\_s = Math.copySign(1.0, angle);
    public static double code(double angle_s, double a, double b_m, double angle_m) {
    	return angle_s * (a * (angle_m * (Math.PI * (a * -0.011111111111111112))));
    }
    
    b_m = math.fabs(b)
    angle\_m = math.fabs(angle)
    angle\_s = math.copysign(1.0, angle)
    def code(angle_s, a, b_m, angle_m):
    	return angle_s * (a * (angle_m * (math.pi * (a * -0.011111111111111112))))
    
    b_m = abs(b)
    angle\_m = abs(angle)
    angle\_s = copysign(1.0, angle)
    function code(angle_s, a, b_m, angle_m)
    	return Float64(angle_s * Float64(a * Float64(angle_m * Float64(pi * Float64(a * -0.011111111111111112)))))
    end
    
    b_m = abs(b);
    angle\_m = abs(angle);
    angle\_s = sign(angle) * abs(1.0);
    function tmp = code(angle_s, a, b_m, angle_m)
    	tmp = angle_s * (a * (angle_m * (pi * (a * -0.011111111111111112))));
    end
    
    b_m = N[Abs[b], $MachinePrecision]
    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$95$m_, angle$95$m_] := N[(angle$95$s * N[(a * N[(angle$95$m * N[(Pi * N[(a * -0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    b_m = \left|b\right|
    \\
    angle\_m = \left|angle\right|
    \\
    angle\_s = \mathsf{copysign}\left(1, angle\right)
    
    \\
    angle\_s \cdot \left(a \cdot \left(angle\_m \cdot \left(\pi \cdot \left(a \cdot -0.011111111111111112\right)\right)\right)\right)
    \end{array}
    
    Derivation
    1. Initial program 48.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. Add Preprocessing
    3. 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)} \]
    4. Step-by-step derivation
      1. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\left(\pi \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \left(angle \cdot 0.011111111111111112\right)} \]
    6. 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)} \]
    7. 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.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) \]
    8. Simplified31.5%

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

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

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

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

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

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

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

        \[\leadsto \mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \frac{-1}{90}\right), \left(a \cdot a\right)\right)\right) \]
      8. *-lowering-*.f6431.5%

        \[\leadsto \mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \frac{-1}{90}\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
    10. Applied egg-rr31.5%

      \[\leadsto \color{blue}{angle \cdot \left(\left(\pi \cdot -0.011111111111111112\right) \cdot \left(a \cdot a\right)\right)} \]
    11. Step-by-step derivation
      1. associate-*r*N/A

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

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

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

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \left(\left(\mathsf{PI}\left(\right) \cdot \frac{-1}{90}\right) \cdot a\right)\right), a\right) \]
      5. associate-*l*N/A

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

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

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \left(\frac{-1}{90} \cdot a\right)\right)\right), a\right) \]
      8. *-lowering-*.f6435.4%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \mathsf{*.f64}\left(\frac{-1}{90}, a\right)\right)\right), a\right) \]
    12. Applied egg-rr35.4%

      \[\leadsto \color{blue}{\left(angle \cdot \left(\pi \cdot \left(-0.011111111111111112 \cdot a\right)\right)\right) \cdot a} \]
    13. Final simplification35.4%

      \[\leadsto a \cdot \left(angle \cdot \left(\pi \cdot \left(a \cdot -0.011111111111111112\right)\right)\right) \]
    14. Add Preprocessing

    Alternative 11: 37.4% accurate, 46.6× speedup?

    \[\begin{array}{l} b_m = \left|b\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(a \cdot \left(a \cdot \left(angle\_m \cdot \left(\pi \cdot -0.011111111111111112\right)\right)\right)\right) \end{array} \]
    b_m = (fabs.f64 b)
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a b_m angle_m)
     :precision binary64
     (* angle_s (* a (* a (* angle_m (* PI -0.011111111111111112))))))
    b_m = fabs(b);
    angle\_m = fabs(angle);
    angle\_s = copysign(1.0, angle);
    double code(double angle_s, double a, double b_m, double angle_m) {
    	return angle_s * (a * (a * (angle_m * (((double) M_PI) * -0.011111111111111112))));
    }
    
    b_m = Math.abs(b);
    angle\_m = Math.abs(angle);
    angle\_s = Math.copySign(1.0, angle);
    public static double code(double angle_s, double a, double b_m, double angle_m) {
    	return angle_s * (a * (a * (angle_m * (Math.PI * -0.011111111111111112))));
    }
    
    b_m = math.fabs(b)
    angle\_m = math.fabs(angle)
    angle\_s = math.copysign(1.0, angle)
    def code(angle_s, a, b_m, angle_m):
    	return angle_s * (a * (a * (angle_m * (math.pi * -0.011111111111111112))))
    
    b_m = abs(b)
    angle\_m = abs(angle)
    angle\_s = copysign(1.0, angle)
    function code(angle_s, a, b_m, angle_m)
    	return Float64(angle_s * Float64(a * Float64(a * Float64(angle_m * Float64(pi * -0.011111111111111112)))))
    end
    
    b_m = abs(b);
    angle\_m = abs(angle);
    angle\_s = sign(angle) * abs(1.0);
    function tmp = code(angle_s, a, b_m, angle_m)
    	tmp = angle_s * (a * (a * (angle_m * (pi * -0.011111111111111112))));
    end
    
    b_m = N[Abs[b], $MachinePrecision]
    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$95$m_, angle$95$m_] := N[(angle$95$s * N[(a * N[(a * N[(angle$95$m * N[(Pi * -0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    b_m = \left|b\right|
    \\
    angle\_m = \left|angle\right|
    \\
    angle\_s = \mathsf{copysign}\left(1, angle\right)
    
    \\
    angle\_s \cdot \left(a \cdot \left(a \cdot \left(angle\_m \cdot \left(\pi \cdot -0.011111111111111112\right)\right)\right)\right)
    \end{array}
    
    Derivation
    1. Initial program 48.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. Add Preprocessing
    3. 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)} \]
    4. Step-by-step derivation
      1. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\left(\pi \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \left(angle \cdot 0.011111111111111112\right)} \]
    6. 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)} \]
    7. 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.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) \]
    8. Simplified31.5%

      \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot -0.011111111111111112\right)} \]
    9. 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. associate-*l*N/A

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

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

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{PI}\left(\right), \frac{-1}{90}\right)\right)\right), a\right) \]
      8. PI-lowering-PI.f6435.4%

        \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(a, \mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \frac{-1}{90}\right)\right)\right), a\right) \]
    10. Applied egg-rr35.4%

      \[\leadsto \color{blue}{\left(a \cdot \left(angle \cdot \left(\pi \cdot -0.011111111111111112\right)\right)\right) \cdot a} \]
    11. Final simplification35.4%

      \[\leadsto a \cdot \left(a \cdot \left(angle \cdot \left(\pi \cdot -0.011111111111111112\right)\right)\right) \]
    12. Add Preprocessing

    Alternative 12: 34.2% accurate, 46.6× speedup?

    \[\begin{array}{l} b_m = \left|b\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(angle\_m \cdot \left(\left(a \cdot a\right) \cdot \left(\pi \cdot -0.011111111111111112\right)\right)\right) \end{array} \]
    b_m = (fabs.f64 b)
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a b_m angle_m)
     :precision binary64
     (* angle_s (* angle_m (* (* a a) (* PI -0.011111111111111112)))))
    b_m = fabs(b);
    angle\_m = fabs(angle);
    angle\_s = copysign(1.0, angle);
    double code(double angle_s, double a, double b_m, double angle_m) {
    	return angle_s * (angle_m * ((a * a) * (((double) M_PI) * -0.011111111111111112)));
    }
    
    b_m = Math.abs(b);
    angle\_m = Math.abs(angle);
    angle\_s = Math.copySign(1.0, angle);
    public static double code(double angle_s, double a, double b_m, double angle_m) {
    	return angle_s * (angle_m * ((a * a) * (Math.PI * -0.011111111111111112)));
    }
    
    b_m = math.fabs(b)
    angle\_m = math.fabs(angle)
    angle\_s = math.copysign(1.0, angle)
    def code(angle_s, a, b_m, angle_m):
    	return angle_s * (angle_m * ((a * a) * (math.pi * -0.011111111111111112)))
    
    b_m = abs(b)
    angle\_m = abs(angle)
    angle\_s = copysign(1.0, angle)
    function code(angle_s, a, b_m, angle_m)
    	return Float64(angle_s * Float64(angle_m * Float64(Float64(a * a) * Float64(pi * -0.011111111111111112))))
    end
    
    b_m = abs(b);
    angle\_m = abs(angle);
    angle\_s = sign(angle) * abs(1.0);
    function tmp = code(angle_s, a, b_m, angle_m)
    	tmp = angle_s * (angle_m * ((a * a) * (pi * -0.011111111111111112)));
    end
    
    b_m = N[Abs[b], $MachinePrecision]
    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$95$m_, angle$95$m_] := N[(angle$95$s * N[(angle$95$m * N[(N[(a * a), $MachinePrecision] * N[(Pi * -0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    b_m = \left|b\right|
    \\
    angle\_m = \left|angle\right|
    \\
    angle\_s = \mathsf{copysign}\left(1, angle\right)
    
    \\
    angle\_s \cdot \left(angle\_m \cdot \left(\left(a \cdot a\right) \cdot \left(\pi \cdot -0.011111111111111112\right)\right)\right)
    \end{array}
    
    Derivation
    1. Initial program 48.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. Add Preprocessing
    3. 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)} \]
    4. Step-by-step derivation
      1. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\left(\pi \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \left(angle \cdot 0.011111111111111112\right)} \]
    6. 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)} \]
    7. 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.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) \]
    8. Simplified31.5%

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

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

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

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

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

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

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

        \[\leadsto \mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \frac{-1}{90}\right), \left(a \cdot a\right)\right)\right) \]
      8. *-lowering-*.f6431.5%

        \[\leadsto \mathsf{*.f64}\left(angle, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{PI.f64}\left(\right), \frac{-1}{90}\right), \mathsf{*.f64}\left(a, \color{blue}{a}\right)\right)\right) \]
    10. Applied egg-rr31.5%

      \[\leadsto \color{blue}{angle \cdot \left(\left(\pi \cdot -0.011111111111111112\right) \cdot \left(a \cdot a\right)\right)} \]
    11. Final simplification31.5%

      \[\leadsto angle \cdot \left(\left(a \cdot a\right) \cdot \left(\pi \cdot -0.011111111111111112\right)\right) \]
    12. Add Preprocessing

    Reproduce

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