ab-angle->ABCF B

Percentage Accurate: 55.3% → 67.6%
Time: 16.2s
Alternatives: 21
Speedup: 13.7×

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 21 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: 55.3% accurate, 1.0× speedup?

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

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

Alternative 1: 67.6% accurate, 0.9× speedup?

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

\\
\begin{array}{l}
t_0 := \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle\_m \cdot 0.005555555555555556\right)\right)\right)\right)\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+35}:\\
\;\;\;\;t\_0 \cdot \cos \left(\frac{\sqrt{\pi}}{180} \cdot e^{-\log \left(\frac{1}{angle\_m \cdot \sqrt{\pi}}\right)}\right)\\

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

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

\mathbf{else}:\\
\;\;\;\;t\_0 \cdot \cos \left(e^{-\log \left(\frac{180}{angle\_m \cdot \pi}\right)}\right)\\


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

    1. Initial program 61.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      22. metadata-eval81.8

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot \color{blue}{0.005555555555555556}\right)\right)\right)\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    4. Applied rewrites81.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180} \cdot \frac{\color{blue}{\sqrt{\mathsf{PI}\left(\right)}}}{\frac{1}{angle}}\right) \]
      16. lower-/.f6481.6

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\pi}}{180} \cdot \frac{\sqrt{\pi}}{\color{blue}{\frac{1}{angle}}}\right) \]
    6. Applied rewrites81.6%

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

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

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

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180} \cdot \color{blue}{e^{\log \left(\frac{\frac{1}{angle}}{\sqrt{\mathsf{PI}\left(\right)}}\right) \cdot -1}}\right) \]
      5. lower-exp.f64N/A

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180} \cdot e^{\color{blue}{\log \left(\frac{\frac{1}{angle}}{\sqrt{\mathsf{PI}\left(\right)}}\right) \cdot -1}}\right) \]
      7. lower-log.f64N/A

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180} \cdot e^{\color{blue}{\log \left(\frac{\frac{1}{angle}}{\sqrt{\mathsf{PI}\left(\right)}}\right)} \cdot -1}\right) \]
      8. clear-numN/A

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180} \cdot e^{\log \color{blue}{\left(\frac{1}{\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{angle}}}\right)} \cdot -1}\right) \]
      9. lift-/.f64N/A

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180} \cdot e^{\log \left(\frac{1}{\color{blue}{\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{angle}}}}\right) \cdot -1}\right) \]
      10. lower-/.f6444.7

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\pi}}{180} \cdot e^{\log \color{blue}{\left(\frac{1}{\frac{\sqrt{\pi}}{\frac{1}{angle}}}\right)} \cdot -1}\right) \]
      11. lift-/.f64N/A

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180} \cdot e^{\log \left(\frac{1}{\color{blue}{\frac{\sqrt{\mathsf{PI}\left(\right)}}{\frac{1}{angle}}}}\right) \cdot -1}\right) \]
      12. lift-/.f64N/A

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180} \cdot e^{\log \left(\frac{1}{\color{blue}{\frac{\sqrt{\mathsf{PI}\left(\right)}}{1} \cdot angle}}\right) \cdot -1}\right) \]
      14. /-rgt-identityN/A

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180} \cdot e^{\log \left(\frac{1}{\color{blue}{angle \cdot \sqrt{\mathsf{PI}\left(\right)}}}\right) \cdot -1}\right) \]
      16. lower-*.f6444.7

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\pi}}{180} \cdot e^{\log \left(\frac{1}{\color{blue}{angle \cdot \sqrt{\pi}}}\right) \cdot -1}\right) \]
    8. Applied rewrites44.7%

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

    if 5.00000000000000021e35 < (/.f64 angle #s(literal 180 binary64)) < 9.99999999999999959e87

    1. Initial program 60.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      18. lower-*.f6460.3

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

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

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      22. metadata-eval57.7

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot \color{blue}{0.005555555555555556}\right)\right)\right)\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    4. Applied rewrites57.7%

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

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

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

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

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

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

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

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

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

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

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

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

    if 9.99999999999999959e87 < (/.f64 angle #s(literal 180 binary64)) < 1.00000000000000002e151

    1. Initial program 41.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      22. metadata-eval47.7

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot \color{blue}{0.005555555555555556}\right)\right)\right)\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    4. Applied rewrites47.7%

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

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

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

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

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

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

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\frac{\color{blue}{angle \cdot \mathsf{PI}\left(\right)}}{180}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      8. lower-/.f6446.5

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

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

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\frac{\color{blue}{\mathsf{PI}\left(\right) \cdot angle}}{180}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      11. lower-*.f6446.5

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

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

      \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)\right)\right) \cdot \color{blue}{1} \]
    8. Step-by-step derivation
      1. Applied rewrites65.1%

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

      if 1.00000000000000002e151 < (/.f64 angle #s(literal 180 binary64))

      1. Initial program 40.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
        18. lower-*.f6444.1

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

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

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

          \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
        22. metadata-eval43.3

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{180} \cdot \frac{\color{blue}{\sqrt{\mathsf{PI}\left(\right)}}}{\frac{1}{angle}}\right) \]
        16. lower-/.f6437.6

          \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\pi}}{180} \cdot \frac{\sqrt{\pi}}{\color{blue}{\frac{1}{angle}}}\right) \]
      6. Applied rewrites37.6%

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

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

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

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

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

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

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

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

          \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)} \cdot \color{blue}{\sqrt{\mathsf{PI}\left(\right)}}}{\frac{180}{angle}}\right) \]
        9. rem-square-sqrtN/A

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

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

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

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

          \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\frac{1}{\frac{180}{\color{blue}{\mathsf{PI}\left(\right) \cdot angle}}}\right) \]
        14. inv-powN/A

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

          \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \color{blue}{\left(e^{\log \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right) \cdot -1}\right)} \]
        16. lower-exp.f64N/A

          \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \color{blue}{\left(e^{\log \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right) \cdot -1}\right)} \]
        17. lower-*.f64N/A

          \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(e^{\color{blue}{\log \left(\frac{180}{\mathsf{PI}\left(\right) \cdot angle}\right) \cdot -1}}\right) \]
      8. Applied rewrites55.3%

        \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right)\right)\right)\right) \cdot \cos \color{blue}{\left(e^{\log \left(\frac{180}{\pi \cdot angle}\right) \cdot -1}\right)} \]
    9. Recombined 4 regimes into one program.
    10. Final simplification47.6%

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

    Alternative 2: 66.0% accurate, 0.8× speedup?

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

      1. Initial program 65.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \color{blue}{\mathsf{PI}\left(\right) \cdot \left(b - a\right)}, \frac{-1}{4374000} \cdot \left({angle}^{2} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right)\right) \]
        5. lower-PI.f64N/A

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \color{blue}{\mathsf{PI}\left(\right)} \cdot \left(b - a\right), \frac{-1}{4374000} \cdot \left({angle}^{2} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right)\right) \]
        6. lower--.f64N/A

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

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

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

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \color{blue}{\left(\frac{-1}{4374000} \cdot {angle}^{2}\right)} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right) \]
        10. unpow2N/A

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \color{blue}{\left(angle \cdot angle\right)}\right) \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right) \]
        11. lower-*.f64N/A

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

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot {\mathsf{PI}\left(\right)}^{3}\right)}\right)\right) \]
        13. lower-*.f64N/A

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot {\mathsf{PI}\left(\right)}^{3}\right)}\right)\right) \]
        14. lower--.f64N/A

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\color{blue}{\left(b - a\right)} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right)\right) \]
        15. cube-multN/A

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)\right)}\right)\right)\right) \]
        16. unpow2N/A

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{{\mathsf{PI}\left(\right)}^{2}}\right)\right)\right)\right) \]
        17. lower-*.f64N/A

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot {\mathsf{PI}\left(\right)}^{2}\right)}\right)\right)\right) \]
        18. lower-PI.f64N/A

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot {\mathsf{PI}\left(\right)}^{2}\right)\right)\right)\right) \]
        19. unpow2N/A

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

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)}\right)\right)\right)\right) \]
        21. lower-PI.f64N/A

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right)\right) \]
        22. lower-PI.f6474.2

          \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \pi \cdot \left(b - a\right), \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \color{blue}{\pi}\right)\right)\right)\right)\right) \]
      7. Applied rewrites74.2%

        \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \pi \cdot \left(b - a\right), \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)} \]

      if -5.00000000000000011e-288 < (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64))) < 1.00000000000000002e306

      1. Initial program 71.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \left(b \cdot b\right) \cdot \sin \left(\color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{90}\right) \]
        8. lower-PI.f6470.3

          \[\leadsto \left(b \cdot b\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\pi}\right) \cdot 0.011111111111111112\right) \]
      7. Applied rewrites70.3%

        \[\leadsto \color{blue}{\left(b \cdot b\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)} \]
      8. Step-by-step derivation
        1. Applied rewrites70.8%

          \[\leadsto \left(b \cdot b\right) \cdot \sin \left(\left(\pi \cdot 0.011111111111111112\right) \cdot angle\right) \]

        if 1.00000000000000002e306 < (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))

        1. Initial program 37.9%

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

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

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

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

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

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

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

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

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

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

            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
          12. lower--.f6457.7

            \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
        5. Applied rewrites57.7%

          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
        6. Step-by-step derivation
          1. Applied rewrites80.4%

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

          \[\leadsto \begin{array}{l} \mathbf{if}\;{b}^{2} - {a}^{2} \leq -5 \cdot 10^{-288}:\\ \;\;\;\;\left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \left(b - a\right) \cdot \pi, \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)\\ \mathbf{elif}\;{b}^{2} - {a}^{2} \leq 10^{+306}:\\ \;\;\;\;\sin \left(angle \cdot \left(\pi \cdot 0.011111111111111112\right)\right) \cdot \left(b \cdot b\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{\left(b + a\right) \cdot \left(angle \cdot \left(\pi \cdot 0.011111111111111112\right)\right)}{\frac{1}{b - a}}\\ \end{array} \]
        9. Add Preprocessing

        Alternative 3: 66.0% accurate, 0.8× speedup?

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

          1. Initial program 65.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \color{blue}{\mathsf{PI}\left(\right) \cdot \left(b - a\right)}, \frac{-1}{4374000} \cdot \left({angle}^{2} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right)\right) \]
            5. lower-PI.f64N/A

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \color{blue}{\mathsf{PI}\left(\right)} \cdot \left(b - a\right), \frac{-1}{4374000} \cdot \left({angle}^{2} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right)\right) \]
            6. lower--.f64N/A

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

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

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

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \color{blue}{\left(\frac{-1}{4374000} \cdot {angle}^{2}\right)} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right) \]
            10. unpow2N/A

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \color{blue}{\left(angle \cdot angle\right)}\right) \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right) \]
            11. lower-*.f64N/A

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

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot {\mathsf{PI}\left(\right)}^{3}\right)}\right)\right) \]
            13. lower-*.f64N/A

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot {\mathsf{PI}\left(\right)}^{3}\right)}\right)\right) \]
            14. lower--.f64N/A

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\color{blue}{\left(b - a\right)} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right)\right) \]
            15. cube-multN/A

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)\right)}\right)\right)\right) \]
            16. unpow2N/A

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{{\mathsf{PI}\left(\right)}^{2}}\right)\right)\right)\right) \]
            17. lower-*.f64N/A

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot {\mathsf{PI}\left(\right)}^{2}\right)}\right)\right)\right) \]
            18. lower-PI.f64N/A

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot {\mathsf{PI}\left(\right)}^{2}\right)\right)\right)\right) \]
            19. unpow2N/A

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

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)}\right)\right)\right)\right) \]
            21. lower-PI.f64N/A

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right)\right) \]
            22. lower-PI.f6474.2

              \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \pi \cdot \left(b - a\right), \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \color{blue}{\pi}\right)\right)\right)\right)\right) \]
          7. Applied rewrites74.2%

            \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \pi \cdot \left(b - a\right), \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)} \]

          if -5.00000000000000011e-288 < (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64))) < 1.00000000000000002e306

          1. Initial program 71.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(b \cdot b\right) \cdot \sin \left(\color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{90}\right) \]
            8. lower-PI.f6470.3

              \[\leadsto \left(b \cdot b\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\pi}\right) \cdot 0.011111111111111112\right) \]
          7. Applied rewrites70.3%

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

          if 1.00000000000000002e306 < (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))

          1. Initial program 37.9%

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
            12. lower--.f6457.7

              \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
          5. Applied rewrites57.7%

            \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
          6. Step-by-step derivation
            1. Applied rewrites80.4%

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

            \[\leadsto \begin{array}{l} \mathbf{if}\;{b}^{2} - {a}^{2} \leq -5 \cdot 10^{-288}:\\ \;\;\;\;\left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \left(b - a\right) \cdot \pi, \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)\\ \mathbf{elif}\;{b}^{2} - {a}^{2} \leq 10^{+306}:\\ \;\;\;\;\sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(b \cdot b\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{\left(b + a\right) \cdot \left(angle \cdot \left(\pi \cdot 0.011111111111111112\right)\right)}{\frac{1}{b - a}}\\ \end{array} \]
          9. Add Preprocessing

          Alternative 4: 67.9% accurate, 1.3× speedup?

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

            1. Initial program 58.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
              18. lower-*.f6475.2

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

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

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

                \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
              22. metadata-eval76.0

                \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot \color{blue}{0.005555555555555556}\right)\right)\right)\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
            4. Applied rewrites76.0%

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

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

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

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

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

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

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

                \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\frac{\color{blue}{angle \cdot \mathsf{PI}\left(\right)}}{180}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
              8. lower-/.f6477.3

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

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

                \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\frac{\color{blue}{\mathsf{PI}\left(\right) \cdot angle}}{180}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
              11. lower-*.f6477.3

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\frac{\color{blue}{\frac{{\mathsf{PI}\left(\right)}^{\left(\frac{\frac{1}{2}}{2}\right)}}{\frac{1}{angle}} \cdot \frac{{\mathsf{PI}\left(\right)}^{\left(\frac{\frac{1}{2}}{2}\right)}}{\frac{1}{\sqrt{\mathsf{PI}\left(\right)}}}}}{180}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
            8. Applied rewrites77.7%

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

            if 1e238 < b

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
              12. lower--.f6471.8

                \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
            5. Applied rewrites71.8%

              \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
            6. Step-by-step derivation
              1. Applied rewrites76.1%

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

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

            Alternative 5: 66.0% accurate, 1.3× speedup?

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

              1. Initial program 70.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \left(b + a\right) \cdot \left(\color{blue}{\left(-1 \cdot a\right)} \cdot \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right)\right) \]
              6. Step-by-step derivation
                1. mul-1-negN/A

                  \[\leadsto \left(b + a\right) \cdot \left(\color{blue}{\left(\mathsf{neg}\left(a\right)\right)} \cdot \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right)\right) \]
                2. lower-neg.f6479.0

                  \[\leadsto \left(b + a\right) \cdot \left(\color{blue}{\left(-a\right)} \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)\right) \]
              7. Applied rewrites79.0%

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

              if 0.0 < (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                12. lower--.f6458.2

                  \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
              5. Applied rewrites58.2%

                \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
              6. Step-by-step derivation
                1. Applied rewrites71.6%

                  \[\leadsto \frac{\left(b + a\right) \cdot \left(angle \cdot \left(\pi \cdot 0.011111111111111112\right)\right)}{\color{blue}{\frac{1}{b - a}}} \]
              7. Recombined 2 regimes into one program.
              8. Final simplification74.9%

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

              Alternative 6: 64.2% accurate, 1.4× speedup?

              \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;{b}^{2} - {a}^{2} \leq -5 \cdot 10^{-288}:\\ \;\;\;\;\left(b + a\right) \cdot \left(angle\_m \cdot \mathsf{fma}\left(0.011111111111111112, \left(b - a\right) \cdot \pi, \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle\_m \cdot angle\_m\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot \left(b \cdot \sin \left(\pi \cdot \left(angle\_m \cdot 0.011111111111111112\right)\right)\right)\\ \end{array} \end{array} \]
              angle\_m = (fabs.f64 angle)
              angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
              (FPCore (angle_s a b angle_m)
               :precision binary64
               (*
                angle_s
                (if (<= (- (pow b 2.0) (pow a 2.0)) -5e-288)
                  (*
                   (+ b a)
                   (*
                    angle_m
                    (fma
                     0.011111111111111112
                     (* (- b a) PI)
                     (*
                      (* -2.2862368541380886e-7 (* angle_m angle_m))
                      (* (- b a) (* PI (* PI PI)))))))
                  (* b (* b (sin (* PI (* angle_m 0.011111111111111112))))))))
              angle\_m = fabs(angle);
              angle\_s = copysign(1.0, angle);
              double code(double angle_s, double a, double b, double angle_m) {
              	double tmp;
              	if ((pow(b, 2.0) - pow(a, 2.0)) <= -5e-288) {
              		tmp = (b + a) * (angle_m * fma(0.011111111111111112, ((b - a) * ((double) M_PI)), ((-2.2862368541380886e-7 * (angle_m * angle_m)) * ((b - a) * (((double) M_PI) * (((double) M_PI) * ((double) M_PI)))))));
              	} else {
              		tmp = b * (b * sin((((double) M_PI) * (angle_m * 0.011111111111111112))));
              	}
              	return angle_s * tmp;
              }
              
              angle\_m = abs(angle)
              angle\_s = copysign(1.0, angle)
              function code(angle_s, a, b, angle_m)
              	tmp = 0.0
              	if (Float64((b ^ 2.0) - (a ^ 2.0)) <= -5e-288)
              		tmp = Float64(Float64(b + a) * Float64(angle_m * fma(0.011111111111111112, Float64(Float64(b - a) * pi), Float64(Float64(-2.2862368541380886e-7 * Float64(angle_m * angle_m)) * Float64(Float64(b - a) * Float64(pi * Float64(pi * pi)))))));
              	else
              		tmp = Float64(b * Float64(b * sin(Float64(pi * Float64(angle_m * 0.011111111111111112)))));
              	end
              	return Float64(angle_s * tmp)
              end
              
              angle\_m = N[Abs[angle], $MachinePrecision]
              angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
              code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision], -5e-288], N[(N[(b + a), $MachinePrecision] * N[(angle$95$m * N[(0.011111111111111112 * N[(N[(b - a), $MachinePrecision] * Pi), $MachinePrecision] + N[(N[(-2.2862368541380886e-7 * N[(angle$95$m * angle$95$m), $MachinePrecision]), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[(Pi * N[(Pi * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * N[(b * N[Sin[N[(Pi * N[(angle$95$m * 0.011111111111111112), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
              
              \begin{array}{l}
              angle\_m = \left|angle\right|
              \\
              angle\_s = \mathsf{copysign}\left(1, angle\right)
              
              \\
              angle\_s \cdot \begin{array}{l}
              \mathbf{if}\;{b}^{2} - {a}^{2} \leq -5 \cdot 10^{-288}:\\
              \;\;\;\;\left(b + a\right) \cdot \left(angle\_m \cdot \mathsf{fma}\left(0.011111111111111112, \left(b - a\right) \cdot \pi, \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle\_m \cdot angle\_m\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)\\
              
              \mathbf{else}:\\
              \;\;\;\;b \cdot \left(b \cdot \sin \left(\pi \cdot \left(angle\_m \cdot 0.011111111111111112\right)\right)\right)\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64))) < -5.00000000000000011e-288

                1. Initial program 65.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \color{blue}{\mathsf{PI}\left(\right) \cdot \left(b - a\right)}, \frac{-1}{4374000} \cdot \left({angle}^{2} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right)\right) \]
                  5. lower-PI.f64N/A

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \color{blue}{\mathsf{PI}\left(\right)} \cdot \left(b - a\right), \frac{-1}{4374000} \cdot \left({angle}^{2} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right)\right) \]
                  6. lower--.f64N/A

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

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

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

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \color{blue}{\left(\frac{-1}{4374000} \cdot {angle}^{2}\right)} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right) \]
                  10. unpow2N/A

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \color{blue}{\left(angle \cdot angle\right)}\right) \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right) \]
                  11. lower-*.f64N/A

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

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot {\mathsf{PI}\left(\right)}^{3}\right)}\right)\right) \]
                  13. lower-*.f64N/A

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot {\mathsf{PI}\left(\right)}^{3}\right)}\right)\right) \]
                  14. lower--.f64N/A

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\color{blue}{\left(b - a\right)} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right)\right) \]
                  15. cube-multN/A

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)\right)}\right)\right)\right) \]
                  16. unpow2N/A

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{{\mathsf{PI}\left(\right)}^{2}}\right)\right)\right)\right) \]
                  17. lower-*.f64N/A

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot {\mathsf{PI}\left(\right)}^{2}\right)}\right)\right)\right) \]
                  18. lower-PI.f64N/A

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot {\mathsf{PI}\left(\right)}^{2}\right)\right)\right)\right) \]
                  19. unpow2N/A

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

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)}\right)\right)\right)\right) \]
                  21. lower-PI.f64N/A

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right)\right) \]
                  22. lower-PI.f6474.2

                    \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \pi \cdot \left(b - a\right), \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \color{blue}{\pi}\right)\right)\right)\right)\right) \]
                7. Applied rewrites74.2%

                  \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \pi \cdot \left(b - a\right), \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)} \]

                if -5.00000000000000011e-288 < (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))

                1. Initial program 53.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \left(b \cdot b\right) \cdot \sin \left(\color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{90}\right) \]
                  8. lower-PI.f6461.8

                    \[\leadsto \left(b \cdot b\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\pi}\right) \cdot 0.011111111111111112\right) \]
                7. Applied rewrites61.8%

                  \[\leadsto \color{blue}{\left(b \cdot b\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)} \]
                8. Step-by-step derivation
                  1. Applied rewrites73.9%

                    \[\leadsto \left(b \cdot \sin \left(\pi \cdot \left(angle \cdot 0.011111111111111112\right)\right)\right) \cdot \color{blue}{b} \]
                9. Recombined 2 regimes into one program.
                10. Final simplification74.0%

                  \[\leadsto \begin{array}{l} \mathbf{if}\;{b}^{2} - {a}^{2} \leq -5 \cdot 10^{-288}:\\ \;\;\;\;\left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \left(b - a\right) \cdot \pi, \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot \left(b \cdot \sin \left(\pi \cdot \left(angle \cdot 0.011111111111111112\right)\right)\right)\\ \end{array} \]
                11. Add Preprocessing

                Alternative 7: 68.0% accurate, 1.8× speedup?

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

                  1. Initial program 58.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                    18. lower-*.f6475.2

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

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

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

                      \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                    22. metadata-eval76.0

                      \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot \color{blue}{0.005555555555555556}\right)\right)\right)\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                  4. Applied rewrites76.0%

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

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

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

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

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

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

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

                      \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{180}\right) \]
                    8. lower-*.f6476.7

                      \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right)\right)\right)\right) \cdot \cos \color{blue}{\left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right)} \]
                    9. lift-*.f64N/A

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

                      \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \left(angle \cdot \frac{1}{180}\right)\right)\right)\right)\right) \cdot \cos \left(\color{blue}{\left(\mathsf{PI}\left(\right) \cdot angle\right)} \cdot \frac{1}{180}\right) \]
                    11. lower-*.f6476.7

                      \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right)\right)\right)\right) \cdot \cos \left(\color{blue}{\left(\pi \cdot angle\right)} \cdot 0.005555555555555556\right) \]
                  6. Applied rewrites76.7%

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

                  if 1e238 < b

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                    12. lower--.f6471.8

                      \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                  5. Applied rewrites71.8%

                    \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                  6. Step-by-step derivation
                    1. Applied rewrites76.1%

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

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

                  Alternative 8: 57.7% accurate, 1.9× speedup?

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                      12. lower--.f6464.4

                        \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                    5. Applied rewrites64.4%

                      \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                    6. Step-by-step derivation
                      1. Applied rewrites64.5%

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

                      if 0.0 < (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))

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

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

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

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

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

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

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

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

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

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

                          \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                        12. lower--.f6458.2

                          \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                      5. Applied rewrites58.2%

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

                        \[\leadsto \frac{1}{90} \cdot \color{blue}{\left(angle \cdot \left({b}^{2} \cdot \mathsf{PI}\left(\right)\right)\right)} \]
                      7. Step-by-step derivation
                        1. Applied rewrites57.5%

                          \[\leadsto 0.011111111111111112 \cdot \color{blue}{\left(angle \cdot \left(\pi \cdot \left(b \cdot b\right)\right)\right)} \]
                        2. Step-by-step derivation
                          1. Applied rewrites70.2%

                            \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(b \cdot \pi\right)\right) \cdot b\right) \]
                        3. Recombined 2 regimes into one program.
                        4. Final simplification67.6%

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

                        Alternative 9: 57.7% accurate, 2.0× speedup?

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

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

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

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

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

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

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

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

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

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

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

                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                            12. lower--.f6464.4

                              \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                          5. Applied rewrites64.4%

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

                            \[\leadsto \frac{-1}{90} \cdot \color{blue}{\left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
                          7. Step-by-step derivation
                            1. Applied rewrites64.4%

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

                            if 0.0 < (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))

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

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

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

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

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

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

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

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

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

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

                                \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                              12. lower--.f6458.2

                                \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                            5. Applied rewrites58.2%

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

                              \[\leadsto \frac{1}{90} \cdot \color{blue}{\left(angle \cdot \left({b}^{2} \cdot \mathsf{PI}\left(\right)\right)\right)} \]
                            7. Step-by-step derivation
                              1. Applied rewrites57.5%

                                \[\leadsto 0.011111111111111112 \cdot \color{blue}{\left(angle \cdot \left(\pi \cdot \left(b \cdot b\right)\right)\right)} \]
                              2. Step-by-step derivation
                                1. Applied rewrites70.2%

                                  \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(b \cdot \pi\right)\right) \cdot b\right) \]
                              3. Recombined 2 regimes into one program.
                              4. Final simplification67.5%

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

                              Alternative 10: 67.8% accurate, 3.0× speedup?

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

                                1. Initial program 59.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \sin \color{blue}{\left(\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)}\right) \]
                                  5. remove-double-divN/A

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

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

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

                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \sin \color{blue}{\left(\frac{\frac{1}{90} \cdot \mathsf{PI}\left(\right)}{\frac{1}{angle}}\right)}\right) \]
                                  9. lower-*.f6475.9

                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\frac{\color{blue}{0.011111111111111112 \cdot \pi}}{\frac{1}{angle}}\right)\right) \]
                                6. Applied rewrites75.9%

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

                                if 1.49999999999999993e227 < b

                                1. Initial program 46.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                  18. lower-*.f6479.0

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

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

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

                                    \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                  22. metadata-eval70.6

                                    \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\pi \cdot \left(angle \cdot \color{blue}{0.005555555555555556}\right)\right)\right)\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                                4. Applied rewrites70.6%

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

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

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

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

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

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

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

                                    \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\frac{\color{blue}{angle \cdot \mathsf{PI}\left(\right)}}{180}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                  8. lower-/.f6466.6

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

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

                                    \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\frac{\color{blue}{\mathsf{PI}\left(\right) \cdot angle}}{180}\right)\right)\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                  11. lower-*.f6466.6

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

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

                                  \[\leadsto \left(\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \sin \left(\frac{\mathsf{PI}\left(\right) \cdot angle}{180}\right)\right)\right)\right) \cdot \color{blue}{1} \]
                                8. Step-by-step derivation
                                  1. Applied rewrites83.3%

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

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

                                Alternative 11: 67.9% accurate, 3.0× speedup?

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

                                  1. Initial program 58.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                      \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\color{blue}{\left(\mathsf{PI}\left(\right) \cdot angle\right)} \cdot \frac{1}{90}\right)\right) \]
                                    2. remove-double-divN/A

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

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

                                      \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\color{blue}{\frac{\mathsf{PI}\left(\right)}{\frac{1}{angle}}} \cdot \frac{1}{90}\right)\right) \]
                                    5. lower-/.f6476.3

                                      \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\color{blue}{\frac{\pi}{\frac{1}{angle}}} \cdot 0.011111111111111112\right)\right) \]
                                  6. Applied rewrites76.3%

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

                                  if 1.99999999999999988e237 < b

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

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

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

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

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

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

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

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

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

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

                                      \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                    12. lower--.f6471.8

                                      \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                  5. Applied rewrites71.8%

                                    \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                  6. Step-by-step derivation
                                    1. Applied rewrites76.1%

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

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

                                  Alternative 12: 68.0% accurate, 3.4× speedup?

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

                                    1. Initial program 59.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                        \[\leadsto \color{blue}{\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot \frac{1}{90}\right)\right)} \]
                                      7. lower-*.f6474.7

                                        \[\leadsto \left(b - a\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)\right)} \]
                                      8. lift-*.f64N/A

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

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

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

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

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

                                        \[\leadsto \left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(angle \cdot \frac{1}{90}\right)}\right)\right) \]
                                      14. lower-*.f6475.2

                                        \[\leadsto \left(b - a\right) \cdot \left(\left(b + a\right) \cdot \sin \left(\pi \cdot \color{blue}{\left(angle \cdot 0.011111111111111112\right)}\right)\right) \]
                                    6. Applied rewrites75.2%

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

                                    if 3e262 < b

                                    1. Initial program 43.4%

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

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

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

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

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

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

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

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

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

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

                                        \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                      12. lower--.f6479.1

                                        \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                    5. Applied rewrites79.1%

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

                                      \[\leadsto \frac{1}{90} \cdot \color{blue}{\left(angle \cdot \left({b}^{2} \cdot \mathsf{PI}\left(\right)\right)\right)} \]
                                    7. Step-by-step derivation
                                      1. Applied rewrites79.1%

                                        \[\leadsto 0.011111111111111112 \cdot \color{blue}{\left(angle \cdot \left(\pi \cdot \left(b \cdot b\right)\right)\right)} \]
                                      2. Step-by-step derivation
                                        1. Applied rewrites85.7%

                                          \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(b \cdot \pi\right)\right) \cdot b\right) \]
                                      3. Recombined 2 regimes into one program.
                                      4. Final simplification75.8%

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

                                      Alternative 13: 67.9% accurate, 3.4× speedup?

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

                                        1. Initial program 60.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                        if 1.90000000000000008e118 < b

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

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

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

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

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

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

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

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

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

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

                                            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                          12. lower--.f6462.6

                                            \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                        5. Applied rewrites62.6%

                                          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                        6. Step-by-step derivation
                                          1. Applied rewrites73.8%

                                            \[\leadsto \frac{\left(b + a\right) \cdot \left(angle \cdot \left(\pi \cdot 0.011111111111111112\right)\right)}{\color{blue}{\frac{1}{b - a}}} \]
                                        7. Recombined 2 regimes into one program.
                                        8. Final simplification75.6%

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

                                        Alternative 14: 67.8% accurate, 3.4× speedup?

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

                                          1. Initial program 59.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                              \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \sin \color{blue}{\left(\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)}\right) \]
                                            6. lower-*.f6474.7

                                              \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\color{blue}{\left(0.011111111111111112 \cdot \pi\right)} \cdot angle\right)\right) \]
                                          6. Applied rewrites74.7%

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

                                          if 3.3999999999999998e260 < b

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

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

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

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

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

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

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

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

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

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

                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                            12. lower--.f6475.5

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

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

                                            \[\leadsto \frac{1}{90} \cdot \color{blue}{\left(angle \cdot \left({b}^{2} \cdot \mathsf{PI}\left(\right)\right)\right)} \]
                                          7. Step-by-step derivation
                                            1. Applied rewrites75.5%

                                              \[\leadsto 0.011111111111111112 \cdot \color{blue}{\left(angle \cdot \left(\pi \cdot \left(b \cdot b\right)\right)\right)} \]
                                            2. Step-by-step derivation
                                              1. Applied rewrites81.3%

                                                \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(b \cdot \pi\right)\right) \cdot b\right) \]
                                            3. Recombined 2 regimes into one program.
                                            4. Final simplification75.1%

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

                                            Alternative 15: 64.5% accurate, 5.8× speedup?

                                            \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 0.02:\\ \;\;\;\;\left(b + a\right) \cdot \left(angle\_m \cdot \mathsf{fma}\left(0.011111111111111112, \left(b - a\right) \cdot \pi, \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle\_m \cdot angle\_m\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;0.011111111111111112 \cdot \left(\left(angle\_m \cdot \pi\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right)\\ \end{array} \end{array} \]
                                            angle\_m = (fabs.f64 angle)
                                            angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                            (FPCore (angle_s a b angle_m)
                                             :precision binary64
                                             (*
                                              angle_s
                                              (if (<= (/ angle_m 180.0) 0.02)
                                                (*
                                                 (+ b a)
                                                 (*
                                                  angle_m
                                                  (fma
                                                   0.011111111111111112
                                                   (* (- b a) PI)
                                                   (*
                                                    (* -2.2862368541380886e-7 (* angle_m angle_m))
                                                    (* (- b a) (* PI (* PI PI)))))))
                                                (* 0.011111111111111112 (* (* angle_m PI) (* (+ b a) (- b a)))))))
                                            angle\_m = fabs(angle);
                                            angle\_s = copysign(1.0, angle);
                                            double code(double angle_s, double a, double b, double angle_m) {
                                            	double tmp;
                                            	if ((angle_m / 180.0) <= 0.02) {
                                            		tmp = (b + a) * (angle_m * fma(0.011111111111111112, ((b - a) * ((double) M_PI)), ((-2.2862368541380886e-7 * (angle_m * angle_m)) * ((b - a) * (((double) M_PI) * (((double) M_PI) * ((double) M_PI)))))));
                                            	} else {
                                            		tmp = 0.011111111111111112 * ((angle_m * ((double) M_PI)) * ((b + a) * (b - a)));
                                            	}
                                            	return angle_s * tmp;
                                            }
                                            
                                            angle\_m = abs(angle)
                                            angle\_s = copysign(1.0, angle)
                                            function code(angle_s, a, b, angle_m)
                                            	tmp = 0.0
                                            	if (Float64(angle_m / 180.0) <= 0.02)
                                            		tmp = Float64(Float64(b + a) * Float64(angle_m * fma(0.011111111111111112, Float64(Float64(b - a) * pi), Float64(Float64(-2.2862368541380886e-7 * Float64(angle_m * angle_m)) * Float64(Float64(b - a) * Float64(pi * Float64(pi * pi)))))));
                                            	else
                                            		tmp = Float64(0.011111111111111112 * Float64(Float64(angle_m * pi) * Float64(Float64(b + a) * Float64(b - a))));
                                            	end
                                            	return Float64(angle_s * tmp)
                                            end
                                            
                                            angle\_m = N[Abs[angle], $MachinePrecision]
                                            angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
                                            code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 0.02], N[(N[(b + a), $MachinePrecision] * N[(angle$95$m * N[(0.011111111111111112 * N[(N[(b - a), $MachinePrecision] * Pi), $MachinePrecision] + N[(N[(-2.2862368541380886e-7 * N[(angle$95$m * angle$95$m), $MachinePrecision]), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[(Pi * N[(Pi * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(0.011111111111111112 * N[(N[(angle$95$m * Pi), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
                                            
                                            \begin{array}{l}
                                            angle\_m = \left|angle\right|
                                            \\
                                            angle\_s = \mathsf{copysign}\left(1, angle\right)
                                            
                                            \\
                                            angle\_s \cdot \begin{array}{l}
                                            \mathbf{if}\;\frac{angle\_m}{180} \leq 0.02:\\
                                            \;\;\;\;\left(b + a\right) \cdot \left(angle\_m \cdot \mathsf{fma}\left(0.011111111111111112, \left(b - a\right) \cdot \pi, \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle\_m \cdot angle\_m\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)\\
                                            
                                            \mathbf{else}:\\
                                            \;\;\;\;0.011111111111111112 \cdot \left(\left(angle\_m \cdot \pi\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right)\\
                                            
                                            
                                            \end{array}
                                            \end{array}
                                            
                                            Derivation
                                            1. Split input into 2 regimes
                                            2. if (/.f64 angle #s(literal 180 binary64)) < 0.0200000000000000004

                                              1. Initial program 62.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \color{blue}{\mathsf{PI}\left(\right) \cdot \left(b - a\right)}, \frac{-1}{4374000} \cdot \left({angle}^{2} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right)\right) \]
                                                5. lower-PI.f64N/A

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \color{blue}{\mathsf{PI}\left(\right)} \cdot \left(b - a\right), \frac{-1}{4374000} \cdot \left({angle}^{2} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right)\right) \]
                                                6. lower--.f64N/A

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

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

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

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \color{blue}{\left(\frac{-1}{4374000} \cdot {angle}^{2}\right)} \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right) \]
                                                10. unpow2N/A

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \color{blue}{\left(angle \cdot angle\right)}\right) \cdot \left({\mathsf{PI}\left(\right)}^{3} \cdot \left(b - a\right)\right)\right)\right) \]
                                                11. lower-*.f64N/A

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

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot {\mathsf{PI}\left(\right)}^{3}\right)}\right)\right) \]
                                                13. lower-*.f64N/A

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot {\mathsf{PI}\left(\right)}^{3}\right)}\right)\right) \]
                                                14. lower--.f64N/A

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\color{blue}{\left(b - a\right)} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right)\right) \]
                                                15. cube-multN/A

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)\right)}\right)\right)\right) \]
                                                16. unpow2N/A

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{{\mathsf{PI}\left(\right)}^{2}}\right)\right)\right)\right) \]
                                                17. lower-*.f64N/A

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot {\mathsf{PI}\left(\right)}^{2}\right)}\right)\right)\right) \]
                                                18. lower-PI.f64N/A

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot {\mathsf{PI}\left(\right)}^{2}\right)\right)\right)\right) \]
                                                19. unpow2N/A

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

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)}\right)\right)\right)\right) \]
                                                21. lower-PI.f64N/A

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{1}{90}, \mathsf{PI}\left(\right) \cdot \left(b - a\right), \left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right)\right)\right)\right)\right)\right) \]
                                                22. lower-PI.f6479.4

                                                  \[\leadsto \left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \pi \cdot \left(b - a\right), \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \color{blue}{\pi}\right)\right)\right)\right)\right) \]
                                              7. Applied rewrites79.4%

                                                \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \pi \cdot \left(b - a\right), \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)} \]

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

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

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

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

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

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

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

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

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

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

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

                                                  \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                                12. lower--.f6445.3

                                                  \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                              5. Applied rewrites45.3%

                                                \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                              6. Step-by-step derivation
                                                1. Applied rewrites45.3%

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

                                                \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 0.02:\\ \;\;\;\;\left(b + a\right) \cdot \left(angle \cdot \mathsf{fma}\left(0.011111111111111112, \left(b - a\right) \cdot \pi, \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \left(\left(b - a\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;0.011111111111111112 \cdot \left(\left(angle \cdot \pi\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right)\\ \end{array} \]
                                              9. Add Preprocessing

                                              Alternative 16: 64.8% accurate, 6.5× speedup?

                                              \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 0.02:\\ \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle\_m \cdot \mathsf{fma}\left(-2.2862368541380886 \cdot 10^{-7}, \left(angle\_m \cdot angle\_m\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right), \pi \cdot 0.011111111111111112\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;0.011111111111111112 \cdot \left(\left(angle\_m \cdot \pi\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right)\\ \end{array} \end{array} \]
                                              angle\_m = (fabs.f64 angle)
                                              angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                              (FPCore (angle_s a b angle_m)
                                               :precision binary64
                                               (*
                                                angle_s
                                                (if (<= (/ angle_m 180.0) 0.02)
                                                  (*
                                                   (+ b a)
                                                   (*
                                                    (- b a)
                                                    (*
                                                     angle_m
                                                     (fma
                                                      -2.2862368541380886e-7
                                                      (* (* angle_m angle_m) (* PI (* PI PI)))
                                                      (* PI 0.011111111111111112)))))
                                                  (* 0.011111111111111112 (* (* angle_m PI) (* (+ b a) (- b a)))))))
                                              angle\_m = fabs(angle);
                                              angle\_s = copysign(1.0, angle);
                                              double code(double angle_s, double a, double b, double angle_m) {
                                              	double tmp;
                                              	if ((angle_m / 180.0) <= 0.02) {
                                              		tmp = (b + a) * ((b - a) * (angle_m * fma(-2.2862368541380886e-7, ((angle_m * angle_m) * (((double) M_PI) * (((double) M_PI) * ((double) M_PI)))), (((double) M_PI) * 0.011111111111111112))));
                                              	} else {
                                              		tmp = 0.011111111111111112 * ((angle_m * ((double) M_PI)) * ((b + a) * (b - a)));
                                              	}
                                              	return angle_s * tmp;
                                              }
                                              
                                              angle\_m = abs(angle)
                                              angle\_s = copysign(1.0, angle)
                                              function code(angle_s, a, b, angle_m)
                                              	tmp = 0.0
                                              	if (Float64(angle_m / 180.0) <= 0.02)
                                              		tmp = Float64(Float64(b + a) * Float64(Float64(b - a) * Float64(angle_m * fma(-2.2862368541380886e-7, Float64(Float64(angle_m * angle_m) * Float64(pi * Float64(pi * pi))), Float64(pi * 0.011111111111111112)))));
                                              	else
                                              		tmp = Float64(0.011111111111111112 * Float64(Float64(angle_m * pi) * Float64(Float64(b + a) * Float64(b - a))));
                                              	end
                                              	return Float64(angle_s * tmp)
                                              end
                                              
                                              angle\_m = N[Abs[angle], $MachinePrecision]
                                              angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
                                              code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 0.02], N[(N[(b + a), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[(angle$95$m * N[(-2.2862368541380886e-7 * N[(N[(angle$95$m * angle$95$m), $MachinePrecision] * N[(Pi * N[(Pi * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(Pi * 0.011111111111111112), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(0.011111111111111112 * N[(N[(angle$95$m * Pi), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
                                              
                                              \begin{array}{l}
                                              angle\_m = \left|angle\right|
                                              \\
                                              angle\_s = \mathsf{copysign}\left(1, angle\right)
                                              
                                              \\
                                              angle\_s \cdot \begin{array}{l}
                                              \mathbf{if}\;\frac{angle\_m}{180} \leq 0.02:\\
                                              \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle\_m \cdot \mathsf{fma}\left(-2.2862368541380886 \cdot 10^{-7}, \left(angle\_m \cdot angle\_m\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right), \pi \cdot 0.011111111111111112\right)\right)\right)\\
                                              
                                              \mathbf{else}:\\
                                              \;\;\;\;0.011111111111111112 \cdot \left(\left(angle\_m \cdot \pi\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right)\\
                                              
                                              
                                              \end{array}
                                              \end{array}
                                              
                                              Derivation
                                              1. Split input into 2 regimes
                                              2. if (/.f64 angle #s(literal 180 binary64)) < 0.0200000000000000004

                                                1. Initial program 62.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. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{-1}{4374000}, \color{blue}{{angle}^{2} \cdot {\mathsf{PI}\left(\right)}^{3}}, \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
                                                  4. unpow2N/A

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

                                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{-1}{4374000}, \color{blue}{\left(angle \cdot angle\right)} \cdot {\mathsf{PI}\left(\right)}^{3}, \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
                                                  6. cube-multN/A

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

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

                                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{-1}{4374000}, \left(angle \cdot angle\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot {\mathsf{PI}\left(\right)}^{2}\right)}, \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
                                                  9. lower-PI.f64N/A

                                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{-1}{4374000}, \left(angle \cdot angle\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot {\mathsf{PI}\left(\right)}^{2}\right), \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
                                                  10. unpow2N/A

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

                                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{-1}{4374000}, \left(angle \cdot angle\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)}\right), \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
                                                  12. lower-PI.f64N/A

                                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{-1}{4374000}, \left(angle \cdot angle\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right)\right)\right), \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)\right) \]
                                                  13. lower-PI.f64N/A

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

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

                                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle \cdot \mathsf{fma}\left(\frac{-1}{4374000}, \left(angle \cdot angle\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)\right), \color{blue}{\mathsf{PI}\left(\right) \cdot \frac{1}{90}}\right)\right)\right) \]
                                                  16. lower-PI.f6479.3

                                                    \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle \cdot \mathsf{fma}\left(-2.2862368541380886 \cdot 10^{-7}, \left(angle \cdot angle\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right), \color{blue}{\pi} \cdot 0.011111111111111112\right)\right)\right) \]
                                                7. Applied rewrites79.3%

                                                  \[\leadsto \left(b + a\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(angle \cdot \mathsf{fma}\left(-2.2862368541380886 \cdot 10^{-7}, \left(angle \cdot angle\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right), \pi \cdot 0.011111111111111112\right)\right)}\right) \]

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

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

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

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

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

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

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

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

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

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

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

                                                    \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                                  12. lower--.f6445.3

                                                    \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                                5. Applied rewrites45.3%

                                                  \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                6. Step-by-step derivation
                                                  1. Applied rewrites45.3%

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

                                                  \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 0.02:\\ \;\;\;\;\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(angle \cdot \mathsf{fma}\left(-2.2862368541380886 \cdot 10^{-7}, \left(angle \cdot angle\right) \cdot \left(\pi \cdot \left(\pi \cdot \pi\right)\right), \pi \cdot 0.011111111111111112\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;0.011111111111111112 \cdot \left(\left(angle \cdot \pi\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right)\\ \end{array} \]
                                                9. Add Preprocessing

                                                Alternative 17: 64.5% accurate, 7.4× speedup?

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

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

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

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

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

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

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

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

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

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

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

                                                      \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                                    12. lower--.f6464.5

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

                                                    \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                  6. Step-by-step derivation
                                                    1. Applied rewrites79.1%

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

                                                    if 4.99999999999999964e-35 < (/.f64 angle #s(literal 180 binary64))

                                                    1. Initial program 47.9%

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

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

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

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

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

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

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

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

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

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

                                                        \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                                      12. lower--.f6451.0

                                                        \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                                    5. Applied rewrites51.0%

                                                      \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                    6. Step-by-step derivation
                                                      1. Applied rewrites51.0%

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

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

                                                    Alternative 18: 64.6% accurate, 10.3× speedup?

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

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

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

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

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

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

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

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

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

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

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

                                                          \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                                        12. lower--.f6464.5

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

                                                        \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                      6. Step-by-step derivation
                                                        1. Applied rewrites79.1%

                                                          \[\leadsto \color{blue}{\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(angle \cdot \left(\pi \cdot 0.011111111111111112\right)\right)\right)} \]

                                                        if 4.99999999999999964e-35 < (/.f64 angle #s(literal 180 binary64))

                                                        1. Initial program 47.9%

                                                          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                                                        2. 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 \frac{1}{90} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
                                                          2. associate-*r*N/A

                                                            \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                                          3. lower-*.f64N/A

                                                            \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                                          4. lower-*.f64N/A

                                                            \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                          5. lower-*.f64N/A

                                                            \[\leadsto \left(\frac{1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                          6. lower-PI.f64N/A

                                                            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                          7. unpow2N/A

                                                            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right) \]
                                                          8. unpow2N/A

                                                            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
                                                          9. difference-of-squaresN/A

                                                            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                          10. lower-*.f64N/A

                                                            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                          11. lower-+.f64N/A

                                                            \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                                          12. lower--.f6451.0

                                                            \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                                        5. Applied rewrites51.0%

                                                          \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                        6. Step-by-step derivation
                                                          1. Applied rewrites51.0%

                                                            \[\leadsto \left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \color{blue}{\left(angle \cdot \left(\pi \cdot 0.011111111111111112\right)\right)} \]
                                                        7. Recombined 2 regimes into one program.
                                                        8. Final simplification71.8%

                                                          \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 5 \cdot 10^{-35}:\\ \;\;\;\;\left(b - a\right) \cdot \left(\left(b + a\right) \cdot \left(angle \cdot \left(\pi \cdot 0.011111111111111112\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(angle \cdot \left(\pi \cdot 0.011111111111111112\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\\ \end{array} \]
                                                        9. Add Preprocessing

                                                        Alternative 19: 56.5% accurate, 13.7× speedup?

                                                        \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;b \leq 1.32 \cdot 10^{+156}:\\ \;\;\;\;\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;0.011111111111111112 \cdot \left(b \cdot \left(angle\_m \cdot \left(b \cdot \pi\right)\right)\right)\\ \end{array} \end{array} \]
                                                        angle\_m = (fabs.f64 angle)
                                                        angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                                        (FPCore (angle_s a b angle_m)
                                                         :precision binary64
                                                         (*
                                                          angle_s
                                                          (if (<= b 1.32e+156)
                                                            (* (* (+ b a) (- b a)) (* (* angle_m PI) 0.011111111111111112))
                                                            (* 0.011111111111111112 (* b (* angle_m (* b PI)))))))
                                                        angle\_m = fabs(angle);
                                                        angle\_s = copysign(1.0, angle);
                                                        double code(double angle_s, double a, double b, double angle_m) {
                                                        	double tmp;
                                                        	if (b <= 1.32e+156) {
                                                        		tmp = ((b + a) * (b - a)) * ((angle_m * ((double) M_PI)) * 0.011111111111111112);
                                                        	} else {
                                                        		tmp = 0.011111111111111112 * (b * (angle_m * (b * ((double) M_PI))));
                                                        	}
                                                        	return angle_s * tmp;
                                                        }
                                                        
                                                        angle\_m = Math.abs(angle);
                                                        angle\_s = Math.copySign(1.0, angle);
                                                        public static double code(double angle_s, double a, double b, double angle_m) {
                                                        	double tmp;
                                                        	if (b <= 1.32e+156) {
                                                        		tmp = ((b + a) * (b - a)) * ((angle_m * Math.PI) * 0.011111111111111112);
                                                        	} else {
                                                        		tmp = 0.011111111111111112 * (b * (angle_m * (b * Math.PI)));
                                                        	}
                                                        	return angle_s * tmp;
                                                        }
                                                        
                                                        angle\_m = math.fabs(angle)
                                                        angle\_s = math.copysign(1.0, angle)
                                                        def code(angle_s, a, b, angle_m):
                                                        	tmp = 0
                                                        	if b <= 1.32e+156:
                                                        		tmp = ((b + a) * (b - a)) * ((angle_m * math.pi) * 0.011111111111111112)
                                                        	else:
                                                        		tmp = 0.011111111111111112 * (b * (angle_m * (b * math.pi)))
                                                        	return angle_s * tmp
                                                        
                                                        angle\_m = abs(angle)
                                                        angle\_s = copysign(1.0, angle)
                                                        function code(angle_s, a, b, angle_m)
                                                        	tmp = 0.0
                                                        	if (b <= 1.32e+156)
                                                        		tmp = Float64(Float64(Float64(b + a) * Float64(b - a)) * Float64(Float64(angle_m * pi) * 0.011111111111111112));
                                                        	else
                                                        		tmp = Float64(0.011111111111111112 * Float64(b * Float64(angle_m * Float64(b * pi))));
                                                        	end
                                                        	return Float64(angle_s * tmp)
                                                        end
                                                        
                                                        angle\_m = abs(angle);
                                                        angle\_s = sign(angle) * abs(1.0);
                                                        function tmp_2 = code(angle_s, a, b, angle_m)
                                                        	tmp = 0.0;
                                                        	if (b <= 1.32e+156)
                                                        		tmp = ((b + a) * (b - a)) * ((angle_m * pi) * 0.011111111111111112);
                                                        	else
                                                        		tmp = 0.011111111111111112 * (b * (angle_m * (b * pi)));
                                                        	end
                                                        	tmp_2 = angle_s * tmp;
                                                        end
                                                        
                                                        angle\_m = N[Abs[angle], $MachinePrecision]
                                                        angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
                                                        code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[b, 1.32e+156], N[(N[(N[(b + a), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision], N[(0.011111111111111112 * N[(b * N[(angle$95$m * N[(b * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
                                                        
                                                        \begin{array}{l}
                                                        angle\_m = \left|angle\right|
                                                        \\
                                                        angle\_s = \mathsf{copysign}\left(1, angle\right)
                                                        
                                                        \\
                                                        angle\_s \cdot \begin{array}{l}
                                                        \mathbf{if}\;b \leq 1.32 \cdot 10^{+156}:\\
                                                        \;\;\;\;\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right)\\
                                                        
                                                        \mathbf{else}:\\
                                                        \;\;\;\;0.011111111111111112 \cdot \left(b \cdot \left(angle\_m \cdot \left(b \cdot \pi\right)\right)\right)\\
                                                        
                                                        
                                                        \end{array}
                                                        \end{array}
                                                        
                                                        Derivation
                                                        1. Split input into 2 regimes
                                                        2. if b < 1.3199999999999999e156

                                                          1. Initial program 60.4%

                                                            \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                                                          2. 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 \frac{1}{90} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
                                                            2. associate-*r*N/A

                                                              \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                                            3. lower-*.f64N/A

                                                              \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                                            4. lower-*.f64N/A

                                                              \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                            5. lower-*.f64N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                            6. lower-PI.f64N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                            7. unpow2N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right) \]
                                                            8. unpow2N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
                                                            9. difference-of-squaresN/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                            10. lower-*.f64N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                            11. lower-+.f64N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                                            12. lower--.f6460.9

                                                              \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                                          5. Applied rewrites60.9%

                                                            \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]

                                                          if 1.3199999999999999e156 < b

                                                          1. Initial program 45.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 \frac{1}{90} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
                                                            2. associate-*r*N/A

                                                              \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                                            3. lower-*.f64N/A

                                                              \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                                            4. lower-*.f64N/A

                                                              \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                            5. lower-*.f64N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                            6. lower-PI.f64N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                            7. unpow2N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right) \]
                                                            8. unpow2N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
                                                            9. difference-of-squaresN/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                            10. lower-*.f64N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                            11. lower-+.f64N/A

                                                              \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                                            12. lower--.f6461.6

                                                              \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                                          5. Applied rewrites61.6%

                                                            \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                          6. Taylor expanded in b around inf

                                                            \[\leadsto \frac{1}{90} \cdot \color{blue}{\left(angle \cdot \left({b}^{2} \cdot \mathsf{PI}\left(\right)\right)\right)} \]
                                                          7. Step-by-step derivation
                                                            1. Applied rewrites61.6%

                                                              \[\leadsto 0.011111111111111112 \cdot \color{blue}{\left(angle \cdot \left(\pi \cdot \left(b \cdot b\right)\right)\right)} \]
                                                            2. Step-by-step derivation
                                                              1. Applied rewrites76.2%

                                                                \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(b \cdot \pi\right)\right) \cdot b\right) \]
                                                            3. Recombined 2 regimes into one program.
                                                            4. Final simplification63.2%

                                                              \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq 1.32 \cdot 10^{+156}:\\ \;\;\;\;\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;0.011111111111111112 \cdot \left(b \cdot \left(angle \cdot \left(b \cdot \pi\right)\right)\right)\\ \end{array} \]
                                                            5. Add Preprocessing

                                                            Alternative 20: 38.2% accurate, 21.6× speedup?

                                                            \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(0.011111111111111112 \cdot \left(b \cdot \left(angle\_m \cdot \left(b \cdot \pi\right)\right)\right)\right) \end{array} \]
                                                            angle\_m = (fabs.f64 angle)
                                                            angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                                            (FPCore (angle_s a b angle_m)
                                                             :precision binary64
                                                             (* angle_s (* 0.011111111111111112 (* b (* angle_m (* b PI))))))
                                                            angle\_m = fabs(angle);
                                                            angle\_s = copysign(1.0, angle);
                                                            double code(double angle_s, double a, double b, double angle_m) {
                                                            	return angle_s * (0.011111111111111112 * (b * (angle_m * (b * ((double) M_PI)))));
                                                            }
                                                            
                                                            angle\_m = Math.abs(angle);
                                                            angle\_s = Math.copySign(1.0, angle);
                                                            public static double code(double angle_s, double a, double b, double angle_m) {
                                                            	return angle_s * (0.011111111111111112 * (b * (angle_m * (b * Math.PI))));
                                                            }
                                                            
                                                            angle\_m = math.fabs(angle)
                                                            angle\_s = math.copysign(1.0, angle)
                                                            def code(angle_s, a, b, angle_m):
                                                            	return angle_s * (0.011111111111111112 * (b * (angle_m * (b * math.pi))))
                                                            
                                                            angle\_m = abs(angle)
                                                            angle\_s = copysign(1.0, angle)
                                                            function code(angle_s, a, b, angle_m)
                                                            	return Float64(angle_s * Float64(0.011111111111111112 * Float64(b * Float64(angle_m * Float64(b * pi)))))
                                                            end
                                                            
                                                            angle\_m = abs(angle);
                                                            angle\_s = sign(angle) * abs(1.0);
                                                            function tmp = code(angle_s, a, b, angle_m)
                                                            	tmp = angle_s * (0.011111111111111112 * (b * (angle_m * (b * pi))));
                                                            end
                                                            
                                                            angle\_m = N[Abs[angle], $MachinePrecision]
                                                            angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
                                                            code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * N[(0.011111111111111112 * N[(b * N[(angle$95$m * N[(b * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                                                            
                                                            \begin{array}{l}
                                                            angle\_m = \left|angle\right|
                                                            \\
                                                            angle\_s = \mathsf{copysign}\left(1, angle\right)
                                                            
                                                            \\
                                                            angle\_s \cdot \left(0.011111111111111112 \cdot \left(b \cdot \left(angle\_m \cdot \left(b \cdot \pi\right)\right)\right)\right)
                                                            \end{array}
                                                            
                                                            Derivation
                                                            1. Initial program 58.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. 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 \frac{1}{90} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
                                                              2. associate-*r*N/A

                                                                \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                                              3. lower-*.f64N/A

                                                                \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                                              4. lower-*.f64N/A

                                                                \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                              5. lower-*.f64N/A

                                                                \[\leadsto \left(\frac{1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                              6. lower-PI.f64N/A

                                                                \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                              7. unpow2N/A

                                                                \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right) \]
                                                              8. unpow2N/A

                                                                \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
                                                              9. difference-of-squaresN/A

                                                                \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                              10. lower-*.f64N/A

                                                                \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                              11. lower-+.f64N/A

                                                                \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                                              12. lower--.f6461.0

                                                                \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                                            5. Applied rewrites61.0%

                                                              \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                            6. Taylor expanded in b around inf

                                                              \[\leadsto \frac{1}{90} \cdot \color{blue}{\left(angle \cdot \left({b}^{2} \cdot \mathsf{PI}\left(\right)\right)\right)} \]
                                                            7. Step-by-step derivation
                                                              1. Applied rewrites40.7%

                                                                \[\leadsto 0.011111111111111112 \cdot \color{blue}{\left(angle \cdot \left(\pi \cdot \left(b \cdot b\right)\right)\right)} \]
                                                              2. Step-by-step derivation
                                                                1. Applied rewrites46.2%

                                                                  \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(b \cdot \pi\right)\right) \cdot b\right) \]
                                                                2. Final simplification46.2%

                                                                  \[\leadsto 0.011111111111111112 \cdot \left(b \cdot \left(angle \cdot \left(b \cdot \pi\right)\right)\right) \]
                                                                3. Add Preprocessing

                                                                Alternative 21: 35.3% accurate, 21.6× speedup?

                                                                \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(0.011111111111111112 \cdot \left(angle\_m \cdot \left(\pi \cdot \left(b \cdot b\right)\right)\right)\right) \end{array} \]
                                                                angle\_m = (fabs.f64 angle)
                                                                angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                                                (FPCore (angle_s a b angle_m)
                                                                 :precision binary64
                                                                 (* angle_s (* 0.011111111111111112 (* angle_m (* PI (* b b))))))
                                                                angle\_m = fabs(angle);
                                                                angle\_s = copysign(1.0, angle);
                                                                double code(double angle_s, double a, double b, double angle_m) {
                                                                	return angle_s * (0.011111111111111112 * (angle_m * (((double) M_PI) * (b * b))));
                                                                }
                                                                
                                                                angle\_m = Math.abs(angle);
                                                                angle\_s = Math.copySign(1.0, angle);
                                                                public static double code(double angle_s, double a, double b, double angle_m) {
                                                                	return angle_s * (0.011111111111111112 * (angle_m * (Math.PI * (b * b))));
                                                                }
                                                                
                                                                angle\_m = math.fabs(angle)
                                                                angle\_s = math.copysign(1.0, angle)
                                                                def code(angle_s, a, b, angle_m):
                                                                	return angle_s * (0.011111111111111112 * (angle_m * (math.pi * (b * b))))
                                                                
                                                                angle\_m = abs(angle)
                                                                angle\_s = copysign(1.0, angle)
                                                                function code(angle_s, a, b, angle_m)
                                                                	return Float64(angle_s * Float64(0.011111111111111112 * Float64(angle_m * Float64(pi * Float64(b * b)))))
                                                                end
                                                                
                                                                angle\_m = abs(angle);
                                                                angle\_s = sign(angle) * abs(1.0);
                                                                function tmp = code(angle_s, a, b, angle_m)
                                                                	tmp = angle_s * (0.011111111111111112 * (angle_m * (pi * (b * b))));
                                                                end
                                                                
                                                                angle\_m = N[Abs[angle], $MachinePrecision]
                                                                angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
                                                                code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * N[(0.011111111111111112 * N[(angle$95$m * N[(Pi * N[(b * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                                                                
                                                                \begin{array}{l}
                                                                angle\_m = \left|angle\right|
                                                                \\
                                                                angle\_s = \mathsf{copysign}\left(1, angle\right)
                                                                
                                                                \\
                                                                angle\_s \cdot \left(0.011111111111111112 \cdot \left(angle\_m \cdot \left(\pi \cdot \left(b \cdot b\right)\right)\right)\right)
                                                                \end{array}
                                                                
                                                                Derivation
                                                                1. Initial program 58.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. 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 \frac{1}{90} \cdot \color{blue}{\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
                                                                  2. associate-*r*N/A

                                                                    \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                                                  3. lower-*.f64N/A

                                                                    \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                                                  4. lower-*.f64N/A

                                                                    \[\leadsto \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                                  5. lower-*.f64N/A

                                                                    \[\leadsto \left(\frac{1}{90} \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                                  6. lower-PI.f64N/A

                                                                    \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                                                  7. unpow2N/A

                                                                    \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right) \]
                                                                  8. unpow2N/A

                                                                    \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
                                                                  9. difference-of-squaresN/A

                                                                    \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                                  10. lower-*.f64N/A

                                                                    \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                                  11. lower-+.f64N/A

                                                                    \[\leadsto \left(\frac{1}{90} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                                                  12. lower--.f6461.0

                                                                    \[\leadsto \left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                                                5. Applied rewrites61.0%

                                                                  \[\leadsto \color{blue}{\left(0.011111111111111112 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                                                6. Taylor expanded in b around inf

                                                                  \[\leadsto \frac{1}{90} \cdot \color{blue}{\left(angle \cdot \left({b}^{2} \cdot \mathsf{PI}\left(\right)\right)\right)} \]
                                                                7. Step-by-step derivation
                                                                  1. Applied rewrites40.7%

                                                                    \[\leadsto 0.011111111111111112 \cdot \color{blue}{\left(angle \cdot \left(\pi \cdot \left(b \cdot b\right)\right)\right)} \]
                                                                  2. Add Preprocessing

                                                                  Reproduce

                                                                  ?
                                                                  herbie shell --seed 2024233 
                                                                  (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)))))