ab-angle->ABCF B

Percentage Accurate: 54.4% → 68.0%
Time: 8.9s
Alternatives: 16
Speedup: 6.6×

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.4% accurate, 1.0× speedup?

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

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

Alternative 1: 68.0% accurate, 0.4× speedup?

\[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \pi \cdot \frac{angle\_m}{180}\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin t\_0\right) \cdot \cos t\_0 \leq -5 \cdot 10^{-65}:\\ \;\;\;\;\left(\left(\sin \left(\frac{angle\_m}{180} \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(2 \cdot \left(\cos \left(\frac{\frac{\mathsf{fma}\left(\pi, -angle\_m, \pi \cdot angle\_m\right)}{-180}}{2}\right) \cdot \cos \left(\left(angle\_m \cdot 0.005555555555555556\right) \cdot \pi\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\left(angle\_m \cdot 0.005555555555555556\right) \cdot \sqrt[3]{\pi \cdot \pi}, \sqrt[3]{\pi}, 0.5 \cdot \pi\right)\right) \cdot 2\right)\\ \end{array} \end{array} \end{array} \]
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a b angle_m)
 :precision binary64
 (let* ((t_0 (* PI (/ angle_m 180.0))))
   (*
    angle_s
    (if (<=
         (* (* (* 2.0 (- (pow b 2.0) (pow a 2.0))) (sin t_0)) (cos t_0))
         -5e-65)
      (*
       (* (* (sin (* (/ angle_m 180.0) PI)) (+ a b)) (- b a))
       (*
        2.0
        (*
         (cos (/ (/ (fma PI (- angle_m) (* PI angle_m)) -180.0) 2.0))
         (cos (* (* angle_m 0.005555555555555556) PI)))))
      (*
       (* (* (sin (* (* 0.005555555555555556 angle_m) PI)) (+ a b)) (- b a))
       (*
        (sin
         (fma
          (* (* angle_m 0.005555555555555556) (cbrt (* PI PI)))
          (cbrt PI)
          (* 0.5 PI)))
        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 = ((double) M_PI) * (angle_m / 180.0);
	double tmp;
	if ((((2.0 * (pow(b, 2.0) - pow(a, 2.0))) * sin(t_0)) * cos(t_0)) <= -5e-65) {
		tmp = ((sin(((angle_m / 180.0) * ((double) M_PI))) * (a + b)) * (b - a)) * (2.0 * (cos(((fma(((double) M_PI), -angle_m, (((double) M_PI) * angle_m)) / -180.0) / 2.0)) * cos(((angle_m * 0.005555555555555556) * ((double) M_PI)))));
	} else {
		tmp = ((sin(((0.005555555555555556 * angle_m) * ((double) M_PI))) * (a + b)) * (b - a)) * (sin(fma(((angle_m * 0.005555555555555556) * cbrt((((double) M_PI) * ((double) M_PI)))), cbrt(((double) M_PI)), (0.5 * ((double) M_PI)))) * 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(pi * Float64(angle_m / 180.0))
	tmp = 0.0
	if (Float64(Float64(Float64(2.0 * Float64((b ^ 2.0) - (a ^ 2.0))) * sin(t_0)) * cos(t_0)) <= -5e-65)
		tmp = Float64(Float64(Float64(sin(Float64(Float64(angle_m / 180.0) * pi)) * Float64(a + b)) * Float64(b - a)) * Float64(2.0 * Float64(cos(Float64(Float64(fma(pi, Float64(-angle_m), Float64(pi * angle_m)) / -180.0) / 2.0)) * cos(Float64(Float64(angle_m * 0.005555555555555556) * pi)))));
	else
		tmp = Float64(Float64(Float64(sin(Float64(Float64(0.005555555555555556 * angle_m) * pi)) * Float64(a + b)) * Float64(b - a)) * Float64(sin(fma(Float64(Float64(angle_m * 0.005555555555555556) * cbrt(Float64(pi * pi))), cbrt(pi), Float64(0.5 * pi))) * 2.0));
	end
	return Float64(angle_s * tmp)
end
angle\_m = N[Abs[angle], $MachinePrecision]
angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[(Pi * N[(angle$95$m / 180.0), $MachinePrecision]), $MachinePrecision]}, N[(angle$95$s * If[LessEqual[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], -5e-65], N[(N[(N[(N[Sin[N[(N[(angle$95$m / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(2.0 * N[(N[Cos[N[(N[(N[(Pi * (-angle$95$m) + N[(Pi * angle$95$m), $MachinePrecision]), $MachinePrecision] / -180.0), $MachinePrecision] / 2.0), $MachinePrecision]], $MachinePrecision] * N[Cos[N[(N[(angle$95$m * 0.005555555555555556), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[Sin[N[(N[(0.005555555555555556 * angle$95$m), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(N[Sin[N[(N[(N[(angle$95$m * 0.005555555555555556), $MachinePrecision] * N[Power[N[(Pi * Pi), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision] * N[Power[Pi, 1/3], $MachinePrecision] + N[(0.5 * Pi), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
\begin{array}{l}
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

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

\mathbf{else}:\\
\;\;\;\;\left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\left(angle\_m \cdot 0.005555555555555556\right) \cdot \sqrt[3]{\pi \cdot \pi}, \sqrt[3]{\pi}, 0.5 \cdot \pi\right)\right) \cdot 2\right)\\


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

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(2 \cdot \left(\cos \left(\frac{\frac{\mathsf{fma}\left(\pi, -angle, \pi \cdot angle\right)}{-180}}{2}\right) \cdot \sin \left(\frac{\frac{\pi \cdot angle - \left(-\pi \cdot angle\right)}{180}}{2} + \frac{\color{blue}{\pi}}{2}\right)\right)\right) \]
      5. div-add-revN/A

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(angle \cdot \color{blue}{\frac{1}{180}}\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(2 \cdot \left(\cos \left(\frac{\frac{\mathsf{fma}\left(\pi, -angle, \pi \cdot angle\right)}{-180}}{2}\right) \cdot \cos \left(\left(angle \cdot \frac{1}{180}\right) \cdot \pi\right)\right)\right) \]
      4. mult-flipN/A

        \[\leadsto \left(\left(\sin \left(\color{blue}{\frac{angle}{180}} \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(2 \cdot \left(\cos \left(\frac{\frac{\mathsf{fma}\left(\pi, -angle, \pi \cdot angle\right)}{-180}}{2}\right) \cdot \cos \left(\left(angle \cdot \frac{1}{180}\right) \cdot \pi\right)\right)\right) \]
      5. lower-/.f6468.0

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

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

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

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \color{blue}{\pi \cdot \left(\frac{1}{180} \cdot angle\right)}\right)\right) \cdot 2\right) \]
      12. lower-*.f6467.7

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \pi \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right) \cdot 2\right) \]
      15. lower-*.f6467.7

        \[\leadsto \left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(0.5, \pi, \pi \cdot \color{blue}{\left(angle \cdot 0.005555555555555556\right)}\right)\right) \cdot 2\right) \]
    5. Applied rewrites67.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\frac{angle}{180} \cdot \color{blue}{\mathsf{PI}\left(\right)} + \frac{1}{2} \cdot \pi\right) \cdot 2\right) \]
      22. add-cube-cbrtN/A

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \color{blue}{\left(\mathsf{fma}\left(\frac{angle}{180} \cdot \left(\sqrt[3]{\mathsf{PI}\left(\right)} \cdot \sqrt[3]{\mathsf{PI}\left(\right)}\right), \sqrt[3]{\mathsf{PI}\left(\right)}, \frac{1}{2} \cdot \pi\right)\right)} \cdot 2\right) \]
    7. Applied rewrites67.8%

      \[\leadsto \left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \color{blue}{\left(\mathsf{fma}\left(\left(angle \cdot 0.005555555555555556\right) \cdot \sqrt[3]{\pi \cdot \pi}, \sqrt[3]{\pi}, 0.5 \cdot \pi\right)\right)} \cdot 2\right) \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 2: 67.8% accurate, 0.7× speedup?

\[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;2 \cdot \left({b}^{2} - {a}^{2}\right) \leq -4 \cdot 10^{+93}:\\ \;\;\;\;\left(\left(a \cdot \sin \left(0.005555555555555556 \cdot \left(angle\_m \cdot \pi\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(2 \cdot \left(\cos \left(\frac{\frac{\mathsf{fma}\left(\pi, -angle\_m, \pi \cdot angle\_m\right)}{-180}}{2}\right) \cdot \cos \left(\left(angle\_m \cdot 0.005555555555555556\right) \cdot \pi\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\left(angle\_m \cdot 0.005555555555555556\right) \cdot \sqrt[3]{\pi \cdot \pi}, \sqrt[3]{\pi}, 0.5 \cdot \pi\right)\right) \cdot 2\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 (<= (* 2.0 (- (pow b 2.0) (pow a 2.0))) -4e+93)
    (*
     (* (* a (sin (* 0.005555555555555556 (* angle_m PI)))) (- b a))
     (*
      2.0
      (*
       (cos (/ (/ (fma PI (- angle_m) (* PI angle_m)) -180.0) 2.0))
       (cos (* (* angle_m 0.005555555555555556) PI)))))
    (*
     (* (* (sin (* (* 0.005555555555555556 angle_m) PI)) (+ a b)) (- b a))
     (*
      (sin
       (fma
        (* (* angle_m 0.005555555555555556) (cbrt (* PI PI)))
        (cbrt PI)
        (* 0.5 PI)))
      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 ((2.0 * (pow(b, 2.0) - pow(a, 2.0))) <= -4e+93) {
		tmp = ((a * sin((0.005555555555555556 * (angle_m * ((double) M_PI))))) * (b - a)) * (2.0 * (cos(((fma(((double) M_PI), -angle_m, (((double) M_PI) * angle_m)) / -180.0) / 2.0)) * cos(((angle_m * 0.005555555555555556) * ((double) M_PI)))));
	} else {
		tmp = ((sin(((0.005555555555555556 * angle_m) * ((double) M_PI))) * (a + b)) * (b - a)) * (sin(fma(((angle_m * 0.005555555555555556) * cbrt((((double) M_PI) * ((double) M_PI)))), cbrt(((double) M_PI)), (0.5 * ((double) M_PI)))) * 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 (Float64(2.0 * Float64((b ^ 2.0) - (a ^ 2.0))) <= -4e+93)
		tmp = Float64(Float64(Float64(a * sin(Float64(0.005555555555555556 * Float64(angle_m * pi)))) * Float64(b - a)) * Float64(2.0 * Float64(cos(Float64(Float64(fma(pi, Float64(-angle_m), Float64(pi * angle_m)) / -180.0) / 2.0)) * cos(Float64(Float64(angle_m * 0.005555555555555556) * pi)))));
	else
		tmp = Float64(Float64(Float64(sin(Float64(Float64(0.005555555555555556 * angle_m) * pi)) * Float64(a + b)) * Float64(b - a)) * Float64(sin(fma(Float64(Float64(angle_m * 0.005555555555555556) * cbrt(Float64(pi * pi))), cbrt(pi), Float64(0.5 * pi))) * 2.0));
	end
	return Float64(angle_s * tmp)
end
angle\_m = N[Abs[angle], $MachinePrecision]
angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * If[LessEqual[N[(2.0 * N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -4e+93], N[(N[(N[(a * N[Sin[N[(0.005555555555555556 * N[(angle$95$m * Pi), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(2.0 * N[(N[Cos[N[(N[(N[(Pi * (-angle$95$m) + N[(Pi * angle$95$m), $MachinePrecision]), $MachinePrecision] / -180.0), $MachinePrecision] / 2.0), $MachinePrecision]], $MachinePrecision] * N[Cos[N[(N[(angle$95$m * 0.005555555555555556), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[Sin[N[(N[(0.005555555555555556 * angle$95$m), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(N[Sin[N[(N[(N[(angle$95$m * 0.005555555555555556), $MachinePrecision] * N[Power[N[(Pi * Pi), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision] * N[Power[Pi, 1/3], $MachinePrecision] + N[(0.5 * Pi), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * 2.0), $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}\;2 \cdot \left({b}^{2} - {a}^{2}\right) \leq -4 \cdot 10^{+93}:\\
\;\;\;\;\left(\left(a \cdot \sin \left(0.005555555555555556 \cdot \left(angle\_m \cdot \pi\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(2 \cdot \left(\cos \left(\frac{\frac{\mathsf{fma}\left(\pi, -angle\_m, \pi \cdot angle\_m\right)}{-180}}{2}\right) \cdot \cos \left(\left(angle\_m \cdot 0.005555555555555556\right) \cdot \pi\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\left(angle\_m \cdot 0.005555555555555556\right) \cdot \sqrt[3]{\pi \cdot \pi}, \sqrt[3]{\pi}, 0.5 \cdot \pi\right)\right) \cdot 2\right)\\


\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)))) < -4.00000000000000017e93

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(2 \cdot \left(\cos \left(\frac{\frac{\mathsf{fma}\left(\pi, -angle, \pi \cdot angle\right)}{-180}}{2}\right) \cdot \sin \left(\frac{\frac{\pi \cdot angle - \left(-\pi \cdot angle\right)}{180}}{2} + \frac{\color{blue}{\pi}}{2}\right)\right)\right) \]
      5. div-add-revN/A

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

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

      \[\leadsto \left(\color{blue}{\left(a \cdot \sin \left(\frac{1}{180} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right)} \cdot \left(b - a\right)\right) \cdot \left(2 \cdot \left(\cos \left(\frac{\frac{\mathsf{fma}\left(\pi, -angle, \pi \cdot angle\right)}{-180}}{2}\right) \cdot \cos \left(\left(angle \cdot \frac{1}{180}\right) \cdot \pi\right)\right)\right) \]
    8. Step-by-step derivation
      1. lower-*.f64N/A

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

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

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

        \[\leadsto \left(\left(a \cdot \sin \left(\frac{1}{180} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(2 \cdot \left(\cos \left(\frac{\frac{\mathsf{fma}\left(\pi, -angle, \pi \cdot angle\right)}{-180}}{2}\right) \cdot \cos \left(\left(angle \cdot \frac{1}{180}\right) \cdot \pi\right)\right)\right) \]
      5. lower-PI.f6442.2

        \[\leadsto \left(\left(a \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(2 \cdot \left(\cos \left(\frac{\frac{\mathsf{fma}\left(\pi, -angle, \pi \cdot angle\right)}{-180}}{2}\right) \cdot \cos \left(\left(angle \cdot 0.005555555555555556\right) \cdot \pi\right)\right)\right) \]
    9. Applied rewrites42.2%

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

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

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \color{blue}{\pi \cdot \left(\frac{1}{180} \cdot angle\right)}\right)\right) \cdot 2\right) \]
      12. lower-*.f6467.7

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \pi \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right) \cdot 2\right) \]
      15. lower-*.f6467.7

        \[\leadsto \left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(0.5, \pi, \pi \cdot \color{blue}{\left(angle \cdot 0.005555555555555556\right)}\right)\right) \cdot 2\right) \]
    5. Applied rewrites67.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\frac{angle}{180} \cdot \color{blue}{\mathsf{PI}\left(\right)} + \frac{1}{2} \cdot \pi\right) \cdot 2\right) \]
      22. add-cube-cbrtN/A

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \color{blue}{\left(\mathsf{fma}\left(\frac{angle}{180} \cdot \left(\sqrt[3]{\mathsf{PI}\left(\right)} \cdot \sqrt[3]{\mathsf{PI}\left(\right)}\right), \sqrt[3]{\mathsf{PI}\left(\right)}, \frac{1}{2} \cdot \pi\right)\right)} \cdot 2\right) \]
    7. Applied rewrites67.8%

      \[\leadsto \left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \color{blue}{\left(\mathsf{fma}\left(\left(angle \cdot 0.005555555555555556\right) \cdot \sqrt[3]{\pi \cdot \pi}, \sqrt[3]{\pi}, 0.5 \cdot \pi\right)\right)} \cdot 2\right) \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 3: 67.8% accurate, 0.9× speedup?

\[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \sqrt[3]{\pi \cdot \pi}\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;angle\_m \leq 8.5 \cdot 10^{+118}:\\ \;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(t\_0 \cdot \left(\sqrt[3]{\pi} \cdot angle\_m\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\left(angle\_m \cdot 0.005555555555555556\right) \cdot t\_0, \sqrt[3]{\pi}, 0.5 \cdot \pi\right)\right) \cdot 2\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 (cbrt (* PI PI))))
   (*
    angle_s
    (if (<= angle_m 8.5e+118)
      (*
       (* (sin (* 0.011111111111111112 (* t_0 (* (cbrt PI) angle_m)))) (- b a))
       (+ b a))
      (*
       (* (* (sin (* (* 0.005555555555555556 angle_m) PI)) (+ a b)) (- b a))
       (*
        (sin
         (fma (* (* angle_m 0.005555555555555556) t_0) (cbrt PI) (* 0.5 PI)))
        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 = cbrt((((double) M_PI) * ((double) M_PI)));
	double tmp;
	if (angle_m <= 8.5e+118) {
		tmp = (sin((0.011111111111111112 * (t_0 * (cbrt(((double) M_PI)) * angle_m)))) * (b - a)) * (b + a);
	} else {
		tmp = ((sin(((0.005555555555555556 * angle_m) * ((double) M_PI))) * (a + b)) * (b - a)) * (sin(fma(((angle_m * 0.005555555555555556) * t_0), cbrt(((double) M_PI)), (0.5 * ((double) M_PI)))) * 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 = cbrt(Float64(pi * pi))
	tmp = 0.0
	if (angle_m <= 8.5e+118)
		tmp = Float64(Float64(sin(Float64(0.011111111111111112 * Float64(t_0 * Float64(cbrt(pi) * angle_m)))) * Float64(b - a)) * Float64(b + a));
	else
		tmp = Float64(Float64(Float64(sin(Float64(Float64(0.005555555555555556 * angle_m) * pi)) * Float64(a + b)) * Float64(b - a)) * Float64(sin(fma(Float64(Float64(angle_m * 0.005555555555555556) * t_0), cbrt(pi), Float64(0.5 * pi))) * 2.0));
	end
	return Float64(angle_s * tmp)
end
angle\_m = N[Abs[angle], $MachinePrecision]
angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[angle$95$s_, a_, b_, angle$95$m_] := Block[{t$95$0 = N[Power[N[(Pi * Pi), $MachinePrecision], 1/3], $MachinePrecision]}, N[(angle$95$s * If[LessEqual[angle$95$m, 8.5e+118], N[(N[(N[Sin[N[(0.011111111111111112 * N[(t$95$0 * N[(N[Power[Pi, 1/3], $MachinePrecision] * angle$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(b + a), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[Sin[N[(N[(0.005555555555555556 * angle$95$m), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(N[Sin[N[(N[(N[(angle$95$m * 0.005555555555555556), $MachinePrecision] * t$95$0), $MachinePrecision] * N[Power[Pi, 1/3], $MachinePrecision] + N[(0.5 * Pi), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
\begin{array}{l}
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

\\
\begin{array}{l}
t_0 := \sqrt[3]{\pi \cdot \pi}\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;angle\_m \leq 8.5 \cdot 10^{+118}:\\
\;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(t\_0 \cdot \left(\sqrt[3]{\pi} \cdot angle\_m\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\

\mathbf{else}:\\
\;\;\;\;\left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\left(angle\_m \cdot 0.005555555555555556\right) \cdot t\_0, \sqrt[3]{\pi}, 0.5 \cdot \pi\right)\right) \cdot 2\right)\\


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

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\sin \left(\frac{1}{90} \cdot \left(\sqrt[3]{\pi \cdot \pi} \cdot \left(\sqrt[3]{\color{blue}{\pi}} \cdot angle\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right) \]
      17. lower-cbrt.f6467.7

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

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

    if 8.50000000000000033e118 < angle

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \color{blue}{\pi \cdot \left(\frac{1}{180} \cdot angle\right)}\right)\right) \cdot 2\right) \]
      12. lower-*.f6467.7

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \pi \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right) \cdot 2\right) \]
      15. lower-*.f6467.7

        \[\leadsto \left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(0.5, \pi, \pi \cdot \color{blue}{\left(angle \cdot 0.005555555555555556\right)}\right)\right) \cdot 2\right) \]
    5. Applied rewrites67.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\frac{angle}{180} \cdot \color{blue}{\mathsf{PI}\left(\right)} + \frac{1}{2} \cdot \pi\right) \cdot 2\right) \]
      22. add-cube-cbrtN/A

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \color{blue}{\left(\mathsf{fma}\left(\frac{angle}{180} \cdot \left(\sqrt[3]{\mathsf{PI}\left(\right)} \cdot \sqrt[3]{\mathsf{PI}\left(\right)}\right), \sqrt[3]{\mathsf{PI}\left(\right)}, \frac{1}{2} \cdot \pi\right)\right)} \cdot 2\right) \]
    7. Applied rewrites67.8%

      \[\leadsto \left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \color{blue}{\left(\mathsf{fma}\left(\left(angle \cdot 0.005555555555555556\right) \cdot \sqrt[3]{\pi \cdot \pi}, \sqrt[3]{\pi}, 0.5 \cdot \pi\right)\right)} \cdot 2\right) \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 4: 67.8% accurate, 1.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 6.4 \cdot 10^{+140}:\\ \;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\pi \cdot \pi} \cdot \left(\sqrt[3]{\pi} \cdot angle\_m\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(2 \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \sin \left(\pi \cdot \frac{angle\_m}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(0.5, \pi, \left|\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right|\right)\right)\\ \end{array} \end{array} \]
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a b angle_m)
 :precision binary64
 (*
  angle_s
  (if (<= angle_m 6.4e+140)
    (*
     (*
      (sin (* 0.011111111111111112 (* (cbrt (* PI PI)) (* (cbrt PI) angle_m))))
      (- b a))
     (+ b a))
    (*
     (* (* 2.0 (* (- b a) (+ b a))) (sin (* PI (/ angle_m 180.0))))
     (sin (fma 0.5 PI (fabs (* (* 0.005555555555555556 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 <= 6.4e+140) {
		tmp = (sin((0.011111111111111112 * (cbrt((((double) M_PI) * ((double) M_PI))) * (cbrt(((double) M_PI)) * angle_m)))) * (b - a)) * (b + a);
	} else {
		tmp = ((2.0 * ((b - a) * (b + a))) * sin((((double) M_PI) * (angle_m / 180.0)))) * sin(fma(0.5, ((double) M_PI), fabs(((0.005555555555555556 * angle_m) * ((double) M_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 <= 6.4e+140)
		tmp = Float64(Float64(sin(Float64(0.011111111111111112 * Float64(cbrt(Float64(pi * pi)) * Float64(cbrt(pi) * angle_m)))) * Float64(b - a)) * Float64(b + a));
	else
		tmp = Float64(Float64(Float64(2.0 * Float64(Float64(b - a) * Float64(b + a))) * sin(Float64(pi * Float64(angle_m / 180.0)))) * sin(fma(0.5, pi, abs(Float64(Float64(0.005555555555555556 * angle_m) * pi)))));
	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, 6.4e+140], N[(N[(N[Sin[N[(0.011111111111111112 * N[(N[Power[N[(Pi * Pi), $MachinePrecision], 1/3], $MachinePrecision] * N[(N[Power[Pi, 1/3], $MachinePrecision] * angle$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(b + a), $MachinePrecision]), $MachinePrecision], N[(N[(N[(2.0 * N[(N[(b - a), $MachinePrecision] * N[(b + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sin[N[(Pi * N[(angle$95$m / 180.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Sin[N[(0.5 * Pi + N[Abs[N[(N[(0.005555555555555556 * angle$95$m), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;angle\_m \leq 6.4 \cdot 10^{+140}:\\
\;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\pi \cdot \pi} \cdot \left(\sqrt[3]{\pi} \cdot angle\_m\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\

\mathbf{else}:\\
\;\;\;\;\left(\left(2 \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \sin \left(\pi \cdot \frac{angle\_m}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(0.5, \pi, \left|\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right|\right)\right)\\


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

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\sin \left(\frac{1}{90} \cdot \left(\sqrt[3]{\pi \cdot \pi} \cdot \left(\sqrt[3]{\color{blue}{\pi}} \cdot angle\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right) \]
      17. lower-cbrt.f6467.7

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

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

    if 6.40000000000000021e140 < angle

    1. Initial program 54.4%

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

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

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

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

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

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

        \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\frac{\color{blue}{\pi}}{2} + \left|\pi \cdot \frac{angle}{180}\right|\right) \]
      7. mult-flipN/A

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

        \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\color{blue}{\frac{1}{2} \cdot \pi} + \left|\pi \cdot \frac{angle}{180}\right|\right) \]
      9. lower-fma.f64N/A

        \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \color{blue}{\left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\pi \cdot \frac{angle}{180}\right|\right)\right)} \]
      10. metadata-evalN/A

        \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\color{blue}{\frac{1}{2}}, \pi, \left|\pi \cdot \frac{angle}{180}\right|\right)\right) \]
      11. lower-fabs.f6454.5

        \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(0.5, \pi, \color{blue}{\left|\pi \cdot \frac{angle}{180}\right|}\right)\right) \]
      12. lift-*.f64N/A

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

        \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\color{blue}{\frac{angle}{180} \cdot \pi}\right|\right)\right) \]
      14. lower-*.f6454.5

        \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(0.5, \pi, \left|\color{blue}{\frac{angle}{180} \cdot \pi}\right|\right)\right) \]
      15. lift-/.f64N/A

        \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\color{blue}{\frac{angle}{180}} \cdot \pi\right|\right)\right) \]
      16. mult-flipN/A

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

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

        \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\color{blue}{\left(\frac{1}{180} \cdot angle\right)} \cdot \pi\right|\right)\right) \]
      19. metadata-eval54.5

        \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(0.5, \pi, \left|\left(\color{blue}{0.005555555555555556} \cdot angle\right) \cdot \pi\right|\right)\right) \]
    3. Applied rewrites54.5%

      \[\leadsto \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \color{blue}{\sin \left(\mathsf{fma}\left(0.5, \pi, \left|\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right|\right)\right)} \]
    4. Step-by-step derivation
      1. lift--.f64N/A

        \[\leadsto \left(\left(2 \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right|\right)\right) \]
      2. lift-pow.f64N/A

        \[\leadsto \left(\left(2 \cdot \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right|\right)\right) \]
      3. pow2N/A

        \[\leadsto \left(\left(2 \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right|\right)\right) \]
      4. lift-pow.f64N/A

        \[\leadsto \left(\left(2 \cdot \left(b \cdot b - \color{blue}{{a}^{2}}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right|\right)\right) \]
      5. unpow2N/A

        \[\leadsto \left(\left(2 \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right|\right)\right) \]
      6. difference-of-squares-revN/A

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

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

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

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

        \[\leadsto \left(\left(2 \cdot \color{blue}{\left(\left(b - a\right) \cdot \left(a + b\right)\right)}\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right|\right)\right) \]
      11. lower-*.f6458.4

        \[\leadsto \left(\left(2 \cdot \color{blue}{\left(\left(b - a\right) \cdot \left(a + b\right)\right)}\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(0.5, \pi, \left|\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right|\right)\right) \]
      12. lift-+.f64N/A

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

        \[\leadsto \left(\left(2 \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(b + a\right)}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \left|\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right|\right)\right) \]
      14. lower-+.f6458.4

        \[\leadsto \left(\left(2 \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(b + a\right)}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(0.5, \pi, \left|\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right|\right)\right) \]
    5. Applied rewrites58.4%

      \[\leadsto \left(\left(2 \cdot \color{blue}{\left(\left(b - a\right) \cdot \left(b + a\right)\right)}\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \sin \left(\mathsf{fma}\left(0.5, \pi, \left|\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right|\right)\right) \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 5: 67.7% accurate, 1.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 5.5 \cdot 10^{+140}:\\ \;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\pi \cdot \pi} \cdot \left(\sqrt[3]{\pi} \cdot angle\_m\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\pi \cdot \mathsf{fma}\left(angle\_m, 0.005555555555555556, 0.5\right)\right) \cdot 2\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 5.5e+140)
    (*
     (*
      (sin (* 0.011111111111111112 (* (cbrt (* PI PI)) (* (cbrt PI) angle_m))))
      (- b a))
     (+ b a))
    (*
     (* (* (sin (* (* 0.005555555555555556 angle_m) PI)) (+ a b)) (- b a))
     (* (sin (* PI (fma angle_m 0.005555555555555556 0.5))) 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 <= 5.5e+140) {
		tmp = (sin((0.011111111111111112 * (cbrt((((double) M_PI) * ((double) M_PI))) * (cbrt(((double) M_PI)) * angle_m)))) * (b - a)) * (b + a);
	} else {
		tmp = ((sin(((0.005555555555555556 * angle_m) * ((double) M_PI))) * (a + b)) * (b - a)) * (sin((((double) M_PI) * fma(angle_m, 0.005555555555555556, 0.5))) * 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 <= 5.5e+140)
		tmp = Float64(Float64(sin(Float64(0.011111111111111112 * Float64(cbrt(Float64(pi * pi)) * Float64(cbrt(pi) * angle_m)))) * Float64(b - a)) * Float64(b + a));
	else
		tmp = Float64(Float64(Float64(sin(Float64(Float64(0.005555555555555556 * angle_m) * pi)) * Float64(a + b)) * Float64(b - a)) * Float64(sin(Float64(pi * fma(angle_m, 0.005555555555555556, 0.5))) * 2.0));
	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, 5.5e+140], N[(N[(N[Sin[N[(0.011111111111111112 * N[(N[Power[N[(Pi * Pi), $MachinePrecision], 1/3], $MachinePrecision] * N[(N[Power[Pi, 1/3], $MachinePrecision] * angle$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(b + a), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[Sin[N[(N[(0.005555555555555556 * angle$95$m), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(N[Sin[N[(Pi * N[(angle$95$m * 0.005555555555555556 + 0.5), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * 2.0), $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 5.5 \cdot 10^{+140}:\\
\;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\pi \cdot \pi} \cdot \left(\sqrt[3]{\pi} \cdot angle\_m\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\

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


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

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\sin \left(\frac{1}{90} \cdot \left(\sqrt[3]{\pi \cdot \pi} \cdot \left(\sqrt[3]{\color{blue}{\pi}} \cdot angle\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right) \]
      17. lower-cbrt.f6467.7

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

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

    if 5.5e140 < angle

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \color{blue}{\pi \cdot \left(\frac{1}{180} \cdot angle\right)}\right)\right) \cdot 2\right) \]
      12. lower-*.f6467.7

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

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

        \[\leadsto \left(\left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(\frac{1}{2}, \pi, \pi \cdot \color{blue}{\left(angle \cdot \frac{1}{180}\right)}\right)\right) \cdot 2\right) \]
      15. lower-*.f6467.7

        \[\leadsto \left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\mathsf{fma}\left(0.5, \pi, \pi \cdot \color{blue}{\left(angle \cdot 0.005555555555555556\right)}\right)\right) \cdot 2\right) \]
    5. Applied rewrites67.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \left(b - a\right)\right) \cdot \left(\sin \left(\pi \cdot \color{blue}{\mathsf{fma}\left(angle, 0.005555555555555556, 0.5\right)}\right) \cdot 2\right) \]
    7. Applied rewrites67.7%

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

Alternative 6: 67.6% accurate, 1.3× speedup?

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

\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;a \leq 1.5 \cdot 10^{+154}:\\
\;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\pi \cdot \pi} \cdot \left(\sqrt[3]{\pi} \cdot angle\_m\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < 1.50000000000000013e154

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\sin \left(\frac{1}{90} \cdot \left(\sqrt[3]{\pi \cdot \pi} \cdot \left(\sqrt[3]{\color{blue}{\pi}} \cdot angle\right)\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right) \]
      17. lower-cbrt.f6467.7

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

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

    if 1.50000000000000013e154 < a

    1. Initial program 54.4%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. 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. lower-*.f64N/A

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
      7. lower-pow.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
    4. Applied rewrites51.2%

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
      6. lower-*.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
      7. lift--.f64N/A

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
      18. lift-+.f64N/A

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
      9. lower-*.f6462.5

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\frac{1}{90} \cdot \left(b - a\right)\right) \cdot \left(\left(\left(b + a\right) \cdot \pi\right) \cdot \color{blue}{angle}\right) \]
      9. lower-*.f6462.7

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

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

Alternative 7: 67.6% accurate, 1.3× speedup?

\[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;2 \cdot \left({b}^{2} - {a}^{2}\right) \leq -2 \cdot 10^{+301}:\\ \;\;\;\;\left(0.011111111111111112 \cdot \left(b - a\right)\right) \cdot \left(\left(\left(b + a\right) \cdot \pi\right) \cdot angle\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\sin \left(\left(0.011111111111111112 \cdot angle\_m\right) \cdot \pi\right) \cdot \left(b - a\right)\right) \cdot \left(b + 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 (<= (* 2.0 (- (pow b 2.0) (pow a 2.0))) -2e+301)
    (* (* 0.011111111111111112 (- b a)) (* (* (+ b a) PI) angle_m))
    (* (* (sin (* (* 0.011111111111111112 angle_m) PI)) (- b a)) (+ b a)))))
angle\_m = fabs(angle);
angle\_s = copysign(1.0, angle);
double code(double angle_s, double a, double b, double angle_m) {
	double tmp;
	if ((2.0 * (pow(b, 2.0) - pow(a, 2.0))) <= -2e+301) {
		tmp = (0.011111111111111112 * (b - a)) * (((b + a) * ((double) M_PI)) * angle_m);
	} else {
		tmp = (sin(((0.011111111111111112 * angle_m) * ((double) M_PI))) * (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 ((2.0 * (Math.pow(b, 2.0) - Math.pow(a, 2.0))) <= -2e+301) {
		tmp = (0.011111111111111112 * (b - a)) * (((b + a) * Math.PI) * angle_m);
	} else {
		tmp = (Math.sin(((0.011111111111111112 * angle_m) * Math.PI)) * (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 (2.0 * (math.pow(b, 2.0) - math.pow(a, 2.0))) <= -2e+301:
		tmp = (0.011111111111111112 * (b - a)) * (((b + a) * math.pi) * angle_m)
	else:
		tmp = (math.sin(((0.011111111111111112 * angle_m) * math.pi)) * (b - a)) * (b + a)
	return angle_s * tmp
angle\_m = abs(angle)
angle\_s = copysign(1.0, angle)
function code(angle_s, a, b, angle_m)
	tmp = 0.0
	if (Float64(2.0 * Float64((b ^ 2.0) - (a ^ 2.0))) <= -2e+301)
		tmp = Float64(Float64(0.011111111111111112 * Float64(b - a)) * Float64(Float64(Float64(b + a) * pi) * angle_m));
	else
		tmp = Float64(Float64(sin(Float64(Float64(0.011111111111111112 * angle_m) * pi)) * 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 ((2.0 * ((b ^ 2.0) - (a ^ 2.0))) <= -2e+301)
		tmp = (0.011111111111111112 * (b - a)) * (((b + a) * pi) * angle_m);
	else
		tmp = (sin(((0.011111111111111112 * angle_m) * pi)) * (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[N[(2.0 * N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -2e+301], N[(N[(0.011111111111111112 * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(b + a), $MachinePrecision] * Pi), $MachinePrecision] * angle$95$m), $MachinePrecision]), $MachinePrecision], N[(N[(N[Sin[N[(N[(0.011111111111111112 * angle$95$m), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision] * N[(b - a), $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 \begin{array}{l}
\mathbf{if}\;2 \cdot \left({b}^{2} - {a}^{2}\right) \leq -2 \cdot 10^{+301}:\\
\;\;\;\;\left(0.011111111111111112 \cdot \left(b - a\right)\right) \cdot \left(\left(\left(b + a\right) \cdot \pi\right) \cdot angle\_m\right)\\

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


\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)))) < -2.00000000000000011e301

    1. Initial program 54.4%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. 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. lower-*.f64N/A

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
      7. lower-pow.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
    4. Applied rewrites51.2%

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
      6. lower-*.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
      7. lift--.f64N/A

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
      18. lift-+.f64N/A

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
      9. lower-*.f6462.5

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\frac{1}{90} \cdot \left(b - a\right)\right) \cdot \left(\left(\left(b + a\right) \cdot \pi\right) \cdot \color{blue}{angle}\right) \]
      9. lower-*.f6462.7

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

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

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

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\sin \color{blue}{\left(\left(\frac{1}{90} \cdot angle\right) \cdot \pi\right)} \cdot \left(b - a\right)\right) \cdot \left(b + a\right) \]
      6. lower-*.f6467.6

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

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

Alternative 8: 67.5% accurate, 0.7× speedup?

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

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

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


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

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

    1. Initial program 54.4%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. 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. lower-*.f64N/A

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
      7. lower-pow.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
    4. Applied rewrites51.2%

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
      6. lower-*.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
      7. lift--.f64N/A

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
      18. lift-+.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 9: 67.2% 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(0.011111111111111112 \cdot \pi\right) \cdot angle\_m\right) \cdot \left(b - a\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 (* (* 0.011111111111111112 PI) angle_m)) (- 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) {
	return angle_s * ((sin(((0.011111111111111112 * ((double) M_PI)) * angle_m)) * (b - a)) * (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(((0.011111111111111112 * Math.PI) * angle_m)) * (b - a)) * (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(((0.011111111111111112 * math.pi) * angle_m)) * (b - a)) * (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(0.011111111111111112 * pi) * angle_m)) * Float64(b - a)) * 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(((0.011111111111111112 * pi) * angle_m)) * (b - a)) * (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[(0.011111111111111112 * Pi), $MachinePrecision] * angle$95$m), $MachinePrecision]], $MachinePrecision] * N[(b - a), $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(0.011111111111111112 \cdot \pi\right) \cdot angle\_m\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\right)
\end{array}
Derivation
  1. Initial program 54.4%

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

      \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 10: 65.6% accurate, 1.8× speedup?

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (pow.f64 a #s(literal 2 binary64)) < 1.9999999999999999e-178

    1. Initial program 54.4%

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

        \[\leadsto \color{blue}{\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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 1.9999999999999999e-178 < (pow.f64 a #s(literal 2 binary64))

    1. Initial program 54.4%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. 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. lower-*.f64N/A

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
      7. lower-pow.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
    4. Applied rewrites51.2%

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
      6. lower-*.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
      7. lift--.f64N/A

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
      18. lift-+.f64N/A

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
      9. lower-*.f6462.5

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\frac{1}{90} \cdot \left(b - a\right)\right) \cdot \left(\left(\left(b + a\right) \cdot \pi\right) \cdot \color{blue}{angle}\right) \]
      9. lower-*.f6462.7

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

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

Alternative 11: 62.7% accurate, 6.6× speedup?

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

\\
angle\_s \cdot \left(\left(\left(0.011111111111111112 \cdot \left(\left(b - a\right) \cdot angle\_m\right)\right) \cdot \left(b + a\right)\right) \cdot \pi\right)
\end{array}
Derivation
  1. Initial program 54.4%

    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
  2. 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. lower-*.f64N/A

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
    7. lower-pow.f6451.2

      \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
  4. Applied rewrites51.2%

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
    6. lower-*.f6451.2

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
    7. lift--.f64N/A

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
    18. lift-+.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 12: 62.6% accurate, 6.6× 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 \left(b - a\right)\right) \cdot \left(\left(\left(b + a\right) \cdot \pi\right) \cdot angle\_m\right)\right) \end{array} \]
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a b angle_m)
 :precision binary64
 (* angle_s (* (* 0.011111111111111112 (- b a)) (* (* (+ b a) PI) angle_m))))
angle\_m = fabs(angle);
angle\_s = copysign(1.0, angle);
double code(double angle_s, double a, double b, double angle_m) {
	return angle_s * ((0.011111111111111112 * (b - a)) * (((b + a) * ((double) M_PI)) * angle_m));
}
angle\_m = Math.abs(angle);
angle\_s = Math.copySign(1.0, angle);
public static double code(double angle_s, double a, double b, double angle_m) {
	return angle_s * ((0.011111111111111112 * (b - a)) * (((b + a) * Math.PI) * angle_m));
}
angle\_m = math.fabs(angle)
angle\_s = math.copysign(1.0, angle)
def code(angle_s, a, b, angle_m):
	return angle_s * ((0.011111111111111112 * (b - a)) * (((b + a) * math.pi) * angle_m))
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 * Float64(b - a)) * Float64(Float64(Float64(b + a) * pi) * angle_m)))
end
angle\_m = abs(angle);
angle\_s = sign(angle) * abs(1.0);
function tmp = code(angle_s, a, b, angle_m)
	tmp = angle_s * ((0.011111111111111112 * (b - a)) * (((b + a) * pi) * angle_m));
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 * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(b + a), $MachinePrecision] * Pi), $MachinePrecision] * angle$95$m), $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 \left(b - a\right)\right) \cdot \left(\left(\left(b + a\right) \cdot \pi\right) \cdot angle\_m\right)\right)
\end{array}
Derivation
  1. Initial program 54.4%

    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
  2. 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. lower-*.f64N/A

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
    7. lower-pow.f6451.2

      \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
  4. Applied rewrites51.2%

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
    6. lower-*.f6451.2

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
    7. lift--.f64N/A

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
    18. lift-+.f64N/A

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
    9. lower-*.f6462.5

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

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

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

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

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

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

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

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

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

      \[\leadsto \left(\frac{1}{90} \cdot \left(b - a\right)\right) \cdot \left(\left(\left(b + a\right) \cdot \pi\right) \cdot \color{blue}{angle}\right) \]
    9. lower-*.f6462.7

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

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

Alternative 13: 62.5% accurate, 6.6× speedup?

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

\\
angle\_s \cdot \left(0.011111111111111112 \cdot \left(\left(b - a\right) \cdot \left(\left(\left(b + a\right) \cdot \pi\right) \cdot angle\_m\right)\right)\right)
\end{array}
Derivation
  1. Initial program 54.4%

    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
  2. 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. lower-*.f64N/A

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
    7. lower-pow.f6451.2

      \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
  4. Applied rewrites51.2%

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
    6. lower-*.f6451.2

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
    7. lift--.f64N/A

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
    18. lift-+.f64N/A

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
    9. lower-*.f6462.5

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

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(\left(b - a\right) \cdot \left(\left(\left(b + a\right) \cdot \pi\right) \cdot \color{blue}{angle}\right)\right) \]
    6. lower-*.f6462.5

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

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

Alternative 14: 62.5% accurate, 6.6× speedup?

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

\\
angle\_s \cdot \left(0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\_m\right) \cdot \left(\left(b + a\right) \cdot \pi\right)\right)\right)
\end{array}
Derivation
  1. Initial program 54.4%

    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
  2. 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. lower-*.f64N/A

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
    7. lower-pow.f6451.2

      \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
  4. Applied rewrites51.2%

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
    6. lower-*.f6451.2

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
    7. lift--.f64N/A

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
    18. lift-+.f64N/A

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
    9. lower-*.f6462.5

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

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

Alternative 15: 61.2% accurate, 2.1× speedup?

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

\\
\begin{array}{l}
t_0 := \left(b - a\right) \cdot angle\_m\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;2 \cdot \left({b}^{2} - {a}^{2}\right) \leq 2 \cdot 10^{-248}:\\
\;\;\;\;0.011111111111111112 \cdot \left(t\_0 \cdot \left(a \cdot \pi\right)\right)\\

\mathbf{else}:\\
\;\;\;\;0.011111111111111112 \cdot \left(t\_0 \cdot \left(b \cdot \pi\right)\right)\\


\end{array}
\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.99999999999999996e-248

    1. Initial program 54.4%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. 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. lower-*.f64N/A

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
      7. lower-pow.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
    4. Applied rewrites51.2%

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
      6. lower-*.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
      7. lift--.f64N/A

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
      18. lift-+.f64N/A

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
      9. lower-*.f6462.5

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

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

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

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

        \[\leadsto 0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(a \cdot \pi\right)\right) \]
    11. Applied rewrites41.4%

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

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

    1. Initial program 54.4%

      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
    2. 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. lower-*.f64N/A

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
      7. lower-pow.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
    4. Applied rewrites51.2%

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

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
      6. lower-*.f6451.2

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
      7. lift--.f64N/A

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
      18. lift-+.f64N/A

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

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

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

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

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \color{blue}{\pi}\right) \]
      2. lift-*.f64N/A

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \pi\right) \]
      3. lift-*.f64N/A

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \pi\right) \]
      4. associate-*r*N/A

        \[\leadsto \frac{1}{90} \cdot \left(\left(\left(angle \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\right) \cdot \pi\right) \]
      5. associate-*l*N/A

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(b - a\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \pi\right)}\right) \]
      6. lower-*.f64N/A

        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(b - a\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \pi\right)}\right) \]
      7. *-commutativeN/A

        \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
      8. lower-*.f64N/A

        \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
      9. lower-*.f6462.5

        \[\leadsto 0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\pi}\right)\right) \]
    8. Applied rewrites62.5%

      \[\leadsto 0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \pi\right)}\right) \]
    9. Taylor expanded in a around 0

      \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(b \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \]
    10. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(b \cdot \mathsf{PI}\left(\right)\right)\right) \]
      2. lower-PI.f6442.1

        \[\leadsto 0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(b \cdot \pi\right)\right) \]
    11. Applied rewrites42.1%

      \[\leadsto 0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(b \cdot \color{blue}{\pi}\right)\right) \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 16: 41.4% accurate, 7.8× speedup?

\[\begin{array}{l} angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\_m\right) \cdot \left(a \cdot \pi\right)\right)\right) \end{array} \]
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a b angle_m)
 :precision binary64
 (* angle_s (* 0.011111111111111112 (* (* (- b a) angle_m) (* a PI)))))
angle\_m = fabs(angle);
angle\_s = copysign(1.0, angle);
double code(double angle_s, double a, double b, double angle_m) {
	return angle_s * (0.011111111111111112 * (((b - a) * angle_m) * (a * ((double) M_PI))));
}
angle\_m = Math.abs(angle);
angle\_s = Math.copySign(1.0, angle);
public static double code(double angle_s, double a, double b, double angle_m) {
	return angle_s * (0.011111111111111112 * (((b - a) * angle_m) * (a * Math.PI)));
}
angle\_m = math.fabs(angle)
angle\_s = math.copysign(1.0, angle)
def code(angle_s, a, b, angle_m):
	return angle_s * (0.011111111111111112 * (((b - a) * angle_m) * (a * math.pi)))
angle\_m = abs(angle)
angle\_s = copysign(1.0, angle)
function code(angle_s, a, b, angle_m)
	return Float64(angle_s * Float64(0.011111111111111112 * Float64(Float64(Float64(b - a) * angle_m) * Float64(a * pi))))
end
angle\_m = abs(angle);
angle\_s = sign(angle) * abs(1.0);
function tmp = code(angle_s, a, b, angle_m)
	tmp = angle_s * (0.011111111111111112 * (((b - a) * angle_m) * (a * pi)));
end
angle\_m = N[Abs[angle], $MachinePrecision]
angle\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[angle$95$s_, a_, b_, angle$95$m_] := N[(angle$95$s * N[(0.011111111111111112 * N[(N[(N[(b - a), $MachinePrecision] * angle$95$m), $MachinePrecision] * N[(a * Pi), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

\\
angle\_s \cdot \left(0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\_m\right) \cdot \left(a \cdot \pi\right)\right)\right)
\end{array}
Derivation
  1. Initial program 54.4%

    \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
  2. 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. lower-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \color{blue}{\left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
    2. lower-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)}\right) \]
    3. lower-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right)\right) \]
    4. lower-PI.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\color{blue}{{b}^{2}} - {a}^{2}\right)\right)\right) \]
    5. lower--.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - \color{blue}{{a}^{2}}\right)\right)\right) \]
    6. lower-pow.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {\color{blue}{a}}^{2}\right)\right)\right) \]
    7. lower-pow.f6451.2

      \[\leadsto 0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{\color{blue}{2}}\right)\right)\right) \]
  4. Applied rewrites51.2%

    \[\leadsto \color{blue}{0.011111111111111112 \cdot \left(angle \cdot \left(\pi \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
  5. Step-by-step derivation
    1. lift-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \color{blue}{\left(\pi \cdot \left({b}^{2} - {a}^{2}\right)\right)}\right) \]
    2. lift-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \color{blue}{\left({b}^{2} - {a}^{2}\right)}\right)\right) \]
    3. *-commutativeN/A

      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\left({b}^{2} - {a}^{2}\right) \cdot \color{blue}{\pi}\right)\right) \]
    4. associate-*r*N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
    5. lower-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \color{blue}{\pi}\right) \]
    6. lower-*.f6451.2

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
    7. lift--.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
    8. lift-pow.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \pi\right) \]
    9. pow2N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \pi\right) \]
    10. lift-pow.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(b \cdot b - {a}^{2}\right)\right) \cdot \pi\right) \]
    11. unpow2N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \pi\right) \]
    12. difference-of-squares-revN/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right) \cdot \pi\right) \]
    13. +-commutativeN/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(a + b\right) \cdot \left(b - a\right)\right)\right) \cdot \pi\right) \]
    14. lift-+.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(a + b\right) \cdot \left(b - a\right)\right)\right) \cdot \pi\right) \]
    15. lift--.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(a + b\right) \cdot \left(b - a\right)\right)\right) \cdot \pi\right) \]
    16. *-commutativeN/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
    17. lower-*.f6455.1

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
    18. lift-+.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
    19. +-commutativeN/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \pi\right) \]
    20. lower-+.f6455.1

      \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \pi\right) \]
  6. Applied rewrites55.1%

    \[\leadsto 0.011111111111111112 \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \color{blue}{\pi}\right) \]
  7. Step-by-step derivation
    1. lift-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \color{blue}{\pi}\right) \]
    2. lift-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \pi\right) \]
    3. lift-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right) \cdot \pi\right) \]
    4. associate-*r*N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(\left(angle \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\right) \cdot \pi\right) \]
    5. associate-*l*N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(b - a\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \pi\right)}\right) \]
    6. lower-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(b - a\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \pi\right)}\right) \]
    7. *-commutativeN/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
    8. lower-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \pi\right)\right) \]
    9. lower-*.f6462.5

      \[\leadsto 0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\pi}\right)\right) \]
  8. Applied rewrites62.5%

    \[\leadsto 0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \pi\right)}\right) \]
  9. Taylor expanded in a around inf

    \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(a \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \]
  10. Step-by-step derivation
    1. lower-*.f64N/A

      \[\leadsto \frac{1}{90} \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(a \cdot \mathsf{PI}\left(\right)\right)\right) \]
    2. lower-PI.f6441.4

      \[\leadsto 0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(a \cdot \pi\right)\right) \]
  11. Applied rewrites41.4%

    \[\leadsto 0.011111111111111112 \cdot \left(\left(\left(b - a\right) \cdot angle\right) \cdot \left(a \cdot \color{blue}{\pi}\right)\right) \]
  12. Add Preprocessing

Reproduce

?
herbie shell --seed 2025159 
(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)))))