ab-angle->ABCF B

Percentage Accurate: 54.8% → 68.8%
Time: 5.7s
Alternatives: 16
Speedup: 5.5×

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}

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 16 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: 54.8% 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: 68.8% accurate, 1.2× speedup?

\[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \left(angle\_m \cdot \pi\right) \cdot 0.005555555555555556\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;angle\_m \leq 3.1 \cdot 10^{+157}:\\ \;\;\;\;\left(\left(\left(\sin t\_0 \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \sin \left(\left(-t\_0\right) + \frac{\pi}{2}\right)\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(\sin \left(\left(\pi \cdot angle\_m\right) \cdot 0.005555555555555556\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right)\\ \end{array} \end{array} \end{array} \]
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a b angle_m)
 :precision binary64
 (let* ((t_0 (* (* angle_m PI) 0.005555555555555556)))
   (*
    angle_s
    (if (<= angle_m 3.1e+157)
      (*
       (* (* (* (sin t_0) (+ a b)) (- b a)) (sin (+ (- t_0) (/ PI 2.0))))
       2.0)
      (*
       2.0
       (*
        (sin (* (* PI angle_m) 0.005555555555555556))
        (* (+ 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.005555555555555556;
	double tmp;
	if (angle_m <= 3.1e+157) {
		tmp = (((sin(t_0) * (a + b)) * (b - a)) * sin((-t_0 + (((double) M_PI) / 2.0)))) * 2.0;
	} else {
		tmp = 2.0 * (sin(((((double) M_PI) * angle_m) * 0.005555555555555556)) * ((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.005555555555555556;
	double tmp;
	if (angle_m <= 3.1e+157) {
		tmp = (((Math.sin(t_0) * (a + b)) * (b - a)) * Math.sin((-t_0 + (Math.PI / 2.0)))) * 2.0;
	} else {
		tmp = 2.0 * (Math.sin(((Math.PI * angle_m) * 0.005555555555555556)) * ((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.005555555555555556
	tmp = 0
	if angle_m <= 3.1e+157:
		tmp = (((math.sin(t_0) * (a + b)) * (b - a)) * math.sin((-t_0 + (math.pi / 2.0)))) * 2.0
	else:
		tmp = 2.0 * (math.sin(((math.pi * angle_m) * 0.005555555555555556)) * ((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(Float64(angle_m * pi) * 0.005555555555555556)
	tmp = 0.0
	if (angle_m <= 3.1e+157)
		tmp = Float64(Float64(Float64(Float64(sin(t_0) * Float64(a + b)) * Float64(b - a)) * sin(Float64(Float64(-t_0) + Float64(pi / 2.0)))) * 2.0);
	else
		tmp = Float64(2.0 * Float64(sin(Float64(Float64(pi * angle_m) * 0.005555555555555556)) * 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.005555555555555556;
	tmp = 0.0;
	if (angle_m <= 3.1e+157)
		tmp = (((sin(t_0) * (a + b)) * (b - a)) * sin((-t_0 + (pi / 2.0)))) * 2.0;
	else
		tmp = 2.0 * (sin(((pi * angle_m) * 0.005555555555555556)) * ((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[(N[(angle$95$m * Pi), $MachinePrecision] * 0.005555555555555556), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[angle$95$m, 3.1e+157], N[(N[(N[(N[(N[Sin[t$95$0], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[Sin[N[((-t$95$0) + N[(Pi / 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], N[(2.0 * N[(N[Sin[N[(N[(Pi * angle$95$m), $MachinePrecision] * 0.005555555555555556), $MachinePrecision]], $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)

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

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


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if angle < 3.0999999999999997e157

    1. Initial program 54.8%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{180}\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos \left(\left(\frac{1}{180} \cdot angle\right) \cdot \mathsf{PI}\left(\right)\right)\right) \cdot 2 \]
      8. lift-PI.f6468.2

        \[\leadsto \left(\left(\left(\sin \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right)\right) \cdot 2 \]
    7. Applied rewrites68.2%

      \[\leadsto \left(\left(\left(\sin \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right)\right) \cdot 2 \]
    8. Step-by-step derivation
      1. lift-cos.f64N/A

        \[\leadsto \left(\left(\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{180}\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right)\right) \cdot 2 \]
      2. cos-neg-revN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{180}\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \sin \left(\left(-\left(angle \cdot \pi\right) \cdot \frac{1}{180}\right) + \frac{\mathsf{PI}\left(\right)}{2}\right)\right) \cdot 2 \]
      16. lift-PI.f6467.9

        \[\leadsto \left(\left(\left(\sin \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \sin \left(\left(-\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right) + \frac{\pi}{2}\right)\right) \cdot 2 \]
    9. Applied rewrites67.9%

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

    if 3.0999999999999997e157 < angle

    1. Initial program 54.8%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 2 \cdot \left(\color{blue}{\sin \left(\left(\pi \cdot angle\right) \cdot 0.005555555555555556\right)} \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \]
    7. Recombined 2 regimes into one program.
    8. Add Preprocessing

    Alternative 2: 68.6% accurate, 1.2× 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(0.005555555555555556 \cdot \pi\right)\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;b \leq 1.75 \cdot 10^{+261}:\\ \;\;\;\;\left(\left(\left(\sin t\_0 \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos t\_0\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(\sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.005555555555555556\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 1\right) \cdot 2\\ \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 (* 0.005555555555555556 PI))))
       (*
        angle_s
        (if (<= b 1.75e+261)
          (* (* (* (* (sin t_0) (+ a b)) (- b a)) (cos t_0)) 2.0)
          (*
           (*
            (* (* (sin (* (* angle_m PI) 0.005555555555555556)) (+ a b)) (- b a))
            1.0)
           2.0)))))
    angle\_m = fabs(angle);
    angle\_s = copysign(1.0, angle);
    double code(double angle_s, double a, double b, double angle_m) {
    	double t_0 = angle_m * (0.005555555555555556 * ((double) M_PI));
    	double tmp;
    	if (b <= 1.75e+261) {
    		tmp = (((sin(t_0) * (a + b)) * (b - a)) * cos(t_0)) * 2.0;
    	} else {
    		tmp = (((sin(((angle_m * ((double) M_PI)) * 0.005555555555555556)) * (a + b)) * (b - a)) * 1.0) * 2.0;
    	}
    	return angle_s * tmp;
    }
    
    angle\_m = Math.abs(angle);
    angle\_s = Math.copySign(1.0, angle);
    public static double code(double angle_s, double a, double b, double angle_m) {
    	double t_0 = angle_m * (0.005555555555555556 * Math.PI);
    	double tmp;
    	if (b <= 1.75e+261) {
    		tmp = (((Math.sin(t_0) * (a + b)) * (b - a)) * Math.cos(t_0)) * 2.0;
    	} else {
    		tmp = (((Math.sin(((angle_m * Math.PI) * 0.005555555555555556)) * (a + b)) * (b - a)) * 1.0) * 2.0;
    	}
    	return angle_s * tmp;
    }
    
    angle\_m = math.fabs(angle)
    angle\_s = math.copysign(1.0, angle)
    def code(angle_s, a, b, angle_m):
    	t_0 = angle_m * (0.005555555555555556 * math.pi)
    	tmp = 0
    	if b <= 1.75e+261:
    		tmp = (((math.sin(t_0) * (a + b)) * (b - a)) * math.cos(t_0)) * 2.0
    	else:
    		tmp = (((math.sin(((angle_m * math.pi) * 0.005555555555555556)) * (a + b)) * (b - a)) * 1.0) * 2.0
    	return angle_s * tmp
    
    angle\_m = abs(angle)
    angle\_s = copysign(1.0, angle)
    function code(angle_s, a, b, angle_m)
    	t_0 = Float64(angle_m * Float64(0.005555555555555556 * pi))
    	tmp = 0.0
    	if (b <= 1.75e+261)
    		tmp = Float64(Float64(Float64(Float64(sin(t_0) * Float64(a + b)) * Float64(b - a)) * cos(t_0)) * 2.0);
    	else
    		tmp = Float64(Float64(Float64(Float64(sin(Float64(Float64(angle_m * pi) * 0.005555555555555556)) * Float64(a + b)) * Float64(b - a)) * 1.0) * 2.0);
    	end
    	return Float64(angle_s * tmp)
    end
    
    angle\_m = abs(angle);
    angle\_s = sign(angle) * abs(1.0);
    function tmp_2 = code(angle_s, a, b, angle_m)
    	t_0 = angle_m * (0.005555555555555556 * pi);
    	tmp = 0.0;
    	if (b <= 1.75e+261)
    		tmp = (((sin(t_0) * (a + b)) * (b - a)) * cos(t_0)) * 2.0;
    	else
    		tmp = (((sin(((angle_m * pi) * 0.005555555555555556)) * (a + b)) * (b - a)) * 1.0) * 2.0;
    	end
    	tmp_2 = angle_s * tmp;
    end
    
    angle\_m = N[Abs[angle], $MachinePrecision]
    angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
    code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(angle$95$m * N[(0.005555555555555556 * Pi), $MachinePrecision]), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[b, 1.75e+261], N[(N[(N[(N[(N[Sin[t$95$0], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], N[(N[(N[(N[(N[Sin[N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.005555555555555556), $MachinePrecision]], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * 1.0), $MachinePrecision] * 2.0), $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(0.005555555555555556 \cdot \pi\right)\\
    angle\_s \cdot \begin{array}{l}
    \mathbf{if}\;b \leq 1.75 \cdot 10^{+261}:\\
    \;\;\;\;\left(\left(\left(\sin t\_0 \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos t\_0\right) \cdot 2\\
    
    \mathbf{else}:\\
    \;\;\;\;\left(\left(\left(\sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.005555555555555556\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 1\right) \cdot 2\\
    
    
    \end{array}
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if b < 1.74999999999999998e261

      1. Initial program 54.8%

        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
      2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \left(\left(\left(\sin \left(angle \cdot \left(\frac{1}{180} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos \left(\left(angle \cdot \pi\right) \cdot \frac{1}{180}\right)\right) \cdot 2 \]
        8. lift-PI.f6468.3

          \[\leadsto \left(\left(\left(\sin \left(angle \cdot \left(0.005555555555555556 \cdot \pi\right)\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right)\right) \cdot 2 \]
      7. Applied rewrites68.3%

        \[\leadsto \left(\left(\left(\sin \left(angle \cdot \left(0.005555555555555556 \cdot \pi\right)\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right)\right) \cdot 2 \]
      8. Step-by-step derivation
        1. lift-*.f64N/A

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

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

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

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

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

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

          \[\leadsto \left(\left(\left(\sin \left(angle \cdot \left(\frac{1}{180} \cdot \pi\right)\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos \left(angle \cdot \left(\frac{1}{180} \cdot \mathsf{PI}\left(\right)\right)\right)\right) \cdot 2 \]
        8. lift-PI.f6468.3

          \[\leadsto \left(\left(\left(\sin \left(angle \cdot \left(0.005555555555555556 \cdot \pi\right)\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \cos \left(angle \cdot \left(0.005555555555555556 \cdot \pi\right)\right)\right) \cdot 2 \]
      9. Applied rewrites68.3%

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

      if 1.74999999999999998e261 < b

      1. Initial program 54.8%

        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
      2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{180}\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 1\right) \cdot 2 \]
      7. Step-by-step derivation
        1. Applied rewrites66.9%

          \[\leadsto \left(\left(\left(\sin \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 1\right) \cdot 2 \]
      8. Recombined 2 regimes into one program.
      9. Add Preprocessing

      Alternative 3: 68.5% accurate, 2.1× speedup?

      \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;angle\_m \leq 1.32 \cdot 10^{+59}:\\ \;\;\;\;\left(\sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(\sin \left(\left(\pi \cdot angle\_m\right) \cdot 0.005555555555555556\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 1.32e+59)
          (* (* (sin (* (* angle_m PI) 0.011111111111111112)) (+ a b)) (- b a))
          (*
           2.0
           (* (sin (* (* PI angle_m) 0.005555555555555556)) (* (+ 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 <= 1.32e+59) {
      		tmp = (sin(((angle_m * ((double) M_PI)) * 0.011111111111111112)) * (a + b)) * (b - a);
      	} else {
      		tmp = 2.0 * (sin(((((double) M_PI) * angle_m) * 0.005555555555555556)) * ((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 tmp;
      	if (angle_m <= 1.32e+59) {
      		tmp = (Math.sin(((angle_m * Math.PI) * 0.011111111111111112)) * (a + b)) * (b - a);
      	} else {
      		tmp = 2.0 * (Math.sin(((Math.PI * angle_m) * 0.005555555555555556)) * ((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):
      	tmp = 0
      	if angle_m <= 1.32e+59:
      		tmp = (math.sin(((angle_m * math.pi) * 0.011111111111111112)) * (a + b)) * (b - a)
      	else:
      		tmp = 2.0 * (math.sin(((math.pi * angle_m) * 0.005555555555555556)) * ((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 (angle_m <= 1.32e+59)
      		tmp = Float64(Float64(sin(Float64(Float64(angle_m * pi) * 0.011111111111111112)) * Float64(a + b)) * Float64(b - a));
      	else
      		tmp = Float64(2.0 * Float64(sin(Float64(Float64(pi * angle_m) * 0.005555555555555556)) * 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)
      	tmp = 0.0;
      	if (angle_m <= 1.32e+59)
      		tmp = (sin(((angle_m * pi) * 0.011111111111111112)) * (a + b)) * (b - a);
      	else
      		tmp = 2.0 * (sin(((pi * angle_m) * 0.005555555555555556)) * ((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_] := N[(angle$95$s * If[LessEqual[angle$95$m, 1.32e+59], N[(N[(N[Sin[N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision], N[(2.0 * N[(N[Sin[N[(N[(Pi * angle$95$m), $MachinePrecision] * 0.005555555555555556), $MachinePrecision]], $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}\;angle\_m \leq 1.32 \cdot 10^{+59}:\\
      \;\;\;\;\left(\sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;2 \cdot \left(\sin \left(\left(\pi \cdot angle\_m\right) \cdot 0.005555555555555556\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 angle < 1.31999999999999993e59

        1. Initial program 54.8%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

            \[\leadsto \left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right) \]
          10. lift--.f6468.5

            \[\leadsto \left(\sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right) \]
        8. Applied rewrites68.5%

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

        if 1.31999999999999993e59 < angle

        1. Initial program 54.8%

          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
        2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

            \[\leadsto 2 \cdot \left(\color{blue}{\sin \left(\left(\pi \cdot angle\right) \cdot 0.005555555555555556\right)} \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \]
        7. Recombined 2 regimes into one program.
        8. Add Preprocessing

        Alternative 4: 68.4% accurate, 2.1× speedup?

        \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;angle\_m \leq 1.32 \cdot 10^{+59}:\\ \;\;\;\;\left(\sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\sin \left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right) \cdot \left(\left(a + b\right) \cdot \left(b - a\right)\right)\right) \cdot 2\\ \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 1.32e+59)
            (* (* (sin (* (* angle_m PI) 0.011111111111111112)) (+ a b)) (- b a))
            (*
             (* (sin (* (* 0.005555555555555556 angle_m) PI)) (* (+ a b) (- b a)))
             2.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 (angle_m <= 1.32e+59) {
        		tmp = (sin(((angle_m * ((double) M_PI)) * 0.011111111111111112)) * (a + b)) * (b - a);
        	} else {
        		tmp = (sin(((0.005555555555555556 * angle_m) * ((double) M_PI))) * ((a + b) * (b - a))) * 2.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 (angle_m <= 1.32e+59) {
        		tmp = (Math.sin(((angle_m * Math.PI) * 0.011111111111111112)) * (a + b)) * (b - a);
        	} else {
        		tmp = (Math.sin(((0.005555555555555556 * angle_m) * Math.PI)) * ((a + b) * (b - a))) * 2.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 angle_m <= 1.32e+59:
        		tmp = (math.sin(((angle_m * math.pi) * 0.011111111111111112)) * (a + b)) * (b - a)
        	else:
        		tmp = (math.sin(((0.005555555555555556 * angle_m) * math.pi)) * ((a + b) * (b - a))) * 2.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 (angle_m <= 1.32e+59)
        		tmp = Float64(Float64(sin(Float64(Float64(angle_m * pi) * 0.011111111111111112)) * Float64(a + b)) * Float64(b - a));
        	else
        		tmp = Float64(Float64(sin(Float64(Float64(0.005555555555555556 * angle_m) * pi)) * Float64(Float64(a + b) * Float64(b - a))) * 2.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 (angle_m <= 1.32e+59)
        		tmp = (sin(((angle_m * pi) * 0.011111111111111112)) * (a + b)) * (b - a);
        	else
        		tmp = (sin(((0.005555555555555556 * angle_m) * pi)) * ((a + b) * (b - a))) * 2.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[angle$95$m, 1.32e+59], N[(N[(N[Sin[N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision], N[(N[(N[Sin[N[(N[(0.005555555555555556 * angle$95$m), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision] * N[(N[(a + b), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 2.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}\;angle\_m \leq 1.32 \cdot 10^{+59}:\\
        \;\;\;\;\left(\sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\\
        
        \mathbf{else}:\\
        \;\;\;\;\left(\sin \left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right) \cdot \left(\left(a + b\right) \cdot \left(b - a\right)\right)\right) \cdot 2\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if angle < 1.31999999999999993e59

          1. Initial program 54.8%

            \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
          2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right) \]
            10. lift--.f6468.5

              \[\leadsto \left(\sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right) \]
          8. Applied rewrites68.5%

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

          if 1.31999999999999993e59 < angle

          1. Initial program 54.8%

            \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
          2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \color{blue}{\left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot \left(\left(a + b\right) \cdot \left(b - a\right)\right)\right) \cdot 2} \]
          7. Recombined 2 regimes into one program.
          8. Add Preprocessing

          Alternative 5: 68.0% accurate, 2.4× speedup?

          \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(\sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\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
            (* (* (sin (* (* angle_m PI) 0.011111111111111112)) (+ a b)) (- b a))))
          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 * ((sin(((angle_m * ((double) M_PI)) * 0.011111111111111112)) * (a + b)) * (b - a));
          }
          
          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 * ((Math.sin(((angle_m * Math.PI) * 0.011111111111111112)) * (a + b)) * (b - a));
          }
          
          angle\_m = math.fabs(angle)
          angle\_s = math.copysign(1.0, angle)
          def code(angle_s, a, b, angle_m):
          	return angle_s * ((math.sin(((angle_m * math.pi) * 0.011111111111111112)) * (a + b)) * (b - a))
          
          angle\_m = abs(angle)
          angle\_s = copysign(1.0, angle)
          function code(angle_s, a, b, angle_m)
          	return Float64(angle_s * Float64(Float64(sin(Float64(Float64(angle_m * pi) * 0.011111111111111112)) * Float64(a + b)) * Float64(b - a)))
          end
          
          angle\_m = abs(angle);
          angle\_s = sign(angle) * abs(1.0);
          function tmp = code(angle_s, a, b, angle_m)
          	tmp = angle_s * ((sin(((angle_m * pi) * 0.011111111111111112)) * (a + b)) * (b - a));
          end
          
          angle\_m = N[Abs[angle], $MachinePrecision]
          angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
          code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * N[(N[(N[Sin[N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
          
          \begin{array}{l}
          angle\_m = \left|angle\right|
          \\
          angle\_s = \mathsf{copysign}\left(1, angle\right)
          
          \\
          angle\_s \cdot \left(\left(\sin \left(\left(angle\_m \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right)
          \end{array}
          
          Derivation
          1. Initial program 54.8%

            \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
          2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right) \]
            10. lift--.f6468.5

              \[\leadsto \left(\sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right) \]
          8. Applied rewrites68.5%

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

          Alternative 6: 66.5% accurate, 1.0× speedup?

          \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := 2 \cdot \left({b}^{2} - {a}^{2}\right)\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;t\_0 \leq -1 \cdot 10^{-221}:\\ \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\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}:\\ \;\;\;\;\left(\left(\left(angle\_m \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 0.011111111111111112\\ \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 (* 2.0 (- (pow b 2.0) (pow a 2.0)))))
             (*
              angle_s
              (if (<= t_0 -1e-221)
                (* (* -0.011111111111111112 a) (* (* angle_m PI) a))
                (if (<= t_0 1e+306)
                  (* (sin (* (* angle_m PI) 0.011111111111111112)) (* b b))
                  (* (* (* (* angle_m PI) (+ a b)) (- b a)) 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 = 2.0 * (pow(b, 2.0) - pow(a, 2.0));
          	double tmp;
          	if (t_0 <= -1e-221) {
          		tmp = (-0.011111111111111112 * a) * ((angle_m * ((double) M_PI)) * a);
          	} else if (t_0 <= 1e+306) {
          		tmp = sin(((angle_m * ((double) M_PI)) * 0.011111111111111112)) * (b * b);
          	} else {
          		tmp = (((angle_m * ((double) M_PI)) * (a + b)) * (b - a)) * 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 = 2.0 * (Math.pow(b, 2.0) - Math.pow(a, 2.0));
          	double tmp;
          	if (t_0 <= -1e-221) {
          		tmp = (-0.011111111111111112 * a) * ((angle_m * Math.PI) * a);
          	} else if (t_0 <= 1e+306) {
          		tmp = Math.sin(((angle_m * Math.PI) * 0.011111111111111112)) * (b * b);
          	} else {
          		tmp = (((angle_m * Math.PI) * (a + b)) * (b - a)) * 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 = 2.0 * (math.pow(b, 2.0) - math.pow(a, 2.0))
          	tmp = 0
          	if t_0 <= -1e-221:
          		tmp = (-0.011111111111111112 * a) * ((angle_m * math.pi) * a)
          	elif t_0 <= 1e+306:
          		tmp = math.sin(((angle_m * math.pi) * 0.011111111111111112)) * (b * b)
          	else:
          		tmp = (((angle_m * math.pi) * (a + b)) * (b - a)) * 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 = Float64(2.0 * Float64((b ^ 2.0) - (a ^ 2.0)))
          	tmp = 0.0
          	if (t_0 <= -1e-221)
          		tmp = Float64(Float64(-0.011111111111111112 * a) * Float64(Float64(angle_m * pi) * a));
          	elseif (t_0 <= 1e+306)
          		tmp = Float64(sin(Float64(Float64(angle_m * pi) * 0.011111111111111112)) * Float64(b * b));
          	else
          		tmp = Float64(Float64(Float64(Float64(angle_m * pi) * Float64(a + b)) * Float64(b - a)) * 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 = 2.0 * ((b ^ 2.0) - (a ^ 2.0));
          	tmp = 0.0;
          	if (t_0 <= -1e-221)
          		tmp = (-0.011111111111111112 * a) * ((angle_m * pi) * a);
          	elseif (t_0 <= 1e+306)
          		tmp = sin(((angle_m * pi) * 0.011111111111111112)) * (b * b);
          	else
          		tmp = (((angle_m * pi) * (a + b)) * (b - a)) * 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[(2.0 * N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[t$95$0, -1e-221], N[(N[(-0.011111111111111112 * a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * a), $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[(N[(angle$95$m * Pi), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]]]), $MachinePrecision]]
          
          \begin{array}{l}
          angle\_m = \left|angle\right|
          \\
          angle\_s = \mathsf{copysign}\left(1, angle\right)
          
          \\
          \begin{array}{l}
          t_0 := 2 \cdot \left({b}^{2} - {a}^{2}\right)\\
          angle\_s \cdot \begin{array}{l}
          \mathbf{if}\;t\_0 \leq -1 \cdot 10^{-221}:\\
          \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\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}:\\
          \;\;\;\;\left(\left(\left(angle\_m \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 0.011111111111111112\\
          
          
          \end{array}
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if (*.f64 #s(literal 2 binary64) (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))) < -1.00000000000000002e-221

            1. Initial program 54.8%

              \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
            2. 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)} \]
            3. Step-by-step derivation
              1. *-commutativeN/A

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

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

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

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

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

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

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

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
              9. unpow2N/A

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
              10. difference-of-squaresN/A

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

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
              12. lower-+.f64N/A

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
              13. lower--.f6455.8

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
            4. Applied rewrites55.8%

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

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

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

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

                \[\leadsto \left(\frac{-1}{90} \cdot {a}^{2}\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
              4. pow2N/A

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

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

                \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
              7. lift-PI.f6436.0

                \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
            7. Applied rewrites36.0%

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

                \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
              2. lift-*.f64N/A

                \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
              3. associate-*r*N/A

                \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
              4. lower-*.f64N/A

                \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
              5. lower-*.f6436.1

                \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
            9. Applied rewrites36.1%

              \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
            10. Step-by-step derivation
              1. lift-*.f64N/A

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

                \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
              3. lift-*.f64N/A

                \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
              4. lift-PI.f64N/A

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

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

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

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

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

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

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

                \[\leadsto \left(\frac{-1}{90} \cdot a\right) \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right) \]
              12. lift-PI.f6439.5

                \[\leadsto \left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot a\right) \]
            11. Applied rewrites39.5%

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

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

            1. Initial program 54.8%

              \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
            2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \sin \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{1}{90}\right) \cdot {b}^{2} \]
              7. lift-PI.f64N/A

                \[\leadsto \sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right) \cdot {b}^{2} \]
              8. unpow2N/A

                \[\leadsto \sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right) \cdot \left(b \cdot b\right) \]
              9. lower-*.f6436.2

                \[\leadsto \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right) \cdot \left(b \cdot b\right) \]
            8. Applied rewrites36.2%

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

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

            1. Initial program 54.8%

              \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
            2. 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)} \]
            3. Step-by-step derivation
              1. *-commutativeN/A

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

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

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

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

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

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

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

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
              9. unpow2N/A

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
              10. difference-of-squaresN/A

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

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
              12. lower-+.f64N/A

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
              13. lower--.f6455.8

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
            4. Applied rewrites55.8%

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

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

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

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
              4. lift--.f64N/A

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

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

                \[\leadsto \left(\left(\left(\pi \cdot angle\right) \cdot \left(b + a\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
              7. lift-PI.f64N/A

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

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

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

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

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

                \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(b + a\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
              13. +-commutativeN/A

                \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
              14. lower-+.f64N/A

                \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
              15. lift--.f6463.7

                \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 0.011111111111111112 \]
            6. Applied rewrites63.7%

              \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 0.011111111111111112 \]
          3. Recombined 3 regimes into one program.
          4. Add Preprocessing

          Alternative 7: 65.3% accurate, 2.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}\;angle\_m \leq 1.7 \cdot 10^{+60}:\\ \;\;\;\;\left(\left(\left(angle\_m \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 0.011111111111111112\\ \mathbf{elif}\;angle\_m \leq 5 \cdot 10^{+158}:\\ \;\;\;\;\left(\mathsf{fma}\left(0.011111111111111112, \pi, \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle\_m \cdot angle\_m\right)\right) \cdot \left(\left(\pi \cdot \pi\right) \cdot \pi\right)\right) \cdot angle\_m\right) \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\pi \cdot angle\_m\right) \cdot \left(b \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112\\ \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 1.7e+60)
              (* (* (* (* angle_m PI) (+ a b)) (- b a)) 0.011111111111111112)
              (if (<= angle_m 5e+158)
                (*
                 (*
                  (fma
                   0.011111111111111112
                   PI
                   (* (* -2.2862368541380886e-7 (* angle_m angle_m)) (* (* PI PI) PI)))
                  angle_m)
                 (* (- b a) (+ a b)))
                (* (* (* PI angle_m) (* b (- b a))) 0.011111111111111112)))))
          angle\_m = fabs(angle);
          angle\_s = copysign(1.0, angle);
          double code(double angle_s, double a, double b, double angle_m) {
          	double tmp;
          	if (angle_m <= 1.7e+60) {
          		tmp = (((angle_m * ((double) M_PI)) * (a + b)) * (b - a)) * 0.011111111111111112;
          	} else if (angle_m <= 5e+158) {
          		tmp = (fma(0.011111111111111112, ((double) M_PI), ((-2.2862368541380886e-7 * (angle_m * angle_m)) * ((((double) M_PI) * ((double) M_PI)) * ((double) M_PI)))) * angle_m) * ((b - a) * (a + b));
          	} else {
          		tmp = ((((double) M_PI) * angle_m) * (b * (b - a))) * 0.011111111111111112;
          	}
          	return angle_s * tmp;
          }
          
          angle\_m = abs(angle)
          angle\_s = copysign(1.0, angle)
          function code(angle_s, a, b, angle_m)
          	tmp = 0.0
          	if (angle_m <= 1.7e+60)
          		tmp = Float64(Float64(Float64(Float64(angle_m * pi) * Float64(a + b)) * Float64(b - a)) * 0.011111111111111112);
          	elseif (angle_m <= 5e+158)
          		tmp = Float64(Float64(fma(0.011111111111111112, pi, Float64(Float64(-2.2862368541380886e-7 * Float64(angle_m * angle_m)) * Float64(Float64(pi * pi) * pi))) * angle_m) * Float64(Float64(b - a) * Float64(a + b)));
          	else
          		tmp = Float64(Float64(Float64(pi * angle_m) * Float64(b * Float64(b - a))) * 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[angle$95$m, 1.7e+60], N[(N[(N[(N[(angle$95$m * Pi), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * 0.011111111111111112), $MachinePrecision], If[LessEqual[angle$95$m, 5e+158], N[(N[(N[(0.011111111111111112 * Pi + N[(N[(-2.2862368541380886e-7 * N[(angle$95$m * angle$95$m), $MachinePrecision]), $MachinePrecision] * N[(N[(Pi * Pi), $MachinePrecision] * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * angle$95$m), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(Pi * angle$95$m), $MachinePrecision] * N[(b * N[(b - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]]]), $MachinePrecision]
          
          \begin{array}{l}
          angle\_m = \left|angle\right|
          \\
          angle\_s = \mathsf{copysign}\left(1, angle\right)
          
          \\
          angle\_s \cdot \begin{array}{l}
          \mathbf{if}\;angle\_m \leq 1.7 \cdot 10^{+60}:\\
          \;\;\;\;\left(\left(\left(angle\_m \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 0.011111111111111112\\
          
          \mathbf{elif}\;angle\_m \leq 5 \cdot 10^{+158}:\\
          \;\;\;\;\left(\mathsf{fma}\left(0.011111111111111112, \pi, \left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle\_m \cdot angle\_m\right)\right) \cdot \left(\left(\pi \cdot \pi\right) \cdot \pi\right)\right) \cdot angle\_m\right) \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\\
          
          \mathbf{else}:\\
          \;\;\;\;\left(\left(\pi \cdot angle\_m\right) \cdot \left(b \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if angle < 1.7e60

            1. Initial program 54.8%

              \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
            2. 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)} \]
            3. Step-by-step derivation
              1. *-commutativeN/A

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

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

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

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

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

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

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

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
              9. unpow2N/A

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
              10. difference-of-squaresN/A

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

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
              12. lower-+.f64N/A

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
              13. lower--.f6455.8

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
            4. Applied rewrites55.8%

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

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

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

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
              4. lift--.f64N/A

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

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

                \[\leadsto \left(\left(\left(\pi \cdot angle\right) \cdot \left(b + a\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
              7. lift-PI.f64N/A

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

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

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

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

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

                \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(b + a\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
              13. +-commutativeN/A

                \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
              14. lower-+.f64N/A

                \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
              15. lift--.f6463.7

                \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 0.011111111111111112 \]
            6. Applied rewrites63.7%

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

            if 1.7e60 < angle < 4.9999999999999996e158

            1. Initial program 54.8%

              \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
            2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \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) \cdot \left(\color{blue}{\left(b - a\right)} \cdot \left(a + b\right)\right) \]
            7. Step-by-step derivation
              1. *-commutativeN/A

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

                \[\leadsto \left(\left(\frac{-1}{4374000} \cdot \left({angle}^{2} \cdot {\mathsf{PI}\left(\right)}^{3}\right) + \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \left(\left(b - \color{blue}{a}\right) \cdot \left(a + b\right)\right) \]
            8. Applied rewrites53.4%

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

            if 4.9999999999999996e158 < angle

            1. Initial program 54.8%

              \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
            2. 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)} \]
            3. Step-by-step derivation
              1. *-commutativeN/A

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

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

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

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

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

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

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

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
              9. unpow2N/A

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
              10. difference-of-squaresN/A

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

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
              12. lower-+.f64N/A

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
              13. lower--.f6455.8

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
            4. Applied rewrites55.8%

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

              \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
            6. Step-by-step derivation
              1. Applied rewrites38.7%

                \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
            7. Recombined 3 regimes into one program.
            8. Add Preprocessing

            Alternative 8: 64.1% accurate, 2.3× speedup?

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

              1. Initial program 54.8%

                \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
              2. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto 2 \cdot \left(\sin \left(\left(\pi \cdot angle\right) \cdot \frac{1}{180}\right) \cdot {b}^{\color{blue}{2}}\right) \]
                3. Step-by-step derivation
                  1. difference-of-squares-revN/A

                    \[\leadsto 2 \cdot \left(\sin \left(\left(\pi \cdot angle\right) \cdot \frac{1}{180}\right) \cdot {b}^{2}\right) \]
                  2. unpow2N/A

                    \[\leadsto 2 \cdot \left(\sin \left(\left(\pi \cdot angle\right) \cdot \frac{1}{180}\right) \cdot {b}^{2}\right) \]
                  3. pow2N/A

                    \[\leadsto 2 \cdot \left(\sin \left(\left(\pi \cdot angle\right) \cdot \frac{1}{180}\right) \cdot {b}^{2}\right) \]
                  4. unpow2N/A

                    \[\leadsto 2 \cdot \left(\sin \left(\left(\pi \cdot angle\right) \cdot \frac{1}{180}\right) \cdot \left(b \cdot b\right)\right) \]
                  5. lower-*.f6435.7

                    \[\leadsto 2 \cdot \left(\sin \left(\left(\pi \cdot angle\right) \cdot 0.005555555555555556\right) \cdot \left(b \cdot b\right)\right) \]
                4. Applied rewrites35.7%

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

                if 8.49999999999999937e-129 < a

                1. Initial program 54.8%

                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                2. 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)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                  9. unpow2N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                  10. difference-of-squaresN/A

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  12. lower-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  13. lower--.f6455.8

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                4. Applied rewrites55.8%

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  4. lift--.f64N/A

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

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

                    \[\leadsto \left(\left(\left(\pi \cdot angle\right) \cdot \left(b + a\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
                  7. lift-PI.f64N/A

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

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

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

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

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

                    \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(b + a\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
                  13. +-commutativeN/A

                    \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
                  14. lower-+.f64N/A

                    \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
                  15. lift--.f6463.7

                    \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 0.011111111111111112 \]
                6. Applied rewrites63.7%

                  \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 0.011111111111111112 \]
              7. Recombined 2 regimes into one program.
              8. Add Preprocessing

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

                1. Initial program 54.8%

                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                2. 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)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                  9. unpow2N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                  10. difference-of-squaresN/A

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  12. lower-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  13. lower--.f6455.8

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                4. Applied rewrites55.8%

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  4. lift--.f64N/A

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

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

                    \[\leadsto \left(\left(\left(\pi \cdot angle\right) \cdot \left(b + a\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
                  7. lift-PI.f64N/A

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

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

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

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

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

                    \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(b + a\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
                  13. +-commutativeN/A

                    \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
                  14. lower-+.f64N/A

                    \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \frac{1}{90} \]
                  15. lift--.f6463.7

                    \[\leadsto \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot 0.011111111111111112 \]
                6. Applied rewrites63.7%

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

                if 8.0000000000000004e-22 < angle

                1. Initial program 54.8%

                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                2. 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)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                  9. unpow2N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                  10. difference-of-squaresN/A

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  12. lower-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  13. lower--.f6455.8

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                4. Applied rewrites55.8%

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  4. lift-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  5. lift--.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  6. associate-*l*N/A

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

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

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

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

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

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

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

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

                    \[\leadsto \left(angle \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(b + a\right)\right) \cdot \frac{1}{90}\right) \]
                  15. lower-*.f64N/A

                    \[\leadsto \left(angle \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(b + a\right)\right) \cdot \frac{1}{90}\right) \]
                  16. lift--.f64N/A

                    \[\leadsto \left(angle \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(b + a\right)\right) \cdot \frac{1}{90}\right) \]
                  17. +-commutativeN/A

                    \[\leadsto \left(angle \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \frac{1}{90}\right) \]
                  18. lower-+.f6455.8

                    \[\leadsto \left(angle \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot 0.011111111111111112\right) \]
                6. Applied rewrites55.8%

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

              Alternative 10: 59.1% accurate, 5.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}\;a \leq 10^{+131}:\\ \;\;\;\;\left(\left(\pi \cdot angle\_m\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112\\ \mathbf{else}:\\ \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\\ \end{array} \end{array} \]
              angle\_m = (fabs.f64 angle)
              angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
              (FPCore (angle_s a b angle_m)
               :precision binary64
               (*
                angle_s
                (if (<= a 1e+131)
                  (* (* (* PI angle_m) (* (+ b a) (- b a))) 0.011111111111111112)
                  (* (* -0.011111111111111112 a) (* (* angle_m PI) 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 (a <= 1e+131) {
              		tmp = ((((double) M_PI) * angle_m) * ((b + a) * (b - a))) * 0.011111111111111112;
              	} else {
              		tmp = (-0.011111111111111112 * a) * ((angle_m * ((double) M_PI)) * 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 (a <= 1e+131) {
              		tmp = ((Math.PI * angle_m) * ((b + a) * (b - a))) * 0.011111111111111112;
              	} else {
              		tmp = (-0.011111111111111112 * a) * ((angle_m * Math.PI) * 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 a <= 1e+131:
              		tmp = ((math.pi * angle_m) * ((b + a) * (b - a))) * 0.011111111111111112
              	else:
              		tmp = (-0.011111111111111112 * a) * ((angle_m * math.pi) * 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 (a <= 1e+131)
              		tmp = Float64(Float64(Float64(pi * angle_m) * Float64(Float64(b + a) * Float64(b - a))) * 0.011111111111111112);
              	else
              		tmp = Float64(Float64(-0.011111111111111112 * a) * Float64(Float64(angle_m * pi) * 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 (a <= 1e+131)
              		tmp = ((pi * angle_m) * ((b + a) * (b - a))) * 0.011111111111111112;
              	else
              		tmp = (-0.011111111111111112 * a) * ((angle_m * pi) * 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[a, 1e+131], N[(N[(N[(Pi * angle$95$m), $MachinePrecision] * N[(N[(b + a), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 0.011111111111111112), $MachinePrecision], N[(N[(-0.011111111111111112 * a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
              
              \begin{array}{l}
              angle\_m = \left|angle\right|
              \\
              angle\_s = \mathsf{copysign}\left(1, angle\right)
              
              \\
              angle\_s \cdot \begin{array}{l}
              \mathbf{if}\;a \leq 10^{+131}:\\
              \;\;\;\;\left(\left(\pi \cdot angle\_m\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112\\
              
              \mathbf{else}:\\
              \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if a < 9.9999999999999991e130

                1. Initial program 54.8%

                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                2. 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)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                  9. unpow2N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                  10. difference-of-squaresN/A

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  12. lower-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  13. lower--.f6455.8

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                4. Applied rewrites55.8%

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

                if 9.9999999999999991e130 < a

                1. Initial program 54.8%

                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                2. 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)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                  9. unpow2N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                  10. difference-of-squaresN/A

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  12. lower-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  13. lower--.f6455.8

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                4. Applied rewrites55.8%

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

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

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot {a}^{2}\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                  4. pow2N/A

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                  7. lift-PI.f6436.0

                    \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                7. Applied rewrites36.0%

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

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  2. lift-*.f64N/A

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  3. associate-*r*N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  4. lower-*.f64N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  5. lower-*.f6436.1

                    \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                9. Applied rewrites36.1%

                  \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                10. Step-by-step derivation
                  1. lift-*.f64N/A

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

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  3. lift-*.f64N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  4. lift-PI.f64N/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot a\right) \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right) \]
                  12. lift-PI.f6439.5

                    \[\leadsto \left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot a\right) \]
                11. Applied rewrites39.5%

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

              Alternative 11: 57.6% accurate, 5.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}\;a \leq 10^{+131}:\\ \;\;\;\;\left(angle\_m \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\\ \end{array} \end{array} \]
              angle\_m = (fabs.f64 angle)
              angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
              (FPCore (angle_s a b angle_m)
               :precision binary64
               (*
                angle_s
                (if (<= a 1e+131)
                  (* (* angle_m PI) (* (* (- b a) (+ a b)) 0.011111111111111112))
                  (* (* -0.011111111111111112 a) (* (* angle_m PI) 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 (a <= 1e+131) {
              		tmp = (angle_m * ((double) M_PI)) * (((b - a) * (a + b)) * 0.011111111111111112);
              	} else {
              		tmp = (-0.011111111111111112 * a) * ((angle_m * ((double) M_PI)) * 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 (a <= 1e+131) {
              		tmp = (angle_m * Math.PI) * (((b - a) * (a + b)) * 0.011111111111111112);
              	} else {
              		tmp = (-0.011111111111111112 * a) * ((angle_m * Math.PI) * 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 a <= 1e+131:
              		tmp = (angle_m * math.pi) * (((b - a) * (a + b)) * 0.011111111111111112)
              	else:
              		tmp = (-0.011111111111111112 * a) * ((angle_m * math.pi) * 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 (a <= 1e+131)
              		tmp = Float64(Float64(angle_m * pi) * Float64(Float64(Float64(b - a) * Float64(a + b)) * 0.011111111111111112));
              	else
              		tmp = Float64(Float64(-0.011111111111111112 * a) * Float64(Float64(angle_m * pi) * 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 (a <= 1e+131)
              		tmp = (angle_m * pi) * (((b - a) * (a + b)) * 0.011111111111111112);
              	else
              		tmp = (-0.011111111111111112 * a) * ((angle_m * pi) * 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[a, 1e+131], N[(N[(angle$95$m * Pi), $MachinePrecision] * N[(N[(N[(b - a), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision], N[(N[(-0.011111111111111112 * a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
              
              \begin{array}{l}
              angle\_m = \left|angle\right|
              \\
              angle\_s = \mathsf{copysign}\left(1, angle\right)
              
              \\
              angle\_s \cdot \begin{array}{l}
              \mathbf{if}\;a \leq 10^{+131}:\\
              \;\;\;\;\left(angle\_m \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot 0.011111111111111112\right)\\
              
              \mathbf{else}:\\
              \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if a < 9.9999999999999991e130

                1. Initial program 54.8%

                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                2. 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)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                  9. unpow2N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                  10. difference-of-squaresN/A

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  12. lower-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  13. lower--.f6455.8

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                4. Applied rewrites55.8%

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  4. lift-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  5. lift--.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  6. associate-*l*N/A

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

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

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

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

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

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

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

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

                    \[\leadsto \left(angle \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(b + a\right)\right) \cdot \frac{1}{90}\right) \]
                  15. lower-*.f64N/A

                    \[\leadsto \left(angle \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(b + a\right)\right) \cdot \frac{1}{90}\right) \]
                  16. lift--.f64N/A

                    \[\leadsto \left(angle \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(b + a\right)\right) \cdot \frac{1}{90}\right) \]
                  17. +-commutativeN/A

                    \[\leadsto \left(angle \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \frac{1}{90}\right) \]
                  18. lower-+.f6455.8

                    \[\leadsto \left(angle \cdot \pi\right) \cdot \left(\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot 0.011111111111111112\right) \]
                6. Applied rewrites55.8%

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

                if 9.9999999999999991e130 < a

                1. Initial program 54.8%

                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                2. 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)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                  9. unpow2N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                  10. difference-of-squaresN/A

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  12. lower-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  13. lower--.f6455.8

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                4. Applied rewrites55.8%

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

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

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot {a}^{2}\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                  4. pow2N/A

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                  7. lift-PI.f6436.0

                    \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                7. Applied rewrites36.0%

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

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  2. lift-*.f64N/A

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  3. associate-*r*N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  4. lower-*.f64N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  5. lower-*.f6436.1

                    \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                9. Applied rewrites36.1%

                  \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                10. Step-by-step derivation
                  1. lift-*.f64N/A

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

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  3. lift-*.f64N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  4. lift-PI.f64N/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot a\right) \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right) \]
                  12. lift-PI.f6439.5

                    \[\leadsto \left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot a\right) \]
                11. Applied rewrites39.5%

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

              Alternative 12: 57.6% accurate, 2.1× 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}\;2 \cdot \left({b}^{2} - {a}^{2}\right) \leq -1 \cdot 10^{-221}:\\ \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\pi \cdot angle\_m\right) \cdot \left(b \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112\\ \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 (<= (* 2.0 (- (pow b 2.0) (pow a 2.0))) -1e-221)
                  (* (* -0.011111111111111112 a) (* (* angle_m PI) a))
                  (* (* (* PI angle_m) (* b (- b a))) 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 ((2.0 * (pow(b, 2.0) - pow(a, 2.0))) <= -1e-221) {
              		tmp = (-0.011111111111111112 * a) * ((angle_m * ((double) M_PI)) * a);
              	} else {
              		tmp = ((((double) M_PI) * angle_m) * (b * (b - a))) * 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 ((2.0 * (Math.pow(b, 2.0) - Math.pow(a, 2.0))) <= -1e-221) {
              		tmp = (-0.011111111111111112 * a) * ((angle_m * Math.PI) * a);
              	} else {
              		tmp = ((Math.PI * angle_m) * (b * (b - a))) * 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 (2.0 * (math.pow(b, 2.0) - math.pow(a, 2.0))) <= -1e-221:
              		tmp = (-0.011111111111111112 * a) * ((angle_m * math.pi) * a)
              	else:
              		tmp = ((math.pi * angle_m) * (b * (b - a))) * 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(2.0 * Float64((b ^ 2.0) - (a ^ 2.0))) <= -1e-221)
              		tmp = Float64(Float64(-0.011111111111111112 * a) * Float64(Float64(angle_m * pi) * a));
              	else
              		tmp = Float64(Float64(Float64(pi * angle_m) * Float64(b * Float64(b - a))) * 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 ((2.0 * ((b ^ 2.0) - (a ^ 2.0))) <= -1e-221)
              		tmp = (-0.011111111111111112 * a) * ((angle_m * pi) * a);
              	else
              		tmp = ((pi * angle_m) * (b * (b - a))) * 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[N[(2.0 * N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -1e-221], N[(N[(-0.011111111111111112 * a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision], N[(N[(N[(Pi * angle$95$m), $MachinePrecision] * N[(b * N[(b - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 0.011111111111111112), $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}\;2 \cdot \left({b}^{2} - {a}^{2}\right) \leq -1 \cdot 10^{-221}:\\
              \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\\
              
              \mathbf{else}:\\
              \;\;\;\;\left(\left(\pi \cdot angle\_m\right) \cdot \left(b \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if (*.f64 #s(literal 2 binary64) (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))) < -1.00000000000000002e-221

                1. Initial program 54.8%

                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                2. 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)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                  9. unpow2N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                  10. difference-of-squaresN/A

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  12. lower-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  13. lower--.f6455.8

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                4. Applied rewrites55.8%

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

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

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot {a}^{2}\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                  4. pow2N/A

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                  7. lift-PI.f6436.0

                    \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                7. Applied rewrites36.0%

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

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  2. lift-*.f64N/A

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  3. associate-*r*N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  4. lower-*.f64N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  5. lower-*.f6436.1

                    \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                9. Applied rewrites36.1%

                  \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                10. Step-by-step derivation
                  1. lift-*.f64N/A

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

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  3. lift-*.f64N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  4. lift-PI.f64N/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot a\right) \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right) \]
                  12. lift-PI.f6439.5

                    \[\leadsto \left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot a\right) \]
                11. Applied rewrites39.5%

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

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

                1. Initial program 54.8%

                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                2. 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)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                  9. unpow2N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                  10. difference-of-squaresN/A

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  12. lower-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  13. lower--.f6455.8

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                4. Applied rewrites55.8%

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

                  \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                6. Step-by-step derivation
                  1. Applied rewrites38.7%

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                7. Recombined 2 regimes into one program.
                8. Add Preprocessing

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

                  1. Initial program 54.8%

                    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                  2. 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)} \]
                  3. Step-by-step derivation
                    1. *-commutativeN/A

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

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

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

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

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

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

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                    9. unpow2N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                    10. difference-of-squaresN/A

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    12. lower-+.f64N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    13. lower--.f6455.8

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                  4. Applied rewrites55.8%

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

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

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot {a}^{2}\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                    4. pow2N/A

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                    7. lift-PI.f6436.0

                      \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  7. Applied rewrites36.0%

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

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                    2. lift-*.f64N/A

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                    3. associate-*r*N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    4. lower-*.f64N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    5. lower-*.f6436.1

                      \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  9. Applied rewrites36.1%

                    \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  10. Step-by-step derivation
                    1. lift-*.f64N/A

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

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    3. lift-*.f64N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    4. lift-PI.f64N/A

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

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

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

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

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

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot a\right) \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right) \]
                    12. lift-PI.f6439.5

                      \[\leadsto \left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot a\right) \]
                  11. Applied rewrites39.5%

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

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

                  1. Initial program 54.8%

                    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                  2. 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)} \]
                  3. Step-by-step derivation
                    1. *-commutativeN/A

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

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

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

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

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

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

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                    9. unpow2N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                    10. difference-of-squaresN/A

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    12. lower-+.f64N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    13. lower--.f6455.8

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                  4. Applied rewrites55.8%

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

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

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

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

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

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

                      \[\leadsto \left(\left(\pi \cdot {b}^{2}\right) \cdot angle\right) \cdot \frac{1}{90} \]
                    6. unpow2N/A

                      \[\leadsto \left(\left(\pi \cdot \left(b \cdot b\right)\right) \cdot angle\right) \cdot \frac{1}{90} \]
                    7. lower-*.f6435.8

                      \[\leadsto \left(\left(\pi \cdot \left(b \cdot b\right)\right) \cdot angle\right) \cdot 0.011111111111111112 \]
                  7. Applied rewrites35.8%

                    \[\leadsto \left(\left(\pi \cdot \left(b \cdot b\right)\right) \cdot angle\right) \cdot 0.011111111111111112 \]
                3. Recombined 2 regimes into one program.
                4. Add Preprocessing

                Alternative 14: 40.8% accurate, 7.2× speedup?

                \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;a \leq 4 \cdot 10^{+148}:\\ \;\;\;\;\left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle\_m \cdot \pi\right)\\ \mathbf{else}:\\ \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\\ \end{array} \end{array} \]
                angle\_m = (fabs.f64 angle)
                angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                (FPCore (angle_s a b angle_m)
                 :precision binary64
                 (*
                  angle_s
                  (if (<= a 4e+148)
                    (* (* (* -0.011111111111111112 a) a) (* angle_m PI))
                    (* (* -0.011111111111111112 a) (* (* angle_m PI) 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 (a <= 4e+148) {
                		tmp = ((-0.011111111111111112 * a) * a) * (angle_m * ((double) M_PI));
                	} else {
                		tmp = (-0.011111111111111112 * a) * ((angle_m * ((double) M_PI)) * 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 (a <= 4e+148) {
                		tmp = ((-0.011111111111111112 * a) * a) * (angle_m * Math.PI);
                	} else {
                		tmp = (-0.011111111111111112 * a) * ((angle_m * Math.PI) * 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 a <= 4e+148:
                		tmp = ((-0.011111111111111112 * a) * a) * (angle_m * math.pi)
                	else:
                		tmp = (-0.011111111111111112 * a) * ((angle_m * math.pi) * 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 (a <= 4e+148)
                		tmp = Float64(Float64(Float64(-0.011111111111111112 * a) * a) * Float64(angle_m * pi));
                	else
                		tmp = Float64(Float64(-0.011111111111111112 * a) * Float64(Float64(angle_m * pi) * 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 (a <= 4e+148)
                		tmp = ((-0.011111111111111112 * a) * a) * (angle_m * pi);
                	else
                		tmp = (-0.011111111111111112 * a) * ((angle_m * pi) * 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[a, 4e+148], N[(N[(N[(-0.011111111111111112 * a), $MachinePrecision] * a), $MachinePrecision] * N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision], N[(N[(-0.011111111111111112 * a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
                
                \begin{array}{l}
                angle\_m = \left|angle\right|
                \\
                angle\_s = \mathsf{copysign}\left(1, angle\right)
                
                \\
                angle\_s \cdot \begin{array}{l}
                \mathbf{if}\;a \leq 4 \cdot 10^{+148}:\\
                \;\;\;\;\left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle\_m \cdot \pi\right)\\
                
                \mathbf{else}:\\
                \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\\
                
                
                \end{array}
                \end{array}
                
                Derivation
                1. Split input into 2 regimes
                2. if a < 4.0000000000000002e148

                  1. Initial program 54.8%

                    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                  2. 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)} \]
                  3. Step-by-step derivation
                    1. *-commutativeN/A

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

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

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

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

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

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

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                    9. unpow2N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                    10. difference-of-squaresN/A

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    12. lower-+.f64N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    13. lower--.f6455.8

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                  4. Applied rewrites55.8%

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

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

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot {a}^{2}\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                    4. pow2N/A

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                    7. lift-PI.f6436.0

                      \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  7. Applied rewrites36.0%

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

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                    2. lift-*.f64N/A

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                    3. associate-*r*N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    4. lower-*.f64N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    5. lower-*.f6436.1

                      \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  9. Applied rewrites36.1%

                    \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]

                  if 4.0000000000000002e148 < a

                  1. Initial program 54.8%

                    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                  2. 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)} \]
                  3. Step-by-step derivation
                    1. *-commutativeN/A

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

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

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

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

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

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

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                    9. unpow2N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                    10. difference-of-squaresN/A

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    12. lower-+.f64N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    13. lower--.f6455.8

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                  4. Applied rewrites55.8%

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

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

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot {a}^{2}\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                    4. pow2N/A

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                    7. lift-PI.f6436.0

                      \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  7. Applied rewrites36.0%

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

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                    2. lift-*.f64N/A

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                    3. associate-*r*N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    4. lower-*.f64N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    5. lower-*.f6436.1

                      \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  9. Applied rewrites36.1%

                    \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  10. Step-by-step derivation
                    1. lift-*.f64N/A

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

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    3. lift-*.f64N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    4. lift-PI.f64N/A

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

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

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

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

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

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot a\right) \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right) \]
                    12. lift-PI.f6439.5

                      \[\leadsto \left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot a\right) \]
                  11. Applied rewrites39.5%

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

                Alternative 15: 39.5% accurate, 7.2× speedup?

                \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;angle\_m \leq 7.6 \cdot 10^{-34}:\\ \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle\_m \cdot \pi\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 7.6e-34)
                    (* (* -0.011111111111111112 a) (* (* angle_m PI) a))
                    (* (* -0.011111111111111112 (* a a)) (* 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 tmp;
                	if (angle_m <= 7.6e-34) {
                		tmp = (-0.011111111111111112 * a) * ((angle_m * ((double) M_PI)) * a);
                	} else {
                		tmp = (-0.011111111111111112 * (a * a)) * (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 tmp;
                	if (angle_m <= 7.6e-34) {
                		tmp = (-0.011111111111111112 * a) * ((angle_m * Math.PI) * a);
                	} else {
                		tmp = (-0.011111111111111112 * (a * a)) * (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):
                	tmp = 0
                	if angle_m <= 7.6e-34:
                		tmp = (-0.011111111111111112 * a) * ((angle_m * math.pi) * a)
                	else:
                		tmp = (-0.011111111111111112 * (a * a)) * (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)
                	tmp = 0.0
                	if (angle_m <= 7.6e-34)
                		tmp = Float64(Float64(-0.011111111111111112 * a) * Float64(Float64(angle_m * pi) * a));
                	else
                		tmp = Float64(Float64(-0.011111111111111112 * Float64(a * a)) * 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)
                	tmp = 0.0;
                	if (angle_m <= 7.6e-34)
                		tmp = (-0.011111111111111112 * a) * ((angle_m * pi) * a);
                	else
                		tmp = (-0.011111111111111112 * (a * a)) * (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_] := N[(angle$95$s * If[LessEqual[angle$95$m, 7.6e-34], N[(N[(-0.011111111111111112 * a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision], N[(N[(-0.011111111111111112 * N[(a * a), $MachinePrecision]), $MachinePrecision] * N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
                
                \begin{array}{l}
                angle\_m = \left|angle\right|
                \\
                angle\_s = \mathsf{copysign}\left(1, angle\right)
                
                \\
                angle\_s \cdot \begin{array}{l}
                \mathbf{if}\;angle\_m \leq 7.6 \cdot 10^{-34}:\\
                \;\;\;\;\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\\
                
                \mathbf{else}:\\
                \;\;\;\;\left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle\_m \cdot \pi\right)\\
                
                
                \end{array}
                \end{array}
                
                Derivation
                1. Split input into 2 regimes
                2. if angle < 7.6000000000000002e-34

                  1. Initial program 54.8%

                    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                  2. 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)} \]
                  3. Step-by-step derivation
                    1. *-commutativeN/A

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

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

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

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

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

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

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                    9. unpow2N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                    10. difference-of-squaresN/A

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    12. lower-+.f64N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    13. lower--.f6455.8

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                  4. Applied rewrites55.8%

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

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

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot {a}^{2}\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                    4. pow2N/A

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                    7. lift-PI.f6436.0

                      \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  7. Applied rewrites36.0%

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

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                    2. lift-*.f64N/A

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                    3. associate-*r*N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    4. lower-*.f64N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    5. lower-*.f6436.1

                      \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  9. Applied rewrites36.1%

                    \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  10. Step-by-step derivation
                    1. lift-*.f64N/A

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

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    3. lift-*.f64N/A

                      \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                    4. lift-PI.f64N/A

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

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

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

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

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

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot a\right) \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right) \]
                    12. lift-PI.f6439.5

                      \[\leadsto \left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot a\right) \]
                  11. Applied rewrites39.5%

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

                  if 7.6000000000000002e-34 < angle

                  1. Initial program 54.8%

                    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                  2. 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)} \]
                  3. Step-by-step derivation
                    1. *-commutativeN/A

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

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

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

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

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

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

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                    9. unpow2N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                    10. difference-of-squaresN/A

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

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    12. lower-+.f64N/A

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                    13. lower--.f6455.8

                      \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                  4. Applied rewrites55.8%

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

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

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot {a}^{2}\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                    4. pow2N/A

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

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

                      \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                    7. lift-PI.f6436.0

                      \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  7. Applied rewrites36.0%

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

                Alternative 16: 38.5% accurate, 9.4× speedup?

                \[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\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 a) (* (* angle_m PI) a))))
                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 * a) * ((angle_m * ((double) M_PI)) * a));
                }
                
                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 * a) * ((angle_m * Math.PI) * a));
                }
                
                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 * a) * ((angle_m * math.pi) * a))
                
                angle\_m = abs(angle)
                angle\_s = copysign(1.0, angle)
                function code(angle_s, a, b, angle_m)
                	return Float64(angle_s * Float64(Float64(-0.011111111111111112 * a) * Float64(Float64(angle_m * pi) * a)))
                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 * a) * ((angle_m * pi) * a));
                end
                
                angle\_m = N[Abs[angle], $MachinePrecision]
                angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
                code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * N[(N[(-0.011111111111111112 * a), $MachinePrecision] * N[(N[(angle$95$m * Pi), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                
                \begin{array}{l}
                angle\_m = \left|angle\right|
                \\
                angle\_s = \mathsf{copysign}\left(1, angle\right)
                
                \\
                angle\_s \cdot \left(\left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle\_m \cdot \pi\right) \cdot a\right)\right)
                \end{array}
                
                Derivation
                1. Initial program 54.8%

                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                2. 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)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \frac{1}{90} \]
                  9. unpow2N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \frac{1}{90} \]
                  10. difference-of-squaresN/A

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

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  12. lower-+.f64N/A

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90} \]
                  13. lower--.f6455.8

                    \[\leadsto \left(\left(\pi \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot 0.011111111111111112 \]
                4. Applied rewrites55.8%

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

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

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot {a}^{2}\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                  4. pow2N/A

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \]
                  7. lift-PI.f6436.0

                    \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                7. Applied rewrites36.0%

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

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  2. lift-*.f64N/A

                    \[\leadsto \left(\frac{-1}{90} \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \pi\right) \]
                  3. associate-*r*N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  4. lower-*.f64N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  5. lower-*.f6436.1

                    \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                9. Applied rewrites36.1%

                  \[\leadsto \left(\left(-0.011111111111111112 \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                10. Step-by-step derivation
                  1. lift-*.f64N/A

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

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  3. lift-*.f64N/A

                    \[\leadsto \left(\left(\frac{-1}{90} \cdot a\right) \cdot a\right) \cdot \left(angle \cdot \pi\right) \]
                  4. lift-PI.f64N/A

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

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

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

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

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

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

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

                    \[\leadsto \left(\frac{-1}{90} \cdot a\right) \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right) \]
                  12. lift-PI.f6439.5

                    \[\leadsto \left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(angle \cdot \pi\right) \cdot a\right) \]
                11. Applied rewrites39.5%

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

                Reproduce

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