ab-angle->ABCF B

Percentage Accurate: 53.9% → 66.9%
Time: 14.1s
Alternatives: 19
Speedup: 16.8×

Specification

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

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 19 alternatives:

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

Initial Program: 53.9% accurate, 1.0× speedup?

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

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

Alternative 1: 66.9% accurate, 1.2× speedup?

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

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

\mathbf{else}:\\
\;\;\;\;1 \cdot t\_0\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (pow.f64 b #s(literal 2 binary64)) < 1e103

    1. Initial program 60.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 1e103 < (pow.f64 b #s(literal 2 binary64))

    1. Initial program 45.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    Alternative 2: 66.9% accurate, 1.3× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_0 := \left(\left(\sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\\ \mathbf{if}\;{b}^{2} \leq 10^{+197}:\\ \;\;\;\;\cos \left(\left(\pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot t\_0\\ \mathbf{else}:\\ \;\;\;\;1 \cdot t\_0\\ \end{array} \end{array} \]
    (FPCore (a b angle)
     :precision binary64
     (let* ((t_0
             (*
              (* (* (sin (* PI (* angle 0.005555555555555556))) 2.0) (- b a))
              (+ a b))))
       (if (<= (pow b 2.0) 1e+197)
         (* (cos (* (* PI 0.005555555555555556) angle)) t_0)
         (* 1.0 t_0))))
    double code(double a, double b, double angle) {
    	double t_0 = ((sin((((double) M_PI) * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b);
    	double tmp;
    	if (pow(b, 2.0) <= 1e+197) {
    		tmp = cos(((((double) M_PI) * 0.005555555555555556) * angle)) * t_0;
    	} else {
    		tmp = 1.0 * t_0;
    	}
    	return tmp;
    }
    
    public static double code(double a, double b, double angle) {
    	double t_0 = ((Math.sin((Math.PI * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b);
    	double tmp;
    	if (Math.pow(b, 2.0) <= 1e+197) {
    		tmp = Math.cos(((Math.PI * 0.005555555555555556) * angle)) * t_0;
    	} else {
    		tmp = 1.0 * t_0;
    	}
    	return tmp;
    }
    
    def code(a, b, angle):
    	t_0 = ((math.sin((math.pi * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b)
    	tmp = 0
    	if math.pow(b, 2.0) <= 1e+197:
    		tmp = math.cos(((math.pi * 0.005555555555555556) * angle)) * t_0
    	else:
    		tmp = 1.0 * t_0
    	return tmp
    
    function code(a, b, angle)
    	t_0 = Float64(Float64(Float64(sin(Float64(pi * Float64(angle * 0.005555555555555556))) * 2.0) * Float64(b - a)) * Float64(a + b))
    	tmp = 0.0
    	if ((b ^ 2.0) <= 1e+197)
    		tmp = Float64(cos(Float64(Float64(pi * 0.005555555555555556) * angle)) * t_0);
    	else
    		tmp = Float64(1.0 * t_0);
    	end
    	return tmp
    end
    
    function tmp_2 = code(a, b, angle)
    	t_0 = ((sin((pi * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b);
    	tmp = 0.0;
    	if ((b ^ 2.0) <= 1e+197)
    		tmp = cos(((pi * 0.005555555555555556) * angle)) * t_0;
    	else
    		tmp = 1.0 * t_0;
    	end
    	tmp_2 = tmp;
    end
    
    code[a_, b_, angle_] := Block[{t$95$0 = N[(N[(N[(N[Sin[N[(Pi * N[(angle * 0.005555555555555556), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * 2.0), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[b, 2.0], $MachinePrecision], 1e+197], N[(N[Cos[N[(N[(Pi * 0.005555555555555556), $MachinePrecision] * angle), $MachinePrecision]], $MachinePrecision] * t$95$0), $MachinePrecision], N[(1.0 * t$95$0), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_0 := \left(\left(\sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\\
    \mathbf{if}\;{b}^{2} \leq 10^{+197}:\\
    \;\;\;\;\cos \left(\left(\pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot t\_0\\
    
    \mathbf{else}:\\
    \;\;\;\;1 \cdot t\_0\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if (pow.f64 b #s(literal 2 binary64)) < 9.9999999999999995e196

      1. Initial program 60.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if 9.9999999999999995e196 < (pow.f64 b #s(literal 2 binary64))

      1. Initial program 41.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      Alternative 3: 66.4% accurate, 1.9× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;{b}^{2} \leq 10^{-127}:\\ \;\;\;\;\left(\left(0.5 \cdot \sin \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\right) \cdot \left(\left(b - a\right) \cdot 2\right)\right) \cdot \left(a + b\right)\\ \mathbf{else}:\\ \;\;\;\;1 \cdot \left(\left(\left(\sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right)\\ \end{array} \end{array} \]
      (FPCore (a b angle)
       :precision binary64
       (if (<= (pow b 2.0) 1e-127)
         (*
          (* (* 0.5 (sin (* (* 0.011111111111111112 angle) PI))) (* (- b a) 2.0))
          (+ a b))
         (*
          1.0
          (*
           (* (* (sin (* PI (* angle 0.005555555555555556))) 2.0) (- b a))
           (+ a b)))))
      double code(double a, double b, double angle) {
      	double tmp;
      	if (pow(b, 2.0) <= 1e-127) {
      		tmp = ((0.5 * sin(((0.011111111111111112 * angle) * ((double) M_PI)))) * ((b - a) * 2.0)) * (a + b);
      	} else {
      		tmp = 1.0 * (((sin((((double) M_PI) * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b));
      	}
      	return tmp;
      }
      
      public static double code(double a, double b, double angle) {
      	double tmp;
      	if (Math.pow(b, 2.0) <= 1e-127) {
      		tmp = ((0.5 * Math.sin(((0.011111111111111112 * angle) * Math.PI))) * ((b - a) * 2.0)) * (a + b);
      	} else {
      		tmp = 1.0 * (((Math.sin((Math.PI * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b));
      	}
      	return tmp;
      }
      
      def code(a, b, angle):
      	tmp = 0
      	if math.pow(b, 2.0) <= 1e-127:
      		tmp = ((0.5 * math.sin(((0.011111111111111112 * angle) * math.pi))) * ((b - a) * 2.0)) * (a + b)
      	else:
      		tmp = 1.0 * (((math.sin((math.pi * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b))
      	return tmp
      
      function code(a, b, angle)
      	tmp = 0.0
      	if ((b ^ 2.0) <= 1e-127)
      		tmp = Float64(Float64(Float64(0.5 * sin(Float64(Float64(0.011111111111111112 * angle) * pi))) * Float64(Float64(b - a) * 2.0)) * Float64(a + b));
      	else
      		tmp = Float64(1.0 * Float64(Float64(Float64(sin(Float64(pi * Float64(angle * 0.005555555555555556))) * 2.0) * Float64(b - a)) * Float64(a + b)));
      	end
      	return tmp
      end
      
      function tmp_2 = code(a, b, angle)
      	tmp = 0.0;
      	if ((b ^ 2.0) <= 1e-127)
      		tmp = ((0.5 * sin(((0.011111111111111112 * angle) * pi))) * ((b - a) * 2.0)) * (a + b);
      	else
      		tmp = 1.0 * (((sin((pi * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b));
      	end
      	tmp_2 = tmp;
      end
      
      code[a_, b_, angle_] := If[LessEqual[N[Power[b, 2.0], $MachinePrecision], 1e-127], N[(N[(N[(0.5 * N[Sin[N[(N[(0.011111111111111112 * angle), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision], N[(1.0 * N[(N[(N[(N[Sin[N[(Pi * N[(angle * 0.005555555555555556), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * 2.0), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      \mathbf{if}\;{b}^{2} \leq 10^{-127}:\\
      \;\;\;\;\left(\left(0.5 \cdot \sin \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\right) \cdot \left(\left(b - a\right) \cdot 2\right)\right) \cdot \left(a + b\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;1 \cdot \left(\left(\left(\sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right)\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if (pow.f64 b #s(literal 2 binary64)) < 1e-127

        1. Initial program 60.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        if 1e-127 < (pow.f64 b #s(literal 2 binary64))

        1. Initial program 49.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        Alternative 4: 66.4% accurate, 1.9× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;{b}^{2} \leq 2 \cdot 10^{-150}:\\ \;\;\;\;\left(\sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\\ \mathbf{else}:\\ \;\;\;\;1 \cdot \left(\left(\left(\sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right)\\ \end{array} \end{array} \]
        (FPCore (a b angle)
         :precision binary64
         (if (<= (pow b 2.0) 2e-150)
           (* (* (sin (* (* PI angle) 0.011111111111111112)) (- b a)) (+ a b))
           (*
            1.0
            (*
             (* (* (sin (* PI (* angle 0.005555555555555556))) 2.0) (- b a))
             (+ a b)))))
        double code(double a, double b, double angle) {
        	double tmp;
        	if (pow(b, 2.0) <= 2e-150) {
        		tmp = (sin(((((double) M_PI) * angle) * 0.011111111111111112)) * (b - a)) * (a + b);
        	} else {
        		tmp = 1.0 * (((sin((((double) M_PI) * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b));
        	}
        	return tmp;
        }
        
        public static double code(double a, double b, double angle) {
        	double tmp;
        	if (Math.pow(b, 2.0) <= 2e-150) {
        		tmp = (Math.sin(((Math.PI * angle) * 0.011111111111111112)) * (b - a)) * (a + b);
        	} else {
        		tmp = 1.0 * (((Math.sin((Math.PI * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b));
        	}
        	return tmp;
        }
        
        def code(a, b, angle):
        	tmp = 0
        	if math.pow(b, 2.0) <= 2e-150:
        		tmp = (math.sin(((math.pi * angle) * 0.011111111111111112)) * (b - a)) * (a + b)
        	else:
        		tmp = 1.0 * (((math.sin((math.pi * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b))
        	return tmp
        
        function code(a, b, angle)
        	tmp = 0.0
        	if ((b ^ 2.0) <= 2e-150)
        		tmp = Float64(Float64(sin(Float64(Float64(pi * angle) * 0.011111111111111112)) * Float64(b - a)) * Float64(a + b));
        	else
        		tmp = Float64(1.0 * Float64(Float64(Float64(sin(Float64(pi * Float64(angle * 0.005555555555555556))) * 2.0) * Float64(b - a)) * Float64(a + b)));
        	end
        	return tmp
        end
        
        function tmp_2 = code(a, b, angle)
        	tmp = 0.0;
        	if ((b ^ 2.0) <= 2e-150)
        		tmp = (sin(((pi * angle) * 0.011111111111111112)) * (b - a)) * (a + b);
        	else
        		tmp = 1.0 * (((sin((pi * (angle * 0.005555555555555556))) * 2.0) * (b - a)) * (a + b));
        	end
        	tmp_2 = tmp;
        end
        
        code[a_, b_, angle_] := If[LessEqual[N[Power[b, 2.0], $MachinePrecision], 2e-150], N[(N[(N[Sin[N[(N[(Pi * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]], $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision], N[(1.0 * N[(N[(N[(N[Sin[N[(Pi * N[(angle * 0.005555555555555556), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * 2.0), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        \mathbf{if}\;{b}^{2} \leq 2 \cdot 10^{-150}:\\
        \;\;\;\;\left(\sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\\
        
        \mathbf{else}:\\
        \;\;\;\;1 \cdot \left(\left(\left(\sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right)\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if (pow.f64 b #s(literal 2 binary64)) < 2.00000000000000001e-150

          1. Initial program 61.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          if 2.00000000000000001e-150 < (pow.f64 b #s(literal 2 binary64))

          1. Initial program 49.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          Alternative 5: 57.2% accurate, 2.0× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;{b}^{2} - {a}^{2} \leq -5 \cdot 10^{-254}:\\ \;\;\;\;\left(\left(-0.011111111111111112 \cdot a\right) \cdot angle\right) \cdot \left(\pi \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(b \cdot b\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\\ \end{array} \end{array} \]
          (FPCore (a b angle)
           :precision binary64
           (if (<= (- (pow b 2.0) (pow a 2.0)) -5e-254)
             (* (* (* -0.011111111111111112 a) angle) (* PI a))
             (* (* (* (* b b) PI) angle) 0.011111111111111112)))
          double code(double a, double b, double angle) {
          	double tmp;
          	if ((pow(b, 2.0) - pow(a, 2.0)) <= -5e-254) {
          		tmp = ((-0.011111111111111112 * a) * angle) * (((double) M_PI) * a);
          	} else {
          		tmp = (((b * b) * ((double) M_PI)) * angle) * 0.011111111111111112;
          	}
          	return tmp;
          }
          
          public static double code(double a, double b, double angle) {
          	double tmp;
          	if ((Math.pow(b, 2.0) - Math.pow(a, 2.0)) <= -5e-254) {
          		tmp = ((-0.011111111111111112 * a) * angle) * (Math.PI * a);
          	} else {
          		tmp = (((b * b) * Math.PI) * angle) * 0.011111111111111112;
          	}
          	return tmp;
          }
          
          def code(a, b, angle):
          	tmp = 0
          	if (math.pow(b, 2.0) - math.pow(a, 2.0)) <= -5e-254:
          		tmp = ((-0.011111111111111112 * a) * angle) * (math.pi * a)
          	else:
          		tmp = (((b * b) * math.pi) * angle) * 0.011111111111111112
          	return tmp
          
          function code(a, b, angle)
          	tmp = 0.0
          	if (Float64((b ^ 2.0) - (a ^ 2.0)) <= -5e-254)
          		tmp = Float64(Float64(Float64(-0.011111111111111112 * a) * angle) * Float64(pi * a));
          	else
          		tmp = Float64(Float64(Float64(Float64(b * b) * pi) * angle) * 0.011111111111111112);
          	end
          	return tmp
          end
          
          function tmp_2 = code(a, b, angle)
          	tmp = 0.0;
          	if (((b ^ 2.0) - (a ^ 2.0)) <= -5e-254)
          		tmp = ((-0.011111111111111112 * a) * angle) * (pi * a);
          	else
          		tmp = (((b * b) * pi) * angle) * 0.011111111111111112;
          	end
          	tmp_2 = tmp;
          end
          
          code[a_, b_, angle_] := If[LessEqual[N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision], -5e-254], N[(N[(N[(-0.011111111111111112 * a), $MachinePrecision] * angle), $MachinePrecision] * N[(Pi * a), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(b * b), $MachinePrecision] * Pi), $MachinePrecision] * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          \mathbf{if}\;{b}^{2} - {a}^{2} \leq -5 \cdot 10^{-254}:\\
          \;\;\;\;\left(\left(-0.011111111111111112 \cdot a\right) \cdot angle\right) \cdot \left(\pi \cdot a\right)\\
          
          \mathbf{else}:\\
          \;\;\;\;\left(\left(\left(b \cdot b\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 2 regimes
          2. if (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64))) < -5.0000000000000003e-254

            1. Initial program 61.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                  1. Initial program 48.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                  Alternative 6: 62.8% accurate, 2.7× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;{b}^{2} \leq 2 \cdot 10^{+69}:\\ \;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(\left(\pi \cdot angle\right) \cdot a, -0.011111111111111112, \left(\left(0 \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right), a, \left(\left(\left(b \cdot b\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right) \cdot 1\\ \end{array} \end{array} \]
                  (FPCore (a b angle)
                   :precision binary64
                   (if (<= (pow b 2.0) 2e+69)
                     (fma
                      (fma
                       (* (* PI angle) a)
                       -0.011111111111111112
                       (* (* (* 0.0 PI) angle) 0.011111111111111112))
                      a
                      (* (* (* (* b b) PI) angle) 0.011111111111111112))
                     (*
                      (*
                       (*
                        (*
                         (*
                          (fma
                           (* -2.8577960676726107e-8 (* angle angle))
                           (* (* PI PI) PI)
                           (* PI 0.005555555555555556))
                          angle)
                         2.0)
                        (- b a))
                       (+ a b))
                      1.0)))
                  double code(double a, double b, double angle) {
                  	double tmp;
                  	if (pow(b, 2.0) <= 2e+69) {
                  		tmp = fma(fma(((((double) M_PI) * angle) * a), -0.011111111111111112, (((0.0 * ((double) M_PI)) * angle) * 0.011111111111111112)), a, ((((b * b) * ((double) M_PI)) * angle) * 0.011111111111111112));
                  	} else {
                  		tmp = ((((fma((-2.8577960676726107e-8 * (angle * angle)), ((((double) M_PI) * ((double) M_PI)) * ((double) M_PI)), (((double) M_PI) * 0.005555555555555556)) * angle) * 2.0) * (b - a)) * (a + b)) * 1.0;
                  	}
                  	return tmp;
                  }
                  
                  function code(a, b, angle)
                  	tmp = 0.0
                  	if ((b ^ 2.0) <= 2e+69)
                  		tmp = fma(fma(Float64(Float64(pi * angle) * a), -0.011111111111111112, Float64(Float64(Float64(0.0 * pi) * angle) * 0.011111111111111112)), a, Float64(Float64(Float64(Float64(b * b) * pi) * angle) * 0.011111111111111112));
                  	else
                  		tmp = Float64(Float64(Float64(Float64(Float64(fma(Float64(-2.8577960676726107e-8 * Float64(angle * angle)), Float64(Float64(pi * pi) * pi), Float64(pi * 0.005555555555555556)) * angle) * 2.0) * Float64(b - a)) * Float64(a + b)) * 1.0);
                  	end
                  	return tmp
                  end
                  
                  code[a_, b_, angle_] := If[LessEqual[N[Power[b, 2.0], $MachinePrecision], 2e+69], N[(N[(N[(N[(Pi * angle), $MachinePrecision] * a), $MachinePrecision] * -0.011111111111111112 + N[(N[(N[(0.0 * Pi), $MachinePrecision] * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision] * a + N[(N[(N[(N[(b * b), $MachinePrecision] * Pi), $MachinePrecision] * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(N[(N[(N[(-2.8577960676726107e-8 * N[(angle * angle), $MachinePrecision]), $MachinePrecision] * N[(N[(Pi * Pi), $MachinePrecision] * Pi), $MachinePrecision] + N[(Pi * 0.005555555555555556), $MachinePrecision]), $MachinePrecision] * angle), $MachinePrecision] * 2.0), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * 1.0), $MachinePrecision]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  \mathbf{if}\;{b}^{2} \leq 2 \cdot 10^{+69}:\\
                  \;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(\left(\pi \cdot angle\right) \cdot a, -0.011111111111111112, \left(\left(0 \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right), a, \left(\left(\left(b \cdot b\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;\left(\left(\left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right) \cdot 1\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if (pow.f64 b #s(literal 2 binary64)) < 2.0000000000000001e69

                    1. Initial program 60.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                      if 2.0000000000000001e69 < (pow.f64 b #s(literal 2 binary64))

                      1. Initial program 45.2%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                            \[\leadsto \left(\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\left(\mathsf{fma}\left(\frac{-1}{34992000} \cdot \color{blue}{\left(angle \cdot angle\right)}, {\mathsf{PI}\left(\right)}^{3}, \frac{1}{180} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 2\right)\right)\right) \cdot 1 \]
                          8. unpow3N/A

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

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

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

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

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

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

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

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

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

                            \[\leadsto \left(\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\left(\mathsf{fma}\left(\frac{-1}{34992000} \cdot \left(angle \cdot angle\right), \left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right), \color{blue}{\mathsf{PI}\left(\right) \cdot \frac{1}{180}}\right) \cdot angle\right) \cdot 2\right)\right)\right) \cdot 1 \]
                          18. lower-PI.f6472.9

                            \[\leadsto \left(\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \color{blue}{\pi} \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right)\right)\right) \cdot 1 \]
                        4. Applied rewrites72.9%

                          \[\leadsto \left(\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\color{blue}{\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \pi \cdot 0.005555555555555556\right) \cdot angle\right)} \cdot 2\right)\right)\right) \cdot 1 \]
                      7. Recombined 2 regimes into one program.
                      8. Final simplification66.4%

                        \[\leadsto \begin{array}{l} \mathbf{if}\;{b}^{2} \leq 2 \cdot 10^{+69}:\\ \;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(\left(\pi \cdot angle\right) \cdot a, -0.011111111111111112, \left(\left(0 \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right), a, \left(\left(\left(b \cdot b\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right) \cdot 1\\ \end{array} \]
                      9. Add Preprocessing

                      Alternative 7: 62.8% accurate, 2.7× speedup?

                      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;{b}^{2} \leq 2 \cdot 10^{+69}:\\ \;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(\left(\pi \cdot angle\right) \cdot a, -0.011111111111111112, \left(\left(0 \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right), a, \left(\left(\left(b \cdot b\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-1.54320987654321 \cdot 10^{-5} \cdot \left(angle \cdot angle\right), \pi \cdot \pi, 1\right) \cdot \left(\left(\left(\left(\pi \cdot \left(b - a\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right)\\ \end{array} \end{array} \]
                      (FPCore (a b angle)
                       :precision binary64
                       (if (<= (pow b 2.0) 2e+69)
                         (fma
                          (fma
                           (* (* PI angle) a)
                           -0.011111111111111112
                           (* (* (* 0.0 PI) angle) 0.011111111111111112))
                          a
                          (* (* (* (* b b) PI) angle) 0.011111111111111112))
                         (*
                          (fma (* -1.54320987654321e-5 (* angle angle)) (* PI PI) 1.0)
                          (* (* (* (* PI (- b a)) angle) 0.011111111111111112) (+ a b)))))
                      double code(double a, double b, double angle) {
                      	double tmp;
                      	if (pow(b, 2.0) <= 2e+69) {
                      		tmp = fma(fma(((((double) M_PI) * angle) * a), -0.011111111111111112, (((0.0 * ((double) M_PI)) * angle) * 0.011111111111111112)), a, ((((b * b) * ((double) M_PI)) * angle) * 0.011111111111111112));
                      	} else {
                      		tmp = fma((-1.54320987654321e-5 * (angle * angle)), (((double) M_PI) * ((double) M_PI)), 1.0) * ((((((double) M_PI) * (b - a)) * angle) * 0.011111111111111112) * (a + b));
                      	}
                      	return tmp;
                      }
                      
                      function code(a, b, angle)
                      	tmp = 0.0
                      	if ((b ^ 2.0) <= 2e+69)
                      		tmp = fma(fma(Float64(Float64(pi * angle) * a), -0.011111111111111112, Float64(Float64(Float64(0.0 * pi) * angle) * 0.011111111111111112)), a, Float64(Float64(Float64(Float64(b * b) * pi) * angle) * 0.011111111111111112));
                      	else
                      		tmp = Float64(fma(Float64(-1.54320987654321e-5 * Float64(angle * angle)), Float64(pi * pi), 1.0) * Float64(Float64(Float64(Float64(pi * Float64(b - a)) * angle) * 0.011111111111111112) * Float64(a + b)));
                      	end
                      	return tmp
                      end
                      
                      code[a_, b_, angle_] := If[LessEqual[N[Power[b, 2.0], $MachinePrecision], 2e+69], N[(N[(N[(N[(Pi * angle), $MachinePrecision] * a), $MachinePrecision] * -0.011111111111111112 + N[(N[(N[(0.0 * Pi), $MachinePrecision] * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision] * a + N[(N[(N[(N[(b * b), $MachinePrecision] * Pi), $MachinePrecision] * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]), $MachinePrecision], N[(N[(N[(-1.54320987654321e-5 * N[(angle * angle), $MachinePrecision]), $MachinePrecision] * N[(Pi * Pi), $MachinePrecision] + 1.0), $MachinePrecision] * N[(N[(N[(N[(Pi * N[(b - a), $MachinePrecision]), $MachinePrecision] * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
                      
                      \begin{array}{l}
                      
                      \\
                      \begin{array}{l}
                      \mathbf{if}\;{b}^{2} \leq 2 \cdot 10^{+69}:\\
                      \;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(\left(\pi \cdot angle\right) \cdot a, -0.011111111111111112, \left(\left(0 \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right), a, \left(\left(\left(b \cdot b\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\
                      
                      \mathbf{else}:\\
                      \;\;\;\;\mathsf{fma}\left(-1.54320987654321 \cdot 10^{-5} \cdot \left(angle \cdot angle\right), \pi \cdot \pi, 1\right) \cdot \left(\left(\left(\left(\pi \cdot \left(b - a\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right)\\
                      
                      
                      \end{array}
                      \end{array}
                      
                      Derivation
                      1. Split input into 2 regimes
                      2. if (pow.f64 b #s(literal 2 binary64)) < 2.0000000000000001e69

                        1. Initial program 60.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                          if 2.0000000000000001e69 < (pow.f64 b #s(literal 2 binary64))

                          1. Initial program 45.2%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                              \[\leadsto \left(\left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \frac{1}{90}\right)\right) \cdot \mathsf{fma}\left(\frac{-1}{64800} \cdot \left(angle \cdot angle\right), \color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right), 1\right) \]
                            10. lower-PI.f6472.8

                              \[\leadsto \left(\left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right)\right) \cdot \mathsf{fma}\left(-1.54320987654321 \cdot 10^{-5} \cdot \left(angle \cdot angle\right), \pi \cdot \color{blue}{\pi}, 1\right) \]
                          10. Applied rewrites72.8%

                            \[\leadsto \left(\left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right)\right) \cdot \color{blue}{\mathsf{fma}\left(-1.54320987654321 \cdot 10^{-5} \cdot \left(angle \cdot angle\right), \pi \cdot \pi, 1\right)} \]
                        8. Recombined 2 regimes into one program.
                        9. Final simplification66.3%

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

                        Alternative 8: 67.1% accurate, 2.8× speedup?

                        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 4 \cdot 10^{+24}:\\ \;\;\;\;\left(\sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+92}:\\ \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot \left(\left(\pi \cdot \pi\right) \cdot \pi\right), angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \sin \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\\ \end{array} \end{array} \]
                        (FPCore (a b angle)
                         :precision binary64
                         (if (<= (/ angle 180.0) 4e+24)
                           (* (* (sin (* (* PI angle) 0.011111111111111112)) (- b a)) (+ a b))
                           (if (<= (/ angle 180.0) 1e+92)
                             (*
                              (* (* a a) 2.0)
                              (*
                               (fma
                                (* -1.1431184270690443e-7 (* (* PI PI) PI))
                                (* angle angle)
                                (* PI 0.005555555555555556))
                               angle))
                             (* (* (- b a) (+ a b)) (sin (* (* 0.011111111111111112 angle) PI))))))
                        double code(double a, double b, double angle) {
                        	double tmp;
                        	if ((angle / 180.0) <= 4e+24) {
                        		tmp = (sin(((((double) M_PI) * angle) * 0.011111111111111112)) * (b - a)) * (a + b);
                        	} else if ((angle / 180.0) <= 1e+92) {
                        		tmp = ((a * a) * 2.0) * (fma((-1.1431184270690443e-7 * ((((double) M_PI) * ((double) M_PI)) * ((double) M_PI))), (angle * angle), (((double) M_PI) * 0.005555555555555556)) * angle);
                        	} else {
                        		tmp = ((b - a) * (a + b)) * sin(((0.011111111111111112 * angle) * ((double) M_PI)));
                        	}
                        	return tmp;
                        }
                        
                        function code(a, b, angle)
                        	tmp = 0.0
                        	if (Float64(angle / 180.0) <= 4e+24)
                        		tmp = Float64(Float64(sin(Float64(Float64(pi * angle) * 0.011111111111111112)) * Float64(b - a)) * Float64(a + b));
                        	elseif (Float64(angle / 180.0) <= 1e+92)
                        		tmp = Float64(Float64(Float64(a * a) * 2.0) * Float64(fma(Float64(-1.1431184270690443e-7 * Float64(Float64(pi * pi) * pi)), Float64(angle * angle), Float64(pi * 0.005555555555555556)) * angle));
                        	else
                        		tmp = Float64(Float64(Float64(b - a) * Float64(a + b)) * sin(Float64(Float64(0.011111111111111112 * angle) * pi)));
                        	end
                        	return tmp
                        end
                        
                        code[a_, b_, angle_] := If[LessEqual[N[(angle / 180.0), $MachinePrecision], 4e+24], N[(N[(N[Sin[N[(N[(Pi * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]], $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(angle / 180.0), $MachinePrecision], 1e+92], N[(N[(N[(a * a), $MachinePrecision] * 2.0), $MachinePrecision] * N[(N[(N[(-1.1431184270690443e-7 * N[(N[(Pi * Pi), $MachinePrecision] * Pi), $MachinePrecision]), $MachinePrecision] * N[(angle * angle), $MachinePrecision] + N[(Pi * 0.005555555555555556), $MachinePrecision]), $MachinePrecision] * angle), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b - a), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[Sin[N[(N[(0.011111111111111112 * angle), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
                        
                        \begin{array}{l}
                        
                        \\
                        \begin{array}{l}
                        \mathbf{if}\;\frac{angle}{180} \leq 4 \cdot 10^{+24}:\\
                        \;\;\;\;\left(\sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\\
                        
                        \mathbf{elif}\;\frac{angle}{180} \leq 10^{+92}:\\
                        \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot \left(\left(\pi \cdot \pi\right) \cdot \pi\right), angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\
                        
                        \mathbf{else}:\\
                        \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \sin \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\\
                        
                        
                        \end{array}
                        \end{array}
                        
                        Derivation
                        1. Split input into 3 regimes
                        2. if (/.f64 angle #s(literal 180 binary64)) < 3.9999999999999999e24

                          1. Initial program 60.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                          if 3.9999999999999999e24 < (/.f64 angle #s(literal 180 binary64)) < 1e92

                          1. Initial program 27.6%

                            \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                          2. Add Preprocessing
                          3. Applied rewrites1.3%

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

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

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

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

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

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

                              \[\leadsto \color{blue}{\left(\left(2 \cdot \left(a \cdot a\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                          8. Applied rewrites18.5%

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

                            \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{180} \cdot \mathsf{PI}\left(\right) + {angle}^{2} \cdot \left(\frac{-1}{11664000} \cdot {\mathsf{PI}\left(\right)}^{3} + \frac{-1}{34992000} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right)\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]
                          10. Step-by-step derivation
                            1. *-commutativeN/A

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

                              \[\leadsto \color{blue}{\left(\left(\frac{1}{180} \cdot \mathsf{PI}\left(\right) + {angle}^{2} \cdot \left(\frac{-1}{11664000} \cdot {\mathsf{PI}\left(\right)}^{3} + \frac{-1}{34992000} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right) \cdot angle\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]
                          11. Applied rewrites49.3%

                            \[\leadsto \color{blue}{\left(\mathsf{fma}\left(\left(\left(\pi \cdot \pi\right) \cdot \pi\right) \cdot -1.1431184270690443 \cdot 10^{-7}, angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]

                          if 1e92 < (/.f64 angle #s(literal 180 binary64))

                          1. Initial program 35.0%

                            \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                          2. Add Preprocessing
                          3. Applied rewrites1.8%

                            \[\leadsto \color{blue}{\left(\mathsf{fma}\left(b \cdot b, b, \left(a \cdot a\right) \cdot a\right) \cdot \left(\left(b \cdot b\right) \cdot b - \left(a \cdot a\right) \cdot a\right)\right) \cdot \left(\frac{1}{\mathsf{fma}\left(\left(b \cdot b\right) \cdot b, b, \mathsf{fma}\left(a, a, b \cdot b\right) \cdot \left(a \cdot a\right)\right)} \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)} \]
                          4. Applied rewrites45.5%

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

                          \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 4 \cdot 10^{+24}:\\ \;\;\;\;\left(\sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+92}:\\ \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot \left(\left(\pi \cdot \pi\right) \cdot \pi\right), angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \sin \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\\ \end{array} \]
                        5. Add Preprocessing

                        Alternative 9: 63.4% accurate, 2.8× speedup?

                        \[\begin{array}{l} \\ \begin{array}{l} t_0 := \left(\pi \cdot \pi\right) \cdot \pi\\ \mathbf{if}\;\frac{angle}{180} \leq 2 \cdot 10^{+20}:\\ \;\;\;\;\left(\left(\left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), t\_0, \pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right) \cdot 1\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+92}:\\ \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot t\_0, angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \sin \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\\ \end{array} \end{array} \]
                        (FPCore (a b angle)
                         :precision binary64
                         (let* ((t_0 (* (* PI PI) PI)))
                           (if (<= (/ angle 180.0) 2e+20)
                             (*
                              (*
                               (*
                                (*
                                 (*
                                  (fma
                                   (* -2.8577960676726107e-8 (* angle angle))
                                   t_0
                                   (* PI 0.005555555555555556))
                                  angle)
                                 2.0)
                                (- b a))
                               (+ a b))
                              1.0)
                             (if (<= (/ angle 180.0) 1e+92)
                               (*
                                (* (* a a) 2.0)
                                (*
                                 (fma
                                  (* -1.1431184270690443e-7 t_0)
                                  (* angle angle)
                                  (* PI 0.005555555555555556))
                                 angle))
                               (* (* (- b a) (+ a b)) (sin (* (* 0.011111111111111112 angle) PI)))))))
                        double code(double a, double b, double angle) {
                        	double t_0 = (((double) M_PI) * ((double) M_PI)) * ((double) M_PI);
                        	double tmp;
                        	if ((angle / 180.0) <= 2e+20) {
                        		tmp = ((((fma((-2.8577960676726107e-8 * (angle * angle)), t_0, (((double) M_PI) * 0.005555555555555556)) * angle) * 2.0) * (b - a)) * (a + b)) * 1.0;
                        	} else if ((angle / 180.0) <= 1e+92) {
                        		tmp = ((a * a) * 2.0) * (fma((-1.1431184270690443e-7 * t_0), (angle * angle), (((double) M_PI) * 0.005555555555555556)) * angle);
                        	} else {
                        		tmp = ((b - a) * (a + b)) * sin(((0.011111111111111112 * angle) * ((double) M_PI)));
                        	}
                        	return tmp;
                        }
                        
                        function code(a, b, angle)
                        	t_0 = Float64(Float64(pi * pi) * pi)
                        	tmp = 0.0
                        	if (Float64(angle / 180.0) <= 2e+20)
                        		tmp = Float64(Float64(Float64(Float64(Float64(fma(Float64(-2.8577960676726107e-8 * Float64(angle * angle)), t_0, Float64(pi * 0.005555555555555556)) * angle) * 2.0) * Float64(b - a)) * Float64(a + b)) * 1.0);
                        	elseif (Float64(angle / 180.0) <= 1e+92)
                        		tmp = Float64(Float64(Float64(a * a) * 2.0) * Float64(fma(Float64(-1.1431184270690443e-7 * t_0), Float64(angle * angle), Float64(pi * 0.005555555555555556)) * angle));
                        	else
                        		tmp = Float64(Float64(Float64(b - a) * Float64(a + b)) * sin(Float64(Float64(0.011111111111111112 * angle) * pi)));
                        	end
                        	return tmp
                        end
                        
                        code[a_, b_, angle_] := Block[{t$95$0 = N[(N[(Pi * Pi), $MachinePrecision] * Pi), $MachinePrecision]}, If[LessEqual[N[(angle / 180.0), $MachinePrecision], 2e+20], N[(N[(N[(N[(N[(N[(N[(-2.8577960676726107e-8 * N[(angle * angle), $MachinePrecision]), $MachinePrecision] * t$95$0 + N[(Pi * 0.005555555555555556), $MachinePrecision]), $MachinePrecision] * angle), $MachinePrecision] * 2.0), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * 1.0), $MachinePrecision], If[LessEqual[N[(angle / 180.0), $MachinePrecision], 1e+92], N[(N[(N[(a * a), $MachinePrecision] * 2.0), $MachinePrecision] * N[(N[(N[(-1.1431184270690443e-7 * t$95$0), $MachinePrecision] * N[(angle * angle), $MachinePrecision] + N[(Pi * 0.005555555555555556), $MachinePrecision]), $MachinePrecision] * angle), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b - a), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[Sin[N[(N[(0.011111111111111112 * angle), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]
                        
                        \begin{array}{l}
                        
                        \\
                        \begin{array}{l}
                        t_0 := \left(\pi \cdot \pi\right) \cdot \pi\\
                        \mathbf{if}\;\frac{angle}{180} \leq 2 \cdot 10^{+20}:\\
                        \;\;\;\;\left(\left(\left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), t\_0, \pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right) \cdot 1\\
                        
                        \mathbf{elif}\;\frac{angle}{180} \leq 10^{+92}:\\
                        \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot t\_0, angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\
                        
                        \mathbf{else}:\\
                        \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \sin \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\\
                        
                        
                        \end{array}
                        \end{array}
                        
                        Derivation
                        1. Split input into 3 regimes
                        2. if (/.f64 angle #s(literal 180 binary64)) < 2e20

                          1. Initial program 60.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                \[\leadsto \left(\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\left(\mathsf{fma}\left(\frac{-1}{34992000} \cdot \color{blue}{\left(angle \cdot angle\right)}, {\mathsf{PI}\left(\right)}^{3}, \frac{1}{180} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 2\right)\right)\right) \cdot 1 \]
                              8. unpow3N/A

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

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

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

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

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

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

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

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

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

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

                                \[\leadsto \left(\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \color{blue}{\pi} \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right)\right)\right) \cdot 1 \]
                            4. Applied rewrites74.3%

                              \[\leadsto \left(\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\color{blue}{\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \pi \cdot 0.005555555555555556\right) \cdot angle\right)} \cdot 2\right)\right)\right) \cdot 1 \]

                            if 2e20 < (/.f64 angle #s(literal 180 binary64)) < 1e92

                            1. Initial program 27.6%

                              \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                            2. Add Preprocessing
                            3. Applied rewrites1.3%

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

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

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

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

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

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

                                \[\leadsto \color{blue}{\left(\left(2 \cdot \left(a \cdot a\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                            8. Applied rewrites18.5%

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

                              \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{180} \cdot \mathsf{PI}\left(\right) + {angle}^{2} \cdot \left(\frac{-1}{11664000} \cdot {\mathsf{PI}\left(\right)}^{3} + \frac{-1}{34992000} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right)\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]
                            10. Step-by-step derivation
                              1. *-commutativeN/A

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

                                \[\leadsto \color{blue}{\left(\left(\frac{1}{180} \cdot \mathsf{PI}\left(\right) + {angle}^{2} \cdot \left(\frac{-1}{11664000} \cdot {\mathsf{PI}\left(\right)}^{3} + \frac{-1}{34992000} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right) \cdot angle\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]
                            11. Applied rewrites49.3%

                              \[\leadsto \color{blue}{\left(\mathsf{fma}\left(\left(\left(\pi \cdot \pi\right) \cdot \pi\right) \cdot -1.1431184270690443 \cdot 10^{-7}, angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]

                            if 1e92 < (/.f64 angle #s(literal 180 binary64))

                            1. Initial program 35.0%

                              \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                            2. Add Preprocessing
                            3. Applied rewrites1.8%

                              \[\leadsto \color{blue}{\left(\mathsf{fma}\left(b \cdot b, b, \left(a \cdot a\right) \cdot a\right) \cdot \left(\left(b \cdot b\right) \cdot b - \left(a \cdot a\right) \cdot a\right)\right) \cdot \left(\frac{1}{\mathsf{fma}\left(\left(b \cdot b\right) \cdot b, b, \mathsf{fma}\left(a, a, b \cdot b\right) \cdot \left(a \cdot a\right)\right)} \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)} \]
                            4. Applied rewrites45.5%

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

                            \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 2 \cdot 10^{+20}:\\ \;\;\;\;\left(\left(\left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right) \cdot 1\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+92}:\\ \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot \left(\left(\pi \cdot \pi\right) \cdot \pi\right), angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \sin \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\\ \end{array} \]
                          9. Add Preprocessing

                          Alternative 10: 63.4% accurate, 2.8× speedup?

                          \[\begin{array}{l} \\ \begin{array}{l} t_0 := \left(\pi \cdot \pi\right) \cdot \pi\\ \mathbf{if}\;\frac{angle}{180} \leq 2 \cdot 10^{+20}:\\ \;\;\;\;\left(\left(\left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), t\_0, \pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right) \cdot 1\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+92}:\\ \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot t\_0, angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)\\ \end{array} \end{array} \]
                          (FPCore (a b angle)
                           :precision binary64
                           (let* ((t_0 (* (* PI PI) PI)))
                             (if (<= (/ angle 180.0) 2e+20)
                               (*
                                (*
                                 (*
                                  (*
                                   (*
                                    (fma
                                     (* -2.8577960676726107e-8 (* angle angle))
                                     t_0
                                     (* PI 0.005555555555555556))
                                    angle)
                                   2.0)
                                  (- b a))
                                 (+ a b))
                                1.0)
                               (if (<= (/ angle 180.0) 1e+92)
                                 (*
                                  (* (* a a) 2.0)
                                  (*
                                   (fma
                                    (* -1.1431184270690443e-7 t_0)
                                    (* angle angle)
                                    (* PI 0.005555555555555556))
                                   angle))
                                 (* (* (- b a) (+ a b)) (sin (* (* PI angle) 0.011111111111111112)))))))
                          double code(double a, double b, double angle) {
                          	double t_0 = (((double) M_PI) * ((double) M_PI)) * ((double) M_PI);
                          	double tmp;
                          	if ((angle / 180.0) <= 2e+20) {
                          		tmp = ((((fma((-2.8577960676726107e-8 * (angle * angle)), t_0, (((double) M_PI) * 0.005555555555555556)) * angle) * 2.0) * (b - a)) * (a + b)) * 1.0;
                          	} else if ((angle / 180.0) <= 1e+92) {
                          		tmp = ((a * a) * 2.0) * (fma((-1.1431184270690443e-7 * t_0), (angle * angle), (((double) M_PI) * 0.005555555555555556)) * angle);
                          	} else {
                          		tmp = ((b - a) * (a + b)) * sin(((((double) M_PI) * angle) * 0.011111111111111112));
                          	}
                          	return tmp;
                          }
                          
                          function code(a, b, angle)
                          	t_0 = Float64(Float64(pi * pi) * pi)
                          	tmp = 0.0
                          	if (Float64(angle / 180.0) <= 2e+20)
                          		tmp = Float64(Float64(Float64(Float64(Float64(fma(Float64(-2.8577960676726107e-8 * Float64(angle * angle)), t_0, Float64(pi * 0.005555555555555556)) * angle) * 2.0) * Float64(b - a)) * Float64(a + b)) * 1.0);
                          	elseif (Float64(angle / 180.0) <= 1e+92)
                          		tmp = Float64(Float64(Float64(a * a) * 2.0) * Float64(fma(Float64(-1.1431184270690443e-7 * t_0), Float64(angle * angle), Float64(pi * 0.005555555555555556)) * angle));
                          	else
                          		tmp = Float64(Float64(Float64(b - a) * Float64(a + b)) * sin(Float64(Float64(pi * angle) * 0.011111111111111112)));
                          	end
                          	return tmp
                          end
                          
                          code[a_, b_, angle_] := Block[{t$95$0 = N[(N[(Pi * Pi), $MachinePrecision] * Pi), $MachinePrecision]}, If[LessEqual[N[(angle / 180.0), $MachinePrecision], 2e+20], N[(N[(N[(N[(N[(N[(N[(-2.8577960676726107e-8 * N[(angle * angle), $MachinePrecision]), $MachinePrecision] * t$95$0 + N[(Pi * 0.005555555555555556), $MachinePrecision]), $MachinePrecision] * angle), $MachinePrecision] * 2.0), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * 1.0), $MachinePrecision], If[LessEqual[N[(angle / 180.0), $MachinePrecision], 1e+92], N[(N[(N[(a * a), $MachinePrecision] * 2.0), $MachinePrecision] * N[(N[(N[(-1.1431184270690443e-7 * t$95$0), $MachinePrecision] * N[(angle * angle), $MachinePrecision] + N[(Pi * 0.005555555555555556), $MachinePrecision]), $MachinePrecision] * angle), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b - a), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[Sin[N[(N[(Pi * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]
                          
                          \begin{array}{l}
                          
                          \\
                          \begin{array}{l}
                          t_0 := \left(\pi \cdot \pi\right) \cdot \pi\\
                          \mathbf{if}\;\frac{angle}{180} \leq 2 \cdot 10^{+20}:\\
                          \;\;\;\;\left(\left(\left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), t\_0, \pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right) \cdot 1\\
                          
                          \mathbf{elif}\;\frac{angle}{180} \leq 10^{+92}:\\
                          \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot t\_0, angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 3 regimes
                          2. if (/.f64 angle #s(literal 180 binary64)) < 2e20

                            1. Initial program 60.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                  \[\leadsto \left(\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\left(\mathsf{fma}\left(\frac{-1}{34992000} \cdot \color{blue}{\left(angle \cdot angle\right)}, {\mathsf{PI}\left(\right)}^{3}, \frac{1}{180} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 2\right)\right)\right) \cdot 1 \]
                                8. unpow3N/A

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

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

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

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

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

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

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

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

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

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

                                  \[\leadsto \left(\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \color{blue}{\pi} \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right)\right)\right) \cdot 1 \]
                              4. Applied rewrites74.3%

                                \[\leadsto \left(\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\color{blue}{\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \pi \cdot 0.005555555555555556\right) \cdot angle\right)} \cdot 2\right)\right)\right) \cdot 1 \]

                              if 2e20 < (/.f64 angle #s(literal 180 binary64)) < 1e92

                              1. Initial program 27.6%

                                \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                              2. Add Preprocessing
                              3. Applied rewrites1.3%

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

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

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

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

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

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

                                  \[\leadsto \color{blue}{\left(\left(2 \cdot \left(a \cdot a\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                              8. Applied rewrites18.5%

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

                                \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{180} \cdot \mathsf{PI}\left(\right) + {angle}^{2} \cdot \left(\frac{-1}{11664000} \cdot {\mathsf{PI}\left(\right)}^{3} + \frac{-1}{34992000} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right)\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]
                              10. Step-by-step derivation
                                1. *-commutativeN/A

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

                                  \[\leadsto \color{blue}{\left(\left(\frac{1}{180} \cdot \mathsf{PI}\left(\right) + {angle}^{2} \cdot \left(\frac{-1}{11664000} \cdot {\mathsf{PI}\left(\right)}^{3} + \frac{-1}{34992000} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right) \cdot angle\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]
                              11. Applied rewrites49.3%

                                \[\leadsto \color{blue}{\left(\mathsf{fma}\left(\left(\left(\pi \cdot \pi\right) \cdot \pi\right) \cdot -1.1431184270690443 \cdot 10^{-7}, angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]

                              if 1e92 < (/.f64 angle #s(literal 180 binary64))

                              1. Initial program 35.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                              \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 2 \cdot 10^{+20}:\\ \;\;\;\;\left(\left(\left(\left(\mathsf{fma}\left(-2.8577960676726107 \cdot 10^{-8} \cdot \left(angle \cdot angle\right), \left(\pi \cdot \pi\right) \cdot \pi, \pi \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 2\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\right) \cdot 1\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+92}:\\ \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot \left(\left(\pi \cdot \pi\right) \cdot \pi\right), angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right)\\ \end{array} \]
                            9. Add Preprocessing

                            Alternative 11: 67.1% accurate, 3.2× speedup?

                            \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq 4.8 \cdot 10^{+204}:\\ \;\;\;\;\left(\sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b \cdot \left(\left(\sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right) \cdot 2\right) \cdot \left(b - a\right)\right)\right) \cdot 1\\ \end{array} \end{array} \]
                            (FPCore (a b angle)
                             :precision binary64
                             (if (<= b 4.8e+204)
                               (* (* (sin (* (* PI angle) 0.011111111111111112)) (- b a)) (+ a b))
                               (*
                                (* b (* (* (sin (* PI (* angle 0.005555555555555556))) 2.0) (- b a)))
                                1.0)))
                            double code(double a, double b, double angle) {
                            	double tmp;
                            	if (b <= 4.8e+204) {
                            		tmp = (sin(((((double) M_PI) * angle) * 0.011111111111111112)) * (b - a)) * (a + b);
                            	} else {
                            		tmp = (b * ((sin((((double) M_PI) * (angle * 0.005555555555555556))) * 2.0) * (b - a))) * 1.0;
                            	}
                            	return tmp;
                            }
                            
                            public static double code(double a, double b, double angle) {
                            	double tmp;
                            	if (b <= 4.8e+204) {
                            		tmp = (Math.sin(((Math.PI * angle) * 0.011111111111111112)) * (b - a)) * (a + b);
                            	} else {
                            		tmp = (b * ((Math.sin((Math.PI * (angle * 0.005555555555555556))) * 2.0) * (b - a))) * 1.0;
                            	}
                            	return tmp;
                            }
                            
                            def code(a, b, angle):
                            	tmp = 0
                            	if b <= 4.8e+204:
                            		tmp = (math.sin(((math.pi * angle) * 0.011111111111111112)) * (b - a)) * (a + b)
                            	else:
                            		tmp = (b * ((math.sin((math.pi * (angle * 0.005555555555555556))) * 2.0) * (b - a))) * 1.0
                            	return tmp
                            
                            function code(a, b, angle)
                            	tmp = 0.0
                            	if (b <= 4.8e+204)
                            		tmp = Float64(Float64(sin(Float64(Float64(pi * angle) * 0.011111111111111112)) * Float64(b - a)) * Float64(a + b));
                            	else
                            		tmp = Float64(Float64(b * Float64(Float64(sin(Float64(pi * Float64(angle * 0.005555555555555556))) * 2.0) * Float64(b - a))) * 1.0);
                            	end
                            	return tmp
                            end
                            
                            function tmp_2 = code(a, b, angle)
                            	tmp = 0.0;
                            	if (b <= 4.8e+204)
                            		tmp = (sin(((pi * angle) * 0.011111111111111112)) * (b - a)) * (a + b);
                            	else
                            		tmp = (b * ((sin((pi * (angle * 0.005555555555555556))) * 2.0) * (b - a))) * 1.0;
                            	end
                            	tmp_2 = tmp;
                            end
                            
                            code[a_, b_, angle_] := If[LessEqual[b, 4.8e+204], N[(N[(N[Sin[N[(N[(Pi * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision]], $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision], N[(N[(b * N[(N[(N[Sin[N[(Pi * N[(angle * 0.005555555555555556), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * 2.0), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 1.0), $MachinePrecision]]
                            
                            \begin{array}{l}
                            
                            \\
                            \begin{array}{l}
                            \mathbf{if}\;b \leq 4.8 \cdot 10^{+204}:\\
                            \;\;\;\;\left(\sin \left(\left(\pi \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)\\
                            
                            \mathbf{else}:\\
                            \;\;\;\;\left(b \cdot \left(\left(\sin \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right) \cdot 2\right) \cdot \left(b - a\right)\right)\right) \cdot 1\\
                            
                            
                            \end{array}
                            \end{array}
                            
                            Derivation
                            1. Split input into 2 regimes
                            2. if b < 4.7999999999999999e204

                              1. Initial program 54.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                              if 4.7999999999999999e204 < b

                              1. Initial program 45.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \left(\mathsf{fma}\left(\sqrt{b}, {b}^{\color{blue}{\frac{1}{2}}}, a\right) \cdot \left(\left(b - a\right) \cdot \left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \mathsf{PI}\left(\right)\right) \cdot 2\right)\right)\right) \cdot 1 \]
                                  10. unpow1/2N/A

                                    \[\leadsto \left(\mathsf{fma}\left(\sqrt{b}, \color{blue}{\sqrt{b}}, a\right) \cdot \left(\left(b - a\right) \cdot \left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \mathsf{PI}\left(\right)\right) \cdot 2\right)\right)\right) \cdot 1 \]
                                  11. lower-sqrt.f6488.6

                                    \[\leadsto \left(\mathsf{fma}\left(\sqrt{b}, \color{blue}{\sqrt{b}}, a\right) \cdot \left(\left(b - a\right) \cdot \left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot 2\right)\right)\right) \cdot 1 \]
                                3. Applied rewrites88.6%

                                  \[\leadsto \left(\color{blue}{\mathsf{fma}\left(\sqrt{b}, \sqrt{b}, a\right)} \cdot \left(\left(b - a\right) \cdot \left(\sin \left(\left(0.005555555555555556 \cdot angle\right) \cdot \pi\right) \cdot 2\right)\right)\right) \cdot 1 \]
                                4. Taylor expanded in b around -inf

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

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

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

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

                                    \[\leadsto \left(\color{blue}{\left(\mathsf{neg}\left(-1 \cdot b\right)\right)} \cdot \left(\left(b - a\right) \cdot \left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \mathsf{PI}\left(\right)\right) \cdot 2\right)\right)\right) \cdot 1 \]
                                  5. distribute-lft-neg-inN/A

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

                                    \[\leadsto \left(\left(\color{blue}{1} \cdot b\right) \cdot \left(\left(b - a\right) \cdot \left(\sin \left(\left(\frac{1}{180} \cdot angle\right) \cdot \mathsf{PI}\left(\right)\right) \cdot 2\right)\right)\right) \cdot 1 \]
                                  7. *-lft-identity85.1

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

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

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

                              Alternative 12: 57.4% accurate, 3.4× speedup?

                              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;{a}^{2} \leq 4 \cdot 10^{+218}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \left(\left(0.011111111111111112 \cdot \pi\right) \cdot angle\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(-0.011111111111111112 \cdot a\right) \cdot angle\right) \cdot \left(\pi \cdot a\right)\\ \end{array} \end{array} \]
                              (FPCore (a b angle)
                               :precision binary64
                               (if (<= (pow a 2.0) 4e+218)
                                 (* (* (- b a) (+ a b)) (* (* 0.011111111111111112 PI) angle))
                                 (* (* (* -0.011111111111111112 a) angle) (* PI a))))
                              double code(double a, double b, double angle) {
                              	double tmp;
                              	if (pow(a, 2.0) <= 4e+218) {
                              		tmp = ((b - a) * (a + b)) * ((0.011111111111111112 * ((double) M_PI)) * angle);
                              	} else {
                              		tmp = ((-0.011111111111111112 * a) * angle) * (((double) M_PI) * a);
                              	}
                              	return tmp;
                              }
                              
                              public static double code(double a, double b, double angle) {
                              	double tmp;
                              	if (Math.pow(a, 2.0) <= 4e+218) {
                              		tmp = ((b - a) * (a + b)) * ((0.011111111111111112 * Math.PI) * angle);
                              	} else {
                              		tmp = ((-0.011111111111111112 * a) * angle) * (Math.PI * a);
                              	}
                              	return tmp;
                              }
                              
                              def code(a, b, angle):
                              	tmp = 0
                              	if math.pow(a, 2.0) <= 4e+218:
                              		tmp = ((b - a) * (a + b)) * ((0.011111111111111112 * math.pi) * angle)
                              	else:
                              		tmp = ((-0.011111111111111112 * a) * angle) * (math.pi * a)
                              	return tmp
                              
                              function code(a, b, angle)
                              	tmp = 0.0
                              	if ((a ^ 2.0) <= 4e+218)
                              		tmp = Float64(Float64(Float64(b - a) * Float64(a + b)) * Float64(Float64(0.011111111111111112 * pi) * angle));
                              	else
                              		tmp = Float64(Float64(Float64(-0.011111111111111112 * a) * angle) * Float64(pi * a));
                              	end
                              	return tmp
                              end
                              
                              function tmp_2 = code(a, b, angle)
                              	tmp = 0.0;
                              	if ((a ^ 2.0) <= 4e+218)
                              		tmp = ((b - a) * (a + b)) * ((0.011111111111111112 * pi) * angle);
                              	else
                              		tmp = ((-0.011111111111111112 * a) * angle) * (pi * a);
                              	end
                              	tmp_2 = tmp;
                              end
                              
                              code[a_, b_, angle_] := If[LessEqual[N[Power[a, 2.0], $MachinePrecision], 4e+218], N[(N[(N[(b - a), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(N[(0.011111111111111112 * Pi), $MachinePrecision] * angle), $MachinePrecision]), $MachinePrecision], N[(N[(N[(-0.011111111111111112 * a), $MachinePrecision] * angle), $MachinePrecision] * N[(Pi * a), $MachinePrecision]), $MachinePrecision]]
                              
                              \begin{array}{l}
                              
                              \\
                              \begin{array}{l}
                              \mathbf{if}\;{a}^{2} \leq 4 \cdot 10^{+218}:\\
                              \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \left(\left(0.011111111111111112 \cdot \pi\right) \cdot angle\right)\\
                              
                              \mathbf{else}:\\
                              \;\;\;\;\left(\left(-0.011111111111111112 \cdot a\right) \cdot angle\right) \cdot \left(\pi \cdot a\right)\\
                              
                              
                              \end{array}
                              \end{array}
                              
                              Derivation
                              1. Split input into 2 regimes
                              2. if (pow.f64 a #s(literal 2 binary64)) < 4.00000000000000033e218

                                1. Initial program 59.2%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                  if 4.00000000000000033e218 < (pow.f64 a #s(literal 2 binary64))

                                  1. Initial program 42.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                      Alternative 13: 57.4% accurate, 3.4× speedup?

                                      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;{a}^{2} \leq 4 \cdot 10^{+218}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(-0.011111111111111112 \cdot a\right) \cdot angle\right) \cdot \left(\pi \cdot a\right)\\ \end{array} \end{array} \]
                                      (FPCore (a b angle)
                                       :precision binary64
                                       (if (<= (pow a 2.0) 4e+218)
                                         (* (* (- b a) (+ a b)) (* (* 0.011111111111111112 angle) PI))
                                         (* (* (* -0.011111111111111112 a) angle) (* PI a))))
                                      double code(double a, double b, double angle) {
                                      	double tmp;
                                      	if (pow(a, 2.0) <= 4e+218) {
                                      		tmp = ((b - a) * (a + b)) * ((0.011111111111111112 * angle) * ((double) M_PI));
                                      	} else {
                                      		tmp = ((-0.011111111111111112 * a) * angle) * (((double) M_PI) * a);
                                      	}
                                      	return tmp;
                                      }
                                      
                                      public static double code(double a, double b, double angle) {
                                      	double tmp;
                                      	if (Math.pow(a, 2.0) <= 4e+218) {
                                      		tmp = ((b - a) * (a + b)) * ((0.011111111111111112 * angle) * Math.PI);
                                      	} else {
                                      		tmp = ((-0.011111111111111112 * a) * angle) * (Math.PI * a);
                                      	}
                                      	return tmp;
                                      }
                                      
                                      def code(a, b, angle):
                                      	tmp = 0
                                      	if math.pow(a, 2.0) <= 4e+218:
                                      		tmp = ((b - a) * (a + b)) * ((0.011111111111111112 * angle) * math.pi)
                                      	else:
                                      		tmp = ((-0.011111111111111112 * a) * angle) * (math.pi * a)
                                      	return tmp
                                      
                                      function code(a, b, angle)
                                      	tmp = 0.0
                                      	if ((a ^ 2.0) <= 4e+218)
                                      		tmp = Float64(Float64(Float64(b - a) * Float64(a + b)) * Float64(Float64(0.011111111111111112 * angle) * pi));
                                      	else
                                      		tmp = Float64(Float64(Float64(-0.011111111111111112 * a) * angle) * Float64(pi * a));
                                      	end
                                      	return tmp
                                      end
                                      
                                      function tmp_2 = code(a, b, angle)
                                      	tmp = 0.0;
                                      	if ((a ^ 2.0) <= 4e+218)
                                      		tmp = ((b - a) * (a + b)) * ((0.011111111111111112 * angle) * pi);
                                      	else
                                      		tmp = ((-0.011111111111111112 * a) * angle) * (pi * a);
                                      	end
                                      	tmp_2 = tmp;
                                      end
                                      
                                      code[a_, b_, angle_] := If[LessEqual[N[Power[a, 2.0], $MachinePrecision], 4e+218], N[(N[(N[(b - a), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(N[(0.011111111111111112 * angle), $MachinePrecision] * Pi), $MachinePrecision]), $MachinePrecision], N[(N[(N[(-0.011111111111111112 * a), $MachinePrecision] * angle), $MachinePrecision] * N[(Pi * a), $MachinePrecision]), $MachinePrecision]]
                                      
                                      \begin{array}{l}
                                      
                                      \\
                                      \begin{array}{l}
                                      \mathbf{if}\;{a}^{2} \leq 4 \cdot 10^{+218}:\\
                                      \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\\
                                      
                                      \mathbf{else}:\\
                                      \;\;\;\;\left(\left(-0.011111111111111112 \cdot a\right) \cdot angle\right) \cdot \left(\pi \cdot a\right)\\
                                      
                                      
                                      \end{array}
                                      \end{array}
                                      
                                      Derivation
                                      1. Split input into 2 regimes
                                      2. if (pow.f64 a #s(literal 2 binary64)) < 4.00000000000000033e218

                                        1. Initial program 59.2%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                        if 4.00000000000000033e218 < (pow.f64 a #s(literal 2 binary64))

                                        1. Initial program 42.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                            Alternative 14: 62.1% accurate, 5.3× speedup?

                                            \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 2 \cdot 10^{+54}:\\ \;\;\;\;\left(\left(0.011111111111111112 \cdot \left(a + b\right)\right) \cdot \left(\pi \cdot angle\right)\right) \cdot \left(b - a\right)\\ \mathbf{elif}\;\frac{angle}{180} \leq 5 \cdot 10^{+230}:\\ \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot \left(\left(\pi \cdot \pi\right) \cdot \pi\right), angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \left(\left(0.011111111111111112 \cdot \pi\right) \cdot angle\right)\\ \end{array} \end{array} \]
                                            (FPCore (a b angle)
                                             :precision binary64
                                             (if (<= (/ angle 180.0) 2e+54)
                                               (* (* (* 0.011111111111111112 (+ a b)) (* PI angle)) (- b a))
                                               (if (<= (/ angle 180.0) 5e+230)
                                                 (*
                                                  (* (* a a) 2.0)
                                                  (*
                                                   (fma
                                                    (* -1.1431184270690443e-7 (* (* PI PI) PI))
                                                    (* angle angle)
                                                    (* PI 0.005555555555555556))
                                                   angle))
                                                 (* (* (- b a) (+ a b)) (* (* 0.011111111111111112 PI) angle)))))
                                            double code(double a, double b, double angle) {
                                            	double tmp;
                                            	if ((angle / 180.0) <= 2e+54) {
                                            		tmp = ((0.011111111111111112 * (a + b)) * (((double) M_PI) * angle)) * (b - a);
                                            	} else if ((angle / 180.0) <= 5e+230) {
                                            		tmp = ((a * a) * 2.0) * (fma((-1.1431184270690443e-7 * ((((double) M_PI) * ((double) M_PI)) * ((double) M_PI))), (angle * angle), (((double) M_PI) * 0.005555555555555556)) * angle);
                                            	} else {
                                            		tmp = ((b - a) * (a + b)) * ((0.011111111111111112 * ((double) M_PI)) * angle);
                                            	}
                                            	return tmp;
                                            }
                                            
                                            function code(a, b, angle)
                                            	tmp = 0.0
                                            	if (Float64(angle / 180.0) <= 2e+54)
                                            		tmp = Float64(Float64(Float64(0.011111111111111112 * Float64(a + b)) * Float64(pi * angle)) * Float64(b - a));
                                            	elseif (Float64(angle / 180.0) <= 5e+230)
                                            		tmp = Float64(Float64(Float64(a * a) * 2.0) * Float64(fma(Float64(-1.1431184270690443e-7 * Float64(Float64(pi * pi) * pi)), Float64(angle * angle), Float64(pi * 0.005555555555555556)) * angle));
                                            	else
                                            		tmp = Float64(Float64(Float64(b - a) * Float64(a + b)) * Float64(Float64(0.011111111111111112 * pi) * angle));
                                            	end
                                            	return tmp
                                            end
                                            
                                            code[a_, b_, angle_] := If[LessEqual[N[(angle / 180.0), $MachinePrecision], 2e+54], N[(N[(N[(0.011111111111111112 * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(Pi * angle), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(angle / 180.0), $MachinePrecision], 5e+230], N[(N[(N[(a * a), $MachinePrecision] * 2.0), $MachinePrecision] * N[(N[(N[(-1.1431184270690443e-7 * N[(N[(Pi * Pi), $MachinePrecision] * Pi), $MachinePrecision]), $MachinePrecision] * N[(angle * angle), $MachinePrecision] + N[(Pi * 0.005555555555555556), $MachinePrecision]), $MachinePrecision] * angle), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b - a), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(N[(0.011111111111111112 * Pi), $MachinePrecision] * angle), $MachinePrecision]), $MachinePrecision]]]
                                            
                                            \begin{array}{l}
                                            
                                            \\
                                            \begin{array}{l}
                                            \mathbf{if}\;\frac{angle}{180} \leq 2 \cdot 10^{+54}:\\
                                            \;\;\;\;\left(\left(0.011111111111111112 \cdot \left(a + b\right)\right) \cdot \left(\pi \cdot angle\right)\right) \cdot \left(b - a\right)\\
                                            
                                            \mathbf{elif}\;\frac{angle}{180} \leq 5 \cdot 10^{+230}:\\
                                            \;\;\;\;\left(\left(a \cdot a\right) \cdot 2\right) \cdot \left(\mathsf{fma}\left(-1.1431184270690443 \cdot 10^{-7} \cdot \left(\left(\pi \cdot \pi\right) \cdot \pi\right), angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)\\
                                            
                                            \mathbf{else}:\\
                                            \;\;\;\;\left(\left(b - a\right) \cdot \left(a + b\right)\right) \cdot \left(\left(0.011111111111111112 \cdot \pi\right) \cdot angle\right)\\
                                            
                                            
                                            \end{array}
                                            \end{array}
                                            
                                            Derivation
                                            1. Split input into 3 regimes
                                            2. if (/.f64 angle #s(literal 180 binary64)) < 2.0000000000000002e54

                                              1. Initial program 60.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                if 2.0000000000000002e54 < (/.f64 angle #s(literal 180 binary64)) < 5.0000000000000003e230

                                                1. Initial program 31.8%

                                                  \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                                                2. Add Preprocessing
                                                3. Applied rewrites1.3%

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

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

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

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

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

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

                                                    \[\leadsto \color{blue}{\left(\left(2 \cdot \left(a \cdot a\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                                8. Applied rewrites19.0%

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

                                                  \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{180} \cdot \mathsf{PI}\left(\right) + {angle}^{2} \cdot \left(\frac{-1}{11664000} \cdot {\mathsf{PI}\left(\right)}^{3} + \frac{-1}{34992000} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right)\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]
                                                10. Step-by-step derivation
                                                  1. *-commutativeN/A

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

                                                    \[\leadsto \color{blue}{\left(\left(\frac{1}{180} \cdot \mathsf{PI}\left(\right) + {angle}^{2} \cdot \left(\frac{-1}{11664000} \cdot {\mathsf{PI}\left(\right)}^{3} + \frac{-1}{34992000} \cdot {\mathsf{PI}\left(\right)}^{3}\right)\right) \cdot angle\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]
                                                11. Applied rewrites30.2%

                                                  \[\leadsto \color{blue}{\left(\mathsf{fma}\left(\left(\left(\pi \cdot \pi\right) \cdot \pi\right) \cdot -1.1431184270690443 \cdot 10^{-7}, angle \cdot angle, \pi \cdot 0.005555555555555556\right) \cdot angle\right)} \cdot \left(\left(a \cdot a\right) \cdot 2\right) \]

                                                if 5.0000000000000003e230 < (/.f64 angle #s(literal 180 binary64))

                                                1. Initial program 35.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                Alternative 15: 62.7% accurate, 7.7× speedup?

                                                \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq 3.4 \cdot 10^{+167}:\\ \;\;\;\;\left(\left(0.011111111111111112 \cdot \left(a + b\right)\right) \cdot \left(\pi \cdot angle\right)\right) \cdot \left(b - a\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-1.54320987654321 \cdot 10^{-5} \cdot \left(angle \cdot angle\right), \pi \cdot \pi, 1\right) \cdot \left(\left(\left(\left(\pi \cdot \left(b - a\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right)\\ \end{array} \end{array} \]
                                                (FPCore (a b angle)
                                                 :precision binary64
                                                 (if (<= b 3.4e+167)
                                                   (* (* (* 0.011111111111111112 (+ a b)) (* PI angle)) (- b a))
                                                   (*
                                                    (fma (* -1.54320987654321e-5 (* angle angle)) (* PI PI) 1.0)
                                                    (* (* (* (* PI (- b a)) angle) 0.011111111111111112) (+ a b)))))
                                                double code(double a, double b, double angle) {
                                                	double tmp;
                                                	if (b <= 3.4e+167) {
                                                		tmp = ((0.011111111111111112 * (a + b)) * (((double) M_PI) * angle)) * (b - a);
                                                	} else {
                                                		tmp = fma((-1.54320987654321e-5 * (angle * angle)), (((double) M_PI) * ((double) M_PI)), 1.0) * ((((((double) M_PI) * (b - a)) * angle) * 0.011111111111111112) * (a + b));
                                                	}
                                                	return tmp;
                                                }
                                                
                                                function code(a, b, angle)
                                                	tmp = 0.0
                                                	if (b <= 3.4e+167)
                                                		tmp = Float64(Float64(Float64(0.011111111111111112 * Float64(a + b)) * Float64(pi * angle)) * Float64(b - a));
                                                	else
                                                		tmp = Float64(fma(Float64(-1.54320987654321e-5 * Float64(angle * angle)), Float64(pi * pi), 1.0) * Float64(Float64(Float64(Float64(pi * Float64(b - a)) * angle) * 0.011111111111111112) * Float64(a + b)));
                                                	end
                                                	return tmp
                                                end
                                                
                                                code[a_, b_, angle_] := If[LessEqual[b, 3.4e+167], N[(N[(N[(0.011111111111111112 * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(Pi * angle), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision], N[(N[(N[(-1.54320987654321e-5 * N[(angle * angle), $MachinePrecision]), $MachinePrecision] * N[(Pi * Pi), $MachinePrecision] + 1.0), $MachinePrecision] * N[(N[(N[(N[(Pi * N[(b - a), $MachinePrecision]), $MachinePrecision] * angle), $MachinePrecision] * 0.011111111111111112), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
                                                
                                                \begin{array}{l}
                                                
                                                \\
                                                \begin{array}{l}
                                                \mathbf{if}\;b \leq 3.4 \cdot 10^{+167}:\\
                                                \;\;\;\;\left(\left(0.011111111111111112 \cdot \left(a + b\right)\right) \cdot \left(\pi \cdot angle\right)\right) \cdot \left(b - a\right)\\
                                                
                                                \mathbf{else}:\\
                                                \;\;\;\;\mathsf{fma}\left(-1.54320987654321 \cdot 10^{-5} \cdot \left(angle \cdot angle\right), \pi \cdot \pi, 1\right) \cdot \left(\left(\left(\left(\pi \cdot \left(b - a\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right)\\
                                                
                                                
                                                \end{array}
                                                \end{array}
                                                
                                                Derivation
                                                1. Split input into 2 regimes
                                                2. if b < 3.4e167

                                                  1. Initial program 55.2%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                    if 3.4e167 < b

                                                    1. Initial program 44.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                        \[\leadsto \left(\left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \color{blue}{\pi}\right) \cdot angle\right) \cdot 0.011111111111111112\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right) \]
                                                    7. Applied rewrites78.3%

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

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

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

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

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

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

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

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

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

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

                                                        \[\leadsto \left(\left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \frac{1}{90}\right)\right) \cdot \mathsf{fma}\left(\frac{-1}{64800} \cdot \left(angle \cdot angle\right), \color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right), 1\right) \]
                                                      10. lower-PI.f6481.0

                                                        \[\leadsto \left(\left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right)\right) \cdot \mathsf{fma}\left(-1.54320987654321 \cdot 10^{-5} \cdot \left(angle \cdot angle\right), \pi \cdot \color{blue}{\pi}, 1\right) \]
                                                    10. Applied rewrites81.0%

                                                      \[\leadsto \left(\left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \pi\right) \cdot angle\right) \cdot 0.011111111111111112\right)\right) \cdot \color{blue}{\mathsf{fma}\left(-1.54320987654321 \cdot 10^{-5} \cdot \left(angle \cdot angle\right), \pi \cdot \pi, 1\right)} \]
                                                  7. Recombined 2 regimes into one program.
                                                  8. Final simplification64.4%

                                                    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq 3.4 \cdot 10^{+167}:\\ \;\;\;\;\left(\left(0.011111111111111112 \cdot \left(a + b\right)\right) \cdot \left(\pi \cdot angle\right)\right) \cdot \left(b - a\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-1.54320987654321 \cdot 10^{-5} \cdot \left(angle \cdot angle\right), \pi \cdot \pi, 1\right) \cdot \left(\left(\left(\left(\pi \cdot \left(b - a\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(a + b\right)\right)\\ \end{array} \]
                                                  9. Add Preprocessing

                                                  Alternative 16: 62.4% accurate, 16.8× speedup?

                                                  \[\begin{array}{l} \\ \left(\left(0.011111111111111112 \cdot \left(a + b\right)\right) \cdot \left(\pi \cdot angle\right)\right) \cdot \left(b - a\right) \end{array} \]
                                                  (FPCore (a b angle)
                                                   :precision binary64
                                                   (* (* (* 0.011111111111111112 (+ a b)) (* PI angle)) (- b a)))
                                                  double code(double a, double b, double angle) {
                                                  	return ((0.011111111111111112 * (a + b)) * (((double) M_PI) * angle)) * (b - a);
                                                  }
                                                  
                                                  public static double code(double a, double b, double angle) {
                                                  	return ((0.011111111111111112 * (a + b)) * (Math.PI * angle)) * (b - a);
                                                  }
                                                  
                                                  def code(a, b, angle):
                                                  	return ((0.011111111111111112 * (a + b)) * (math.pi * angle)) * (b - a)
                                                  
                                                  function code(a, b, angle)
                                                  	return Float64(Float64(Float64(0.011111111111111112 * Float64(a + b)) * Float64(pi * angle)) * Float64(b - a))
                                                  end
                                                  
                                                  function tmp = code(a, b, angle)
                                                  	tmp = ((0.011111111111111112 * (a + b)) * (pi * angle)) * (b - a);
                                                  end
                                                  
                                                  code[a_, b_, angle_] := N[(N[(N[(0.011111111111111112 * N[(a + b), $MachinePrecision]), $MachinePrecision] * N[(Pi * angle), $MachinePrecision]), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision]
                                                  
                                                  \begin{array}{l}
                                                  
                                                  \\
                                                  \left(\left(0.011111111111111112 \cdot \left(a + b\right)\right) \cdot \left(\pi \cdot angle\right)\right) \cdot \left(b - a\right)
                                                  \end{array}
                                                  
                                                  Derivation
                                                  1. Initial program 53.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                    Alternative 17: 62.4% accurate, 16.8× speedup?

                                                    \[\begin{array}{l} \\ \left(\left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right) \end{array} \]
                                                    (FPCore (a b angle)
                                                     :precision binary64
                                                     (* (* (* (* 0.011111111111111112 angle) PI) (- b a)) (+ a b)))
                                                    double code(double a, double b, double angle) {
                                                    	return (((0.011111111111111112 * angle) * ((double) M_PI)) * (b - a)) * (a + b);
                                                    }
                                                    
                                                    public static double code(double a, double b, double angle) {
                                                    	return (((0.011111111111111112 * angle) * Math.PI) * (b - a)) * (a + b);
                                                    }
                                                    
                                                    def code(a, b, angle):
                                                    	return (((0.011111111111111112 * angle) * math.pi) * (b - a)) * (a + b)
                                                    
                                                    function code(a, b, angle)
                                                    	return Float64(Float64(Float64(Float64(0.011111111111111112 * angle) * pi) * Float64(b - a)) * Float64(a + b))
                                                    end
                                                    
                                                    function tmp = code(a, b, angle)
                                                    	tmp = (((0.011111111111111112 * angle) * pi) * (b - a)) * (a + b);
                                                    end
                                                    
                                                    code[a_, b_, angle_] := N[(N[(N[(N[(0.011111111111111112 * angle), $MachinePrecision] * Pi), $MachinePrecision] * N[(b - a), $MachinePrecision]), $MachinePrecision] * N[(a + b), $MachinePrecision]), $MachinePrecision]
                                                    
                                                    \begin{array}{l}
                                                    
                                                    \\
                                                    \left(\left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right) \cdot \left(b - a\right)\right) \cdot \left(a + b\right)
                                                    \end{array}
                                                    
                                                    Derivation
                                                    1. Initial program 53.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                        \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \left(\left(0.011111111111111112 \cdot angle\right) \cdot \pi\right)\right)} \]
                                                      2. Final simplification62.8%

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

                                                      Alternative 18: 38.6% accurate, 21.6× speedup?

                                                      \[\begin{array}{l} \\ \left(\left(-0.011111111111111112 \cdot a\right) \cdot angle\right) \cdot \left(\pi \cdot a\right) \end{array} \]
                                                      (FPCore (a b angle)
                                                       :precision binary64
                                                       (* (* (* -0.011111111111111112 a) angle) (* PI a)))
                                                      double code(double a, double b, double angle) {
                                                      	return ((-0.011111111111111112 * a) * angle) * (((double) M_PI) * a);
                                                      }
                                                      
                                                      public static double code(double a, double b, double angle) {
                                                      	return ((-0.011111111111111112 * a) * angle) * (Math.PI * a);
                                                      }
                                                      
                                                      def code(a, b, angle):
                                                      	return ((-0.011111111111111112 * a) * angle) * (math.pi * a)
                                                      
                                                      function code(a, b, angle)
                                                      	return Float64(Float64(Float64(-0.011111111111111112 * a) * angle) * Float64(pi * a))
                                                      end
                                                      
                                                      function tmp = code(a, b, angle)
                                                      	tmp = ((-0.011111111111111112 * a) * angle) * (pi * a);
                                                      end
                                                      
                                                      code[a_, b_, angle_] := N[(N[(N[(-0.011111111111111112 * a), $MachinePrecision] * angle), $MachinePrecision] * N[(Pi * a), $MachinePrecision]), $MachinePrecision]
                                                      
                                                      \begin{array}{l}
                                                      
                                                      \\
                                                      \left(\left(-0.011111111111111112 \cdot a\right) \cdot angle\right) \cdot \left(\pi \cdot a\right)
                                                      \end{array}
                                                      
                                                      Derivation
                                                      1. Initial program 53.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                            Alternative 19: 38.6% accurate, 21.6× speedup?

                                                            \[\begin{array}{l} \\ \left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(\pi \cdot angle\right) \cdot a\right) \end{array} \]
                                                            (FPCore (a b angle)
                                                             :precision binary64
                                                             (* (* -0.011111111111111112 a) (* (* PI angle) a)))
                                                            double code(double a, double b, double angle) {
                                                            	return (-0.011111111111111112 * a) * ((((double) M_PI) * angle) * a);
                                                            }
                                                            
                                                            public static double code(double a, double b, double angle) {
                                                            	return (-0.011111111111111112 * a) * ((Math.PI * angle) * a);
                                                            }
                                                            
                                                            def code(a, b, angle):
                                                            	return (-0.011111111111111112 * a) * ((math.pi * angle) * a)
                                                            
                                                            function code(a, b, angle)
                                                            	return Float64(Float64(-0.011111111111111112 * a) * Float64(Float64(pi * angle) * a))
                                                            end
                                                            
                                                            function tmp = code(a, b, angle)
                                                            	tmp = (-0.011111111111111112 * a) * ((pi * angle) * a);
                                                            end
                                                            
                                                            code[a_, b_, angle_] := N[(N[(-0.011111111111111112 * a), $MachinePrecision] * N[(N[(Pi * angle), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision]
                                                            
                                                            \begin{array}{l}
                                                            
                                                            \\
                                                            \left(-0.011111111111111112 \cdot a\right) \cdot \left(\left(\pi \cdot angle\right) \cdot a\right)
                                                            \end{array}
                                                            
                                                            Derivation
                                                            1. Initial program 53.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                                Reproduce

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