ab-angle->ABCF B

Percentage Accurate: 54.1% → 67.8%
Time: 56.0s
Alternatives: 17
Speedup: 14.6×

Specification

?
\[\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} \]
(FPCore (a b angle)
  :precision binary64
  (let* ((t_0 (* PI (/ angle 180))))
  (* (* (* 2 (- (pow b 2) (pow a 2))) (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), $MachinePrecision]), $MachinePrecision]}, N[(N[(N[(2 * N[(N[Power[b, 2], $MachinePrecision] - N[Power[a, 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision] * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision]]
\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}

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 17 alternatives:

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

Initial Program: 54.1% accurate, 1.0× speedup?

\[\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} \]
(FPCore (a b angle)
  :precision binary64
  (let* ((t_0 (* PI (/ angle 180))))
  (* (* (* 2 (- (pow b 2) (pow a 2))) (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), $MachinePrecision]), $MachinePrecision]}, N[(N[(N[(2 * N[(N[Power[b, 2], $MachinePrecision] - N[Power[a, 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision] * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision]]
\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}

Alternative 1: 67.8% accurate, 1.8× speedup?

\[\begin{array}{l} t_0 := a + \left|b\right|\\ t_1 := \left|b\right| - a\\ \mathsf{copysign}\left(1, angle\right) \cdot \begin{array}{l} \mathbf{if}\;\left|angle\right| \leq \frac{4113761393303015}{102844034832575377634685573909834406561420991602098741459288064}:\\ \;\;\;\;t\_1 \cdot \left(\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot t\_0\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(t\_1 \cdot t\_0\right) \cdot \sin \left(\left(\left|angle\right| \cdot \pi\right) \cdot \frac{1}{90}\right)\\ \end{array} \end{array} \]
(FPCore (a b angle)
  :precision binary64
  (let* ((t_0 (+ a (fabs b))) (t_1 (- (fabs b) a)))
  (*
   (copysign 1 angle)
   (if (<=
        (fabs angle)
        4113761393303015/102844034832575377634685573909834406561420991602098741459288064)
     (* t_1 (* 1/90 (* (fabs angle) (* PI t_0))))
     (* (* t_1 t_0) (sin (* (* (fabs angle) PI) 1/90)))))))
double code(double a, double b, double angle) {
	double t_0 = a + fabs(b);
	double t_1 = fabs(b) - a;
	double tmp;
	if (fabs(angle) <= 4e-47) {
		tmp = t_1 * (0.011111111111111112 * (fabs(angle) * (((double) M_PI) * t_0)));
	} else {
		tmp = (t_1 * t_0) * sin(((fabs(angle) * ((double) M_PI)) * 0.011111111111111112));
	}
	return copysign(1.0, angle) * tmp;
}
public static double code(double a, double b, double angle) {
	double t_0 = a + Math.abs(b);
	double t_1 = Math.abs(b) - a;
	double tmp;
	if (Math.abs(angle) <= 4e-47) {
		tmp = t_1 * (0.011111111111111112 * (Math.abs(angle) * (Math.PI * t_0)));
	} else {
		tmp = (t_1 * t_0) * Math.sin(((Math.abs(angle) * Math.PI) * 0.011111111111111112));
	}
	return Math.copySign(1.0, angle) * tmp;
}
def code(a, b, angle):
	t_0 = a + math.fabs(b)
	t_1 = math.fabs(b) - a
	tmp = 0
	if math.fabs(angle) <= 4e-47:
		tmp = t_1 * (0.011111111111111112 * (math.fabs(angle) * (math.pi * t_0)))
	else:
		tmp = (t_1 * t_0) * math.sin(((math.fabs(angle) * math.pi) * 0.011111111111111112))
	return math.copysign(1.0, angle) * tmp
function code(a, b, angle)
	t_0 = Float64(a + abs(b))
	t_1 = Float64(abs(b) - a)
	tmp = 0.0
	if (abs(angle) <= 4e-47)
		tmp = Float64(t_1 * Float64(0.011111111111111112 * Float64(abs(angle) * Float64(pi * t_0))));
	else
		tmp = Float64(Float64(t_1 * t_0) * sin(Float64(Float64(abs(angle) * pi) * 0.011111111111111112)));
	end
	return Float64(copysign(1.0, angle) * tmp)
end
function tmp_2 = code(a, b, angle)
	t_0 = a + abs(b);
	t_1 = abs(b) - a;
	tmp = 0.0;
	if (abs(angle) <= 4e-47)
		tmp = t_1 * (0.011111111111111112 * (abs(angle) * (pi * t_0)));
	else
		tmp = (t_1 * t_0) * sin(((abs(angle) * pi) * 0.011111111111111112));
	end
	tmp_2 = (sign(angle) * abs(1.0)) * tmp;
end
code[a_, b_, angle_] := Block[{t$95$0 = N[(a + N[Abs[b], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[Abs[b], $MachinePrecision] - a), $MachinePrecision]}, N[(N[With[{TMP1 = Abs[1], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision] * If[LessEqual[N[Abs[angle], $MachinePrecision], 4113761393303015/102844034832575377634685573909834406561420991602098741459288064], N[(t$95$1 * N[(1/90 * N[(N[Abs[angle], $MachinePrecision] * N[(Pi * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t$95$1 * t$95$0), $MachinePrecision] * N[Sin[N[(N[(N[Abs[angle], $MachinePrecision] * Pi), $MachinePrecision] * 1/90), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]]
\begin{array}{l}
t_0 := a + \left|b\right|\\
t_1 := \left|b\right| - a\\
\mathsf{copysign}\left(1, angle\right) \cdot \begin{array}{l}
\mathbf{if}\;\left|angle\right| \leq \frac{4113761393303015}{102844034832575377634685573909834406561420991602098741459288064}:\\
\;\;\;\;t\_1 \cdot \left(\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot t\_0\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\left(t\_1 \cdot t\_0\right) \cdot \sin \left(\left(\left|angle\right| \cdot \pi\right) \cdot \frac{1}{90}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if angle < 3.9999999999999999e-47

    1. Initial program 54.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. Step-by-step derivation
      1. lift-*.f64N/A

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
    4. Step-by-step derivation
      1. lift-134-z0z1z2z3z4N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 3.9999999999999999e-47 < angle

    1. Initial program 54.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. Step-by-step derivation
      1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

Alternative 2: 67.8% accurate, 3.5× speedup?

\[\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right) \]
(FPCore (a b angle)
  :precision binary64
  (134-z0z1z2z3z4 (sin (* (* angle PI) 1/90)) b b a a))
\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)
Derivation
  1. Initial program 54.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. Step-by-step derivation
    1. lift-*.f64N/A

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

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

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

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

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

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

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

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

    \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
  4. Add Preprocessing

Alternative 3: 67.7% accurate, 3.6× speedup?

\[\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right)\right) \]
(FPCore (a b angle)
  :precision binary64
  (* (+ a b) (* (- b a) (sin (* (* angle PI) 1/90)))))
double code(double a, double b, double angle) {
	return (a + b) * ((b - a) * sin(((angle * ((double) M_PI)) * 0.011111111111111112)));
}
public static double code(double a, double b, double angle) {
	return (a + b) * ((b - a) * Math.sin(((angle * Math.PI) * 0.011111111111111112)));
}
def code(a, b, angle):
	return (a + b) * ((b - a) * math.sin(((angle * math.pi) * 0.011111111111111112)))
function code(a, b, angle)
	return Float64(Float64(a + b) * Float64(Float64(b - a) * sin(Float64(Float64(angle * pi) * 0.011111111111111112))))
end
function tmp = code(a, b, angle)
	tmp = (a + b) * ((b - a) * sin(((angle * pi) * 0.011111111111111112)));
end
code[a_, b_, angle_] := N[(N[(a + b), $MachinePrecision] * N[(N[(b - a), $MachinePrecision] * N[Sin[N[(N[(angle * Pi), $MachinePrecision] * 1/90), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right)\right)
Derivation
  1. Initial program 54.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. Step-by-step derivation
    1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

Alternative 4: 67.3% accurate, 1.8× speedup?

\[\begin{array}{l} t_0 := a + \left|b\right|\\ t_1 := \left|b\right| - a\\ \mathsf{copysign}\left(1, angle\right) \cdot \begin{array}{l} \mathbf{if}\;\left|angle\right| \leq \frac{3946757204148067}{127314748520905380391777855525586135065716774604121015664758778084648831235208544136462336}:\\ \;\;\;\;t\_1 \cdot \left(\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot t\_0\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(t\_1 \cdot t\_0\right) \cdot \sin \left(\left(\frac{1}{90} \cdot \pi\right) \cdot \left|angle\right|\right)\\ \end{array} \end{array} \]
(FPCore (a b angle)
  :precision binary64
  (let* ((t_0 (+ a (fabs b))) (t_1 (- (fabs b) a)))
  (*
   (copysign 1 angle)
   (if (<=
        (fabs angle)
        3946757204148067/127314748520905380391777855525586135065716774604121015664758778084648831235208544136462336)
     (* t_1 (* 1/90 (* (fabs angle) (* PI t_0))))
     (* (* t_1 t_0) (sin (* (* 1/90 PI) (fabs angle))))))))
double code(double a, double b, double angle) {
	double t_0 = a + fabs(b);
	double t_1 = fabs(b) - a;
	double tmp;
	if (fabs(angle) <= 3.1e-74) {
		tmp = t_1 * (0.011111111111111112 * (fabs(angle) * (((double) M_PI) * t_0)));
	} else {
		tmp = (t_1 * t_0) * sin(((0.011111111111111112 * ((double) M_PI)) * fabs(angle)));
	}
	return copysign(1.0, angle) * tmp;
}
public static double code(double a, double b, double angle) {
	double t_0 = a + Math.abs(b);
	double t_1 = Math.abs(b) - a;
	double tmp;
	if (Math.abs(angle) <= 3.1e-74) {
		tmp = t_1 * (0.011111111111111112 * (Math.abs(angle) * (Math.PI * t_0)));
	} else {
		tmp = (t_1 * t_0) * Math.sin(((0.011111111111111112 * Math.PI) * Math.abs(angle)));
	}
	return Math.copySign(1.0, angle) * tmp;
}
def code(a, b, angle):
	t_0 = a + math.fabs(b)
	t_1 = math.fabs(b) - a
	tmp = 0
	if math.fabs(angle) <= 3.1e-74:
		tmp = t_1 * (0.011111111111111112 * (math.fabs(angle) * (math.pi * t_0)))
	else:
		tmp = (t_1 * t_0) * math.sin(((0.011111111111111112 * math.pi) * math.fabs(angle)))
	return math.copysign(1.0, angle) * tmp
function code(a, b, angle)
	t_0 = Float64(a + abs(b))
	t_1 = Float64(abs(b) - a)
	tmp = 0.0
	if (abs(angle) <= 3.1e-74)
		tmp = Float64(t_1 * Float64(0.011111111111111112 * Float64(abs(angle) * Float64(pi * t_0))));
	else
		tmp = Float64(Float64(t_1 * t_0) * sin(Float64(Float64(0.011111111111111112 * pi) * abs(angle))));
	end
	return Float64(copysign(1.0, angle) * tmp)
end
function tmp_2 = code(a, b, angle)
	t_0 = a + abs(b);
	t_1 = abs(b) - a;
	tmp = 0.0;
	if (abs(angle) <= 3.1e-74)
		tmp = t_1 * (0.011111111111111112 * (abs(angle) * (pi * t_0)));
	else
		tmp = (t_1 * t_0) * sin(((0.011111111111111112 * pi) * abs(angle)));
	end
	tmp_2 = (sign(angle) * abs(1.0)) * tmp;
end
code[a_, b_, angle_] := Block[{t$95$0 = N[(a + N[Abs[b], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[Abs[b], $MachinePrecision] - a), $MachinePrecision]}, N[(N[With[{TMP1 = Abs[1], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision] * If[LessEqual[N[Abs[angle], $MachinePrecision], 3946757204148067/127314748520905380391777855525586135065716774604121015664758778084648831235208544136462336], N[(t$95$1 * N[(1/90 * N[(N[Abs[angle], $MachinePrecision] * N[(Pi * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t$95$1 * t$95$0), $MachinePrecision] * N[Sin[N[(N[(1/90 * Pi), $MachinePrecision] * N[Abs[angle], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]]
\begin{array}{l}
t_0 := a + \left|b\right|\\
t_1 := \left|b\right| - a\\
\mathsf{copysign}\left(1, angle\right) \cdot \begin{array}{l}
\mathbf{if}\;\left|angle\right| \leq \frac{3946757204148067}{127314748520905380391777855525586135065716774604121015664758778084648831235208544136462336}:\\
\;\;\;\;t\_1 \cdot \left(\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot t\_0\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\left(t\_1 \cdot t\_0\right) \cdot \sin \left(\left(\frac{1}{90} \cdot \pi\right) \cdot \left|angle\right|\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if angle < 3.1000000000000002e-74

    1. Initial program 54.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. Step-by-step derivation
      1. lift-*.f64N/A

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
    4. Step-by-step derivation
      1. lift-134-z0z1z2z3z4N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 3.1000000000000002e-74 < angle

    1. Initial program 54.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. Step-by-step derivation
      1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 5: 67.0% accurate, 1.3× speedup?

\[\begin{array}{l} t_0 := \left|b\right| - \left|a\right|\\ t_1 := \sin \left(\frac{1}{90} \cdot \left(angle \cdot \pi\right)\right)\\ \mathbf{if}\;2 \cdot \left({\left(\left|b\right|\right)}^{2} - {\left(\left|a\right|\right)}^{2}\right) \leq \frac{-8254602048994769}{16509204097989538948510618278641143953713978938628797566498772157083559454897651858575539246489287121708574843539285271215073361234458923039079343076966861778387083874968908880272859927388326282907007278381599637629625884148486304338699903086469889890298080653054312448}:\\ \;\;\;\;t\_0 \cdot \left(\left|a\right| \cdot t\_1\right)\\ \mathbf{else}:\\ \;\;\;\;t\_0 \cdot \left(\left|b\right| \cdot t\_1\right)\\ \end{array} \]
(FPCore (a b angle)
  :precision binary64
  (let* ((t_0 (- (fabs b) (fabs a))) (t_1 (sin (* 1/90 (* angle PI)))))
  (if (<=
       (* 2 (- (pow (fabs b) 2) (pow (fabs a) 2)))
       -8254602048994769/16509204097989538948510618278641143953713978938628797566498772157083559454897651858575539246489287121708574843539285271215073361234458923039079343076966861778387083874968908880272859927388326282907007278381599637629625884148486304338699903086469889890298080653054312448)
    (* t_0 (* (fabs a) t_1))
    (* t_0 (* (fabs b) t_1)))))
double code(double a, double b, double angle) {
	double t_0 = fabs(b) - fabs(a);
	double t_1 = sin((0.011111111111111112 * (angle * ((double) M_PI))));
	double tmp;
	if ((2.0 * (pow(fabs(b), 2.0) - pow(fabs(a), 2.0))) <= -5e-253) {
		tmp = t_0 * (fabs(a) * t_1);
	} else {
		tmp = t_0 * (fabs(b) * t_1);
	}
	return tmp;
}
public static double code(double a, double b, double angle) {
	double t_0 = Math.abs(b) - Math.abs(a);
	double t_1 = Math.sin((0.011111111111111112 * (angle * Math.PI)));
	double tmp;
	if ((2.0 * (Math.pow(Math.abs(b), 2.0) - Math.pow(Math.abs(a), 2.0))) <= -5e-253) {
		tmp = t_0 * (Math.abs(a) * t_1);
	} else {
		tmp = t_0 * (Math.abs(b) * t_1);
	}
	return tmp;
}
def code(a, b, angle):
	t_0 = math.fabs(b) - math.fabs(a)
	t_1 = math.sin((0.011111111111111112 * (angle * math.pi)))
	tmp = 0
	if (2.0 * (math.pow(math.fabs(b), 2.0) - math.pow(math.fabs(a), 2.0))) <= -5e-253:
		tmp = t_0 * (math.fabs(a) * t_1)
	else:
		tmp = t_0 * (math.fabs(b) * t_1)
	return tmp
function code(a, b, angle)
	t_0 = Float64(abs(b) - abs(a))
	t_1 = sin(Float64(0.011111111111111112 * Float64(angle * pi)))
	tmp = 0.0
	if (Float64(2.0 * Float64((abs(b) ^ 2.0) - (abs(a) ^ 2.0))) <= -5e-253)
		tmp = Float64(t_0 * Float64(abs(a) * t_1));
	else
		tmp = Float64(t_0 * Float64(abs(b) * t_1));
	end
	return tmp
end
function tmp_2 = code(a, b, angle)
	t_0 = abs(b) - abs(a);
	t_1 = sin((0.011111111111111112 * (angle * pi)));
	tmp = 0.0;
	if ((2.0 * ((abs(b) ^ 2.0) - (abs(a) ^ 2.0))) <= -5e-253)
		tmp = t_0 * (abs(a) * t_1);
	else
		tmp = t_0 * (abs(b) * t_1);
	end
	tmp_2 = tmp;
end
code[a_, b_, angle_] := Block[{t$95$0 = N[(N[Abs[b], $MachinePrecision] - N[Abs[a], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[Sin[N[(1/90 * N[(angle * Pi), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[N[(2 * N[(N[Power[N[Abs[b], $MachinePrecision], 2], $MachinePrecision] - N[Power[N[Abs[a], $MachinePrecision], 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -8254602048994769/16509204097989538948510618278641143953713978938628797566498772157083559454897651858575539246489287121708574843539285271215073361234458923039079343076966861778387083874968908880272859927388326282907007278381599637629625884148486304338699903086469889890298080653054312448], N[(t$95$0 * N[(N[Abs[a], $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision], N[(t$95$0 * N[(N[Abs[b], $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
t_0 := \left|b\right| - \left|a\right|\\
t_1 := \sin \left(\frac{1}{90} \cdot \left(angle \cdot \pi\right)\right)\\
\mathbf{if}\;2 \cdot \left({\left(\left|b\right|\right)}^{2} - {\left(\left|a\right|\right)}^{2}\right) \leq \frac{-8254602048994769}{16509204097989538948510618278641143953713978938628797566498772157083559454897651858575539246489287121708574843539285271215073361234458923039079343076966861778387083874968908880272859927388326282907007278381599637629625884148486304338699903086469889890298080653054312448}:\\
\;\;\;\;t\_0 \cdot \left(\left|a\right| \cdot t\_1\right)\\

\mathbf{else}:\\
\;\;\;\;t\_0 \cdot \left(\left|b\right| \cdot t\_1\right)\\


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

    1. Initial program 54.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. Step-by-step derivation
      1. lift-*.f64N/A

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
    4. Step-by-step derivation
      1. lift-134-z0z1z2z3z4N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(b - a\right) \cdot \left(a \cdot \sin \left(\frac{1}{90} \cdot \left(angle \cdot \pi\right)\right)\right) \]
    8. Applied rewrites42.6%

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

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

    1. Initial program 54.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. Step-by-step derivation
      1. lift-*.f64N/A

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
    4. Step-by-step derivation
      1. lift-134-z0z1z2z3z4N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(b - a\right) \cdot \left(b \cdot \sin \left(\frac{1}{90} \cdot \left(angle \cdot \pi\right)\right)\right) \]
    8. Applied rewrites42.0%

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

Alternative 6: 66.4% accurate, 0.8× speedup?

\[\begin{array}{l} t_0 := 2 \cdot \left({\left(\left|b\right|\right)}^{2} - {a}^{2}\right)\\ t_1 := a + \left|b\right|\\ t_2 := \left|b\right| - a\\ \mathbf{if}\;t\_0 \leq \frac{-8254602048994769}{16509204097989538948510618278641143953713978938628797566498772157083559454897651858575539246489287121708574843539285271215073361234458923039079343076966861778387083874968908880272859927388326282907007278381599637629625884148486304338699903086469889890298080653054312448}:\\ \;\;\;\;t\_2 \cdot \left(a \cdot \sin \left(\frac{1}{90} \cdot \left(angle \cdot \pi\right)\right)\right)\\ \mathbf{elif}\;t\_0 \leq 49999999999999996962677625276823109300201436100586624765953857856616022815066169514216546287202538742184280590280810862893585968713180152651178994204334413874936507208410055205338551265812204529218599012742757995383198412754109163297745561348039749026730174593312862032038021904229799310374521740690718720:\\ \;\;\;\;\left(\left|b\right| \cdot t\_1\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right)\\ \mathbf{else}:\\ \;\;\;\;t\_2 \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot t\_1\right)\right)\right)\\ \end{array} \]
(FPCore (a b angle)
  :precision binary64
  (let* ((t_0 (* 2 (- (pow (fabs b) 2) (pow a 2))))
       (t_1 (+ a (fabs b)))
       (t_2 (- (fabs b) a)))
  (if (<=
       t_0
       -8254602048994769/16509204097989538948510618278641143953713978938628797566498772157083559454897651858575539246489287121708574843539285271215073361234458923039079343076966861778387083874968908880272859927388326282907007278381599637629625884148486304338699903086469889890298080653054312448)
    (* t_2 (* a (sin (* 1/90 (* angle PI)))))
    (if (<=
         t_0
         49999999999999996962677625276823109300201436100586624765953857856616022815066169514216546287202538742184280590280810862893585968713180152651178994204334413874936507208410055205338551265812204529218599012742757995383198412754109163297745561348039749026730174593312862032038021904229799310374521740690718720)
      (* (* (fabs b) t_1) (sin (* (* angle PI) 1/90)))
      (* t_2 (* 1/90 (* angle (* PI t_1))))))))
double code(double a, double b, double angle) {
	double t_0 = 2.0 * (pow(fabs(b), 2.0) - pow(a, 2.0));
	double t_1 = a + fabs(b);
	double t_2 = fabs(b) - a;
	double tmp;
	if (t_0 <= -5e-253) {
		tmp = t_2 * (a * sin((0.011111111111111112 * (angle * ((double) M_PI)))));
	} else if (t_0 <= 5e+304) {
		tmp = (fabs(b) * t_1) * sin(((angle * ((double) M_PI)) * 0.011111111111111112));
	} else {
		tmp = t_2 * (0.011111111111111112 * (angle * (((double) M_PI) * t_1)));
	}
	return tmp;
}
public static double code(double a, double b, double angle) {
	double t_0 = 2.0 * (Math.pow(Math.abs(b), 2.0) - Math.pow(a, 2.0));
	double t_1 = a + Math.abs(b);
	double t_2 = Math.abs(b) - a;
	double tmp;
	if (t_0 <= -5e-253) {
		tmp = t_2 * (a * Math.sin((0.011111111111111112 * (angle * Math.PI))));
	} else if (t_0 <= 5e+304) {
		tmp = (Math.abs(b) * t_1) * Math.sin(((angle * Math.PI) * 0.011111111111111112));
	} else {
		tmp = t_2 * (0.011111111111111112 * (angle * (Math.PI * t_1)));
	}
	return tmp;
}
def code(a, b, angle):
	t_0 = 2.0 * (math.pow(math.fabs(b), 2.0) - math.pow(a, 2.0))
	t_1 = a + math.fabs(b)
	t_2 = math.fabs(b) - a
	tmp = 0
	if t_0 <= -5e-253:
		tmp = t_2 * (a * math.sin((0.011111111111111112 * (angle * math.pi))))
	elif t_0 <= 5e+304:
		tmp = (math.fabs(b) * t_1) * math.sin(((angle * math.pi) * 0.011111111111111112))
	else:
		tmp = t_2 * (0.011111111111111112 * (angle * (math.pi * t_1)))
	return tmp
function code(a, b, angle)
	t_0 = Float64(2.0 * Float64((abs(b) ^ 2.0) - (a ^ 2.0)))
	t_1 = Float64(a + abs(b))
	t_2 = Float64(abs(b) - a)
	tmp = 0.0
	if (t_0 <= -5e-253)
		tmp = Float64(t_2 * Float64(a * sin(Float64(0.011111111111111112 * Float64(angle * pi)))));
	elseif (t_0 <= 5e+304)
		tmp = Float64(Float64(abs(b) * t_1) * sin(Float64(Float64(angle * pi) * 0.011111111111111112)));
	else
		tmp = Float64(t_2 * Float64(0.011111111111111112 * Float64(angle * Float64(pi * t_1))));
	end
	return tmp
end
function tmp_2 = code(a, b, angle)
	t_0 = 2.0 * ((abs(b) ^ 2.0) - (a ^ 2.0));
	t_1 = a + abs(b);
	t_2 = abs(b) - a;
	tmp = 0.0;
	if (t_0 <= -5e-253)
		tmp = t_2 * (a * sin((0.011111111111111112 * (angle * pi))));
	elseif (t_0 <= 5e+304)
		tmp = (abs(b) * t_1) * sin(((angle * pi) * 0.011111111111111112));
	else
		tmp = t_2 * (0.011111111111111112 * (angle * (pi * t_1)));
	end
	tmp_2 = tmp;
end
code[a_, b_, angle_] := Block[{t$95$0 = N[(2 * N[(N[Power[N[Abs[b], $MachinePrecision], 2], $MachinePrecision] - N[Power[a, 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(a + N[Abs[b], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[Abs[b], $MachinePrecision] - a), $MachinePrecision]}, If[LessEqual[t$95$0, -8254602048994769/16509204097989538948510618278641143953713978938628797566498772157083559454897651858575539246489287121708574843539285271215073361234458923039079343076966861778387083874968908880272859927388326282907007278381599637629625884148486304338699903086469889890298080653054312448], N[(t$95$2 * N[(a * N[Sin[N[(1/90 * N[(angle * Pi), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$0, 49999999999999996962677625276823109300201436100586624765953857856616022815066169514216546287202538742184280590280810862893585968713180152651178994204334413874936507208410055205338551265812204529218599012742757995383198412754109163297745561348039749026730174593312862032038021904229799310374521740690718720], N[(N[(N[Abs[b], $MachinePrecision] * t$95$1), $MachinePrecision] * N[Sin[N[(N[(angle * Pi), $MachinePrecision] * 1/90), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(t$95$2 * N[(1/90 * N[(angle * N[(Pi * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
t_0 := 2 \cdot \left({\left(\left|b\right|\right)}^{2} - {a}^{2}\right)\\
t_1 := a + \left|b\right|\\
t_2 := \left|b\right| - a\\
\mathbf{if}\;t\_0 \leq \frac{-8254602048994769}{16509204097989538948510618278641143953713978938628797566498772157083559454897651858575539246489287121708574843539285271215073361234458923039079343076966861778387083874968908880272859927388326282907007278381599637629625884148486304338699903086469889890298080653054312448}:\\
\;\;\;\;t\_2 \cdot \left(a \cdot \sin \left(\frac{1}{90} \cdot \left(angle \cdot \pi\right)\right)\right)\\

\mathbf{elif}\;t\_0 \leq 49999999999999996962677625276823109300201436100586624765953857856616022815066169514216546287202538742184280590280810862893585968713180152651178994204334413874936507208410055205338551265812204529218599012742757995383198412754109163297745561348039749026730174593312862032038021904229799310374521740690718720:\\
\;\;\;\;\left(\left|b\right| \cdot t\_1\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right)\\

\mathbf{else}:\\
\;\;\;\;t\_2 \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot t\_1\right)\right)\right)\\


\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 #s(literal 2 binary64) (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))) < -4.9999999999999997e-253

    1. Initial program 54.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. Step-by-step derivation
      1. lift-*.f64N/A

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
    4. Step-by-step derivation
      1. lift-134-z0z1z2z3z4N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(b - a\right) \cdot \left(a \cdot \sin \left(\frac{1}{90} \cdot \left(angle \cdot \pi\right)\right)\right) \]
    8. Applied rewrites42.6%

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

    if -4.9999999999999997e-253 < (*.f64 #s(literal 2 binary64) (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))) < 4.9999999999999997e304

    1. Initial program 54.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. Step-by-step derivation
      1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

      1. Initial program 54.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. Step-by-step derivation
        1. lift-*.f64N/A

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
      4. Step-by-step derivation
        1. lift-134-z0z1z2z3z4N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(b - a\right) \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(a + b\right)\right)\right)\right)} \]
    6. Recombined 3 regimes into one program.
    7. Add Preprocessing

    Alternative 7: 64.3% accurate, 2.5× speedup?

    \[\begin{array}{l} t_0 := \left|a\right| + \left|b\right|\\ t_1 := \left|b\right| - \left|a\right|\\ \mathsf{copysign}\left(1, angle\right) \cdot \begin{array}{l} \mathbf{if}\;\left|angle\right| \leq 33000:\\ \;\;\;\;t\_1 \cdot \left(\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot t\_0\right)\right)\right)\\ \mathbf{elif}\;\left|angle\right| \leq 450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864:\\ \;\;\;\;\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot \left(\frac{t\_0 \cdot t\_1}{t\_1} \cdot \left|b\right|\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot \left(t\_0 \cdot \left(-1 \cdot \left|a\right|\right)\right)\right)\right)\\ \end{array} \end{array} \]
    (FPCore (a b angle)
      :precision binary64
      (let* ((t_0 (+ (fabs a) (fabs b))) (t_1 (- (fabs b) (fabs a))))
      (*
       (copysign 1 angle)
       (if (<= (fabs angle) 33000)
         (* t_1 (* 1/90 (* (fabs angle) (* PI t_0))))
         (if (<=
              (fabs angle)
              450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864)
           (*
            1/90
            (* (fabs angle) (* PI (* (/ (* t_0 t_1) t_1) (fabs b)))))
           (* 1/90 (* (fabs angle) (* PI (* t_0 (* -1 (fabs a)))))))))))
    double code(double a, double b, double angle) {
    	double t_0 = fabs(a) + fabs(b);
    	double t_1 = fabs(b) - fabs(a);
    	double tmp;
    	if (fabs(angle) <= 33000.0) {
    		tmp = t_1 * (0.011111111111111112 * (fabs(angle) * (((double) M_PI) * t_0)));
    	} else if (fabs(angle) <= 4.5e+287) {
    		tmp = 0.011111111111111112 * (fabs(angle) * (((double) M_PI) * (((t_0 * t_1) / t_1) * fabs(b))));
    	} else {
    		tmp = 0.011111111111111112 * (fabs(angle) * (((double) M_PI) * (t_0 * (-1.0 * fabs(a)))));
    	}
    	return copysign(1.0, angle) * tmp;
    }
    
    public static double code(double a, double b, double angle) {
    	double t_0 = Math.abs(a) + Math.abs(b);
    	double t_1 = Math.abs(b) - Math.abs(a);
    	double tmp;
    	if (Math.abs(angle) <= 33000.0) {
    		tmp = t_1 * (0.011111111111111112 * (Math.abs(angle) * (Math.PI * t_0)));
    	} else if (Math.abs(angle) <= 4.5e+287) {
    		tmp = 0.011111111111111112 * (Math.abs(angle) * (Math.PI * (((t_0 * t_1) / t_1) * Math.abs(b))));
    	} else {
    		tmp = 0.011111111111111112 * (Math.abs(angle) * (Math.PI * (t_0 * (-1.0 * Math.abs(a)))));
    	}
    	return Math.copySign(1.0, angle) * tmp;
    }
    
    def code(a, b, angle):
    	t_0 = math.fabs(a) + math.fabs(b)
    	t_1 = math.fabs(b) - math.fabs(a)
    	tmp = 0
    	if math.fabs(angle) <= 33000.0:
    		tmp = t_1 * (0.011111111111111112 * (math.fabs(angle) * (math.pi * t_0)))
    	elif math.fabs(angle) <= 4.5e+287:
    		tmp = 0.011111111111111112 * (math.fabs(angle) * (math.pi * (((t_0 * t_1) / t_1) * math.fabs(b))))
    	else:
    		tmp = 0.011111111111111112 * (math.fabs(angle) * (math.pi * (t_0 * (-1.0 * math.fabs(a)))))
    	return math.copysign(1.0, angle) * tmp
    
    function code(a, b, angle)
    	t_0 = Float64(abs(a) + abs(b))
    	t_1 = Float64(abs(b) - abs(a))
    	tmp = 0.0
    	if (abs(angle) <= 33000.0)
    		tmp = Float64(t_1 * Float64(0.011111111111111112 * Float64(abs(angle) * Float64(pi * t_0))));
    	elseif (abs(angle) <= 4.5e+287)
    		tmp = Float64(0.011111111111111112 * Float64(abs(angle) * Float64(pi * Float64(Float64(Float64(t_0 * t_1) / t_1) * abs(b)))));
    	else
    		tmp = Float64(0.011111111111111112 * Float64(abs(angle) * Float64(pi * Float64(t_0 * Float64(-1.0 * abs(a))))));
    	end
    	return Float64(copysign(1.0, angle) * tmp)
    end
    
    function tmp_2 = code(a, b, angle)
    	t_0 = abs(a) + abs(b);
    	t_1 = abs(b) - abs(a);
    	tmp = 0.0;
    	if (abs(angle) <= 33000.0)
    		tmp = t_1 * (0.011111111111111112 * (abs(angle) * (pi * t_0)));
    	elseif (abs(angle) <= 4.5e+287)
    		tmp = 0.011111111111111112 * (abs(angle) * (pi * (((t_0 * t_1) / t_1) * abs(b))));
    	else
    		tmp = 0.011111111111111112 * (abs(angle) * (pi * (t_0 * (-1.0 * abs(a)))));
    	end
    	tmp_2 = (sign(angle) * abs(1.0)) * tmp;
    end
    
    code[a_, b_, angle_] := Block[{t$95$0 = N[(N[Abs[a], $MachinePrecision] + N[Abs[b], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[Abs[b], $MachinePrecision] - N[Abs[a], $MachinePrecision]), $MachinePrecision]}, N[(N[With[{TMP1 = Abs[1], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision] * If[LessEqual[N[Abs[angle], $MachinePrecision], 33000], N[(t$95$1 * N[(1/90 * N[(N[Abs[angle], $MachinePrecision] * N[(Pi * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Abs[angle], $MachinePrecision], 450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864], N[(1/90 * N[(N[Abs[angle], $MachinePrecision] * N[(Pi * N[(N[(N[(t$95$0 * t$95$1), $MachinePrecision] / t$95$1), $MachinePrecision] * N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1/90 * N[(N[Abs[angle], $MachinePrecision] * N[(Pi * N[(t$95$0 * N[(-1 * N[Abs[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]]
    
    \begin{array}{l}
    t_0 := \left|a\right| + \left|b\right|\\
    t_1 := \left|b\right| - \left|a\right|\\
    \mathsf{copysign}\left(1, angle\right) \cdot \begin{array}{l}
    \mathbf{if}\;\left|angle\right| \leq 33000:\\
    \;\;\;\;t\_1 \cdot \left(\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot t\_0\right)\right)\right)\\
    
    \mathbf{elif}\;\left|angle\right| \leq 450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864:\\
    \;\;\;\;\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot \left(\frac{t\_0 \cdot t\_1}{t\_1} \cdot \left|b\right|\right)\right)\right)\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot \left(t\_0 \cdot \left(-1 \cdot \left|a\right|\right)\right)\right)\right)\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if angle < 33000

      1. Initial program 54.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. Step-by-step derivation
        1. lift-*.f64N/A

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
      4. Step-by-step derivation
        1. lift-134-z0z1z2z3z4N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if 33000 < angle < 4.5000000000000002e287

      1. Initial program 54.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. Step-by-step derivation
        1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
      6. Applied rewrites54.2%

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

        \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \]
      8. Step-by-step derivation
        1. Applied rewrites37.2%

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

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

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

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

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

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

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

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\frac{b \cdot b - a \cdot a}{b - a} \cdot b\right)\right)\right) \]
          8. sqr-neg-revN/A

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

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

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

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

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

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

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\frac{{b}^{2} - \left(\mathsf{neg}\left(a\right)\right) \cdot \left(\mathsf{neg}\left(a\right)\right)}{b - a} \cdot b\right)\right)\right) \]
          15. lower-unsound-*.f32N/A

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\frac{{b}^{2} - \left(\mathsf{neg}\left(a\right)\right) \cdot \left(\mathsf{neg}\left(a\right)\right)}{b - a} \cdot b\right)\right)\right) \]
          16. lower-*.f32N/A

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\frac{{b}^{2} - \left(\mathsf{neg}\left(a\right)\right) \cdot \left(\mathsf{neg}\left(a\right)\right)}{b - a} \cdot b\right)\right)\right) \]
          17. sqr-neg-revN/A

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

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

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\frac{{b}^{2} - {a}^{2}}{b - a} \cdot b\right)\right)\right) \]
          20. lower-unsound--.f3229.3%

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\frac{\left( \left( {b}^{2} \right)_{\text{binary64}} - \left( {a}^{2} \right)_{\text{binary64}} \right)_{\text{binary32}}}{b - a} \cdot b\right)\right)\right) \]
          21. lower--.f32N/A

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

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

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

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

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

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

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

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

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

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\frac{\left(a + b\right) \cdot \left(b - a\right)}{b - a} \cdot b\right)\right)\right) \]
        3. Applied rewrites41.1%

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

        if 4.5000000000000002e287 < angle

        1. Initial program 54.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. Step-by-step derivation
          1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
        6. Applied rewrites54.2%

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

          \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(-1 \cdot \color{blue}{a}\right)\right)\right)\right) \]
        8. Step-by-step derivation
          1. lower-*.f6437.3%

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(-1 \cdot a\right)\right)\right)\right) \]
        9. Applied rewrites37.3%

          \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(-1 \cdot \color{blue}{a}\right)\right)\right)\right) \]
      9. Recombined 3 regimes into one program.
      10. Add Preprocessing

      Alternative 8: 63.9% accurate, 2.6× speedup?

      \[\begin{array}{l} t_0 := \left|a\right| + \left|b\right|\\ \mathsf{copysign}\left(1, angle\right) \cdot \begin{array}{l} \mathbf{if}\;\left|angle\right| \leq 35000:\\ \;\;\;\;\left(\left|b\right| - \left|a\right|\right) \cdot \left(\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot t\_0\right)\right)\right)\\ \mathbf{elif}\;\left|angle\right| \leq 450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864:\\ \;\;\;\;\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot \left(\left(\left(1 + \frac{\left|a\right|}{\left|b\right|}\right) \cdot \left|b\right|\right) \cdot \left|b\right|\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot \left(t\_0 \cdot \left(-1 \cdot \left|a\right|\right)\right)\right)\right)\\ \end{array} \end{array} \]
      (FPCore (a b angle)
        :precision binary64
        (let* ((t_0 (+ (fabs a) (fabs b))))
        (*
         (copysign 1 angle)
         (if (<= (fabs angle) 35000)
           (* (- (fabs b) (fabs a)) (* 1/90 (* (fabs angle) (* PI t_0))))
           (if (<=
                (fabs angle)
                450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864)
             (*
              1/90
              (*
               (fabs angle)
               (*
                PI
                (* (* (+ 1 (/ (fabs a) (fabs b))) (fabs b)) (fabs b)))))
             (* 1/90 (* (fabs angle) (* PI (* t_0 (* -1 (fabs a)))))))))))
      double code(double a, double b, double angle) {
      	double t_0 = fabs(a) + fabs(b);
      	double tmp;
      	if (fabs(angle) <= 35000.0) {
      		tmp = (fabs(b) - fabs(a)) * (0.011111111111111112 * (fabs(angle) * (((double) M_PI) * t_0)));
      	} else if (fabs(angle) <= 4.5e+287) {
      		tmp = 0.011111111111111112 * (fabs(angle) * (((double) M_PI) * (((1.0 + (fabs(a) / fabs(b))) * fabs(b)) * fabs(b))));
      	} else {
      		tmp = 0.011111111111111112 * (fabs(angle) * (((double) M_PI) * (t_0 * (-1.0 * fabs(a)))));
      	}
      	return copysign(1.0, angle) * tmp;
      }
      
      public static double code(double a, double b, double angle) {
      	double t_0 = Math.abs(a) + Math.abs(b);
      	double tmp;
      	if (Math.abs(angle) <= 35000.0) {
      		tmp = (Math.abs(b) - Math.abs(a)) * (0.011111111111111112 * (Math.abs(angle) * (Math.PI * t_0)));
      	} else if (Math.abs(angle) <= 4.5e+287) {
      		tmp = 0.011111111111111112 * (Math.abs(angle) * (Math.PI * (((1.0 + (Math.abs(a) / Math.abs(b))) * Math.abs(b)) * Math.abs(b))));
      	} else {
      		tmp = 0.011111111111111112 * (Math.abs(angle) * (Math.PI * (t_0 * (-1.0 * Math.abs(a)))));
      	}
      	return Math.copySign(1.0, angle) * tmp;
      }
      
      def code(a, b, angle):
      	t_0 = math.fabs(a) + math.fabs(b)
      	tmp = 0
      	if math.fabs(angle) <= 35000.0:
      		tmp = (math.fabs(b) - math.fabs(a)) * (0.011111111111111112 * (math.fabs(angle) * (math.pi * t_0)))
      	elif math.fabs(angle) <= 4.5e+287:
      		tmp = 0.011111111111111112 * (math.fabs(angle) * (math.pi * (((1.0 + (math.fabs(a) / math.fabs(b))) * math.fabs(b)) * math.fabs(b))))
      	else:
      		tmp = 0.011111111111111112 * (math.fabs(angle) * (math.pi * (t_0 * (-1.0 * math.fabs(a)))))
      	return math.copysign(1.0, angle) * tmp
      
      function code(a, b, angle)
      	t_0 = Float64(abs(a) + abs(b))
      	tmp = 0.0
      	if (abs(angle) <= 35000.0)
      		tmp = Float64(Float64(abs(b) - abs(a)) * Float64(0.011111111111111112 * Float64(abs(angle) * Float64(pi * t_0))));
      	elseif (abs(angle) <= 4.5e+287)
      		tmp = Float64(0.011111111111111112 * Float64(abs(angle) * Float64(pi * Float64(Float64(Float64(1.0 + Float64(abs(a) / abs(b))) * abs(b)) * abs(b)))));
      	else
      		tmp = Float64(0.011111111111111112 * Float64(abs(angle) * Float64(pi * Float64(t_0 * Float64(-1.0 * abs(a))))));
      	end
      	return Float64(copysign(1.0, angle) * tmp)
      end
      
      function tmp_2 = code(a, b, angle)
      	t_0 = abs(a) + abs(b);
      	tmp = 0.0;
      	if (abs(angle) <= 35000.0)
      		tmp = (abs(b) - abs(a)) * (0.011111111111111112 * (abs(angle) * (pi * t_0)));
      	elseif (abs(angle) <= 4.5e+287)
      		tmp = 0.011111111111111112 * (abs(angle) * (pi * (((1.0 + (abs(a) / abs(b))) * abs(b)) * abs(b))));
      	else
      		tmp = 0.011111111111111112 * (abs(angle) * (pi * (t_0 * (-1.0 * abs(a)))));
      	end
      	tmp_2 = (sign(angle) * abs(1.0)) * tmp;
      end
      
      code[a_, b_, angle_] := Block[{t$95$0 = N[(N[Abs[a], $MachinePrecision] + N[Abs[b], $MachinePrecision]), $MachinePrecision]}, N[(N[With[{TMP1 = Abs[1], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision] * If[LessEqual[N[Abs[angle], $MachinePrecision], 35000], N[(N[(N[Abs[b], $MachinePrecision] - N[Abs[a], $MachinePrecision]), $MachinePrecision] * N[(1/90 * N[(N[Abs[angle], $MachinePrecision] * N[(Pi * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Abs[angle], $MachinePrecision], 450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864], N[(1/90 * N[(N[Abs[angle], $MachinePrecision] * N[(Pi * N[(N[(N[(1 + N[(N[Abs[a], $MachinePrecision] / N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Abs[b], $MachinePrecision]), $MachinePrecision] * N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1/90 * N[(N[Abs[angle], $MachinePrecision] * N[(Pi * N[(t$95$0 * N[(-1 * N[Abs[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
      
      \begin{array}{l}
      t_0 := \left|a\right| + \left|b\right|\\
      \mathsf{copysign}\left(1, angle\right) \cdot \begin{array}{l}
      \mathbf{if}\;\left|angle\right| \leq 35000:\\
      \;\;\;\;\left(\left|b\right| - \left|a\right|\right) \cdot \left(\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot t\_0\right)\right)\right)\\
      
      \mathbf{elif}\;\left|angle\right| \leq 450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864:\\
      \;\;\;\;\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot \left(\left(\left(1 + \frac{\left|a\right|}{\left|b\right|}\right) \cdot \left|b\right|\right) \cdot \left|b\right|\right)\right)\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot \left(t\_0 \cdot \left(-1 \cdot \left|a\right|\right)\right)\right)\right)\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 3 regimes
      2. if angle < 35000

        1. Initial program 54.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. Step-by-step derivation
          1. lift-*.f64N/A

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

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

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

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

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

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

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

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

          \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
        4. Step-by-step derivation
          1. lift-134-z0z1z2z3z4N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        if 35000 < angle < 4.5000000000000002e287

        1. Initial program 54.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. Step-by-step derivation
          1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
        6. Applied rewrites54.2%

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

          \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \]
        8. Step-by-step derivation
          1. Applied rewrites37.2%

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

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

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

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

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

              \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(\left(1 + \frac{a}{b}\right) \cdot b\right) \cdot b\right)\right)\right) \]
            6. lower-unsound-/.f6440.2%

              \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(\left(1 + \frac{a}{b}\right) \cdot b\right) \cdot b\right)\right)\right) \]
          3. Applied rewrites40.2%

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(\left(1 + \frac{a}{b}\right) \cdot b\right) \cdot b\right)\right)\right) \]

          if 4.5000000000000002e287 < angle

          1. Initial program 54.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. Step-by-step derivation
            1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
          6. Applied rewrites54.2%

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

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(-1 \cdot \color{blue}{a}\right)\right)\right)\right) \]
          8. Step-by-step derivation
            1. lower-*.f6437.3%

              \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(-1 \cdot a\right)\right)\right)\right) \]
          9. Applied rewrites37.3%

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(-1 \cdot \color{blue}{a}\right)\right)\right)\right) \]
        9. Recombined 3 regimes into one program.
        10. Add Preprocessing

        Alternative 9: 62.6% accurate, 2.8× speedup?

        \[\begin{array}{l} t_0 := \left|a\right| + \left|b\right|\\ \mathsf{copysign}\left(1, angle\right) \cdot \begin{array}{l} \mathbf{if}\;\left|angle\right| \leq 44999999999999997619501552954440605329731224537770508792680074270517912479690686752281910390554624:\\ \;\;\;\;\left(\left|b\right| - \left|a\right|\right) \cdot \left(\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot t\_0\right)\right)\right)\\ \mathbf{elif}\;\left|angle\right| \leq 450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864:\\ \;\;\;\;\frac{1}{90} \cdot \left(\left(\left(\left|angle\right| \cdot \pi\right) \cdot t\_0\right) \cdot \left|b\right|\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot \left(t\_0 \cdot \left(-1 \cdot \left|a\right|\right)\right)\right)\right)\\ \end{array} \end{array} \]
        (FPCore (a b angle)
          :precision binary64
          (let* ((t_0 (+ (fabs a) (fabs b))))
          (*
           (copysign 1 angle)
           (if (<=
                (fabs angle)
                44999999999999997619501552954440605329731224537770508792680074270517912479690686752281910390554624)
             (* (- (fabs b) (fabs a)) (* 1/90 (* (fabs angle) (* PI t_0))))
             (if (<=
                  (fabs angle)
                  450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864)
               (* 1/90 (* (* (* (fabs angle) PI) t_0) (fabs b)))
               (* 1/90 (* (fabs angle) (* PI (* t_0 (* -1 (fabs a)))))))))))
        double code(double a, double b, double angle) {
        	double t_0 = fabs(a) + fabs(b);
        	double tmp;
        	if (fabs(angle) <= 4.5e+97) {
        		tmp = (fabs(b) - fabs(a)) * (0.011111111111111112 * (fabs(angle) * (((double) M_PI) * t_0)));
        	} else if (fabs(angle) <= 4.5e+287) {
        		tmp = 0.011111111111111112 * (((fabs(angle) * ((double) M_PI)) * t_0) * fabs(b));
        	} else {
        		tmp = 0.011111111111111112 * (fabs(angle) * (((double) M_PI) * (t_0 * (-1.0 * fabs(a)))));
        	}
        	return copysign(1.0, angle) * tmp;
        }
        
        public static double code(double a, double b, double angle) {
        	double t_0 = Math.abs(a) + Math.abs(b);
        	double tmp;
        	if (Math.abs(angle) <= 4.5e+97) {
        		tmp = (Math.abs(b) - Math.abs(a)) * (0.011111111111111112 * (Math.abs(angle) * (Math.PI * t_0)));
        	} else if (Math.abs(angle) <= 4.5e+287) {
        		tmp = 0.011111111111111112 * (((Math.abs(angle) * Math.PI) * t_0) * Math.abs(b));
        	} else {
        		tmp = 0.011111111111111112 * (Math.abs(angle) * (Math.PI * (t_0 * (-1.0 * Math.abs(a)))));
        	}
        	return Math.copySign(1.0, angle) * tmp;
        }
        
        def code(a, b, angle):
        	t_0 = math.fabs(a) + math.fabs(b)
        	tmp = 0
        	if math.fabs(angle) <= 4.5e+97:
        		tmp = (math.fabs(b) - math.fabs(a)) * (0.011111111111111112 * (math.fabs(angle) * (math.pi * t_0)))
        	elif math.fabs(angle) <= 4.5e+287:
        		tmp = 0.011111111111111112 * (((math.fabs(angle) * math.pi) * t_0) * math.fabs(b))
        	else:
        		tmp = 0.011111111111111112 * (math.fabs(angle) * (math.pi * (t_0 * (-1.0 * math.fabs(a)))))
        	return math.copysign(1.0, angle) * tmp
        
        function code(a, b, angle)
        	t_0 = Float64(abs(a) + abs(b))
        	tmp = 0.0
        	if (abs(angle) <= 4.5e+97)
        		tmp = Float64(Float64(abs(b) - abs(a)) * Float64(0.011111111111111112 * Float64(abs(angle) * Float64(pi * t_0))));
        	elseif (abs(angle) <= 4.5e+287)
        		tmp = Float64(0.011111111111111112 * Float64(Float64(Float64(abs(angle) * pi) * t_0) * abs(b)));
        	else
        		tmp = Float64(0.011111111111111112 * Float64(abs(angle) * Float64(pi * Float64(t_0 * Float64(-1.0 * abs(a))))));
        	end
        	return Float64(copysign(1.0, angle) * tmp)
        end
        
        function tmp_2 = code(a, b, angle)
        	t_0 = abs(a) + abs(b);
        	tmp = 0.0;
        	if (abs(angle) <= 4.5e+97)
        		tmp = (abs(b) - abs(a)) * (0.011111111111111112 * (abs(angle) * (pi * t_0)));
        	elseif (abs(angle) <= 4.5e+287)
        		tmp = 0.011111111111111112 * (((abs(angle) * pi) * t_0) * abs(b));
        	else
        		tmp = 0.011111111111111112 * (abs(angle) * (pi * (t_0 * (-1.0 * abs(a)))));
        	end
        	tmp_2 = (sign(angle) * abs(1.0)) * tmp;
        end
        
        code[a_, b_, angle_] := Block[{t$95$0 = N[(N[Abs[a], $MachinePrecision] + N[Abs[b], $MachinePrecision]), $MachinePrecision]}, N[(N[With[{TMP1 = Abs[1], TMP2 = Sign[angle]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision] * If[LessEqual[N[Abs[angle], $MachinePrecision], 44999999999999997619501552954440605329731224537770508792680074270517912479690686752281910390554624], N[(N[(N[Abs[b], $MachinePrecision] - N[Abs[a], $MachinePrecision]), $MachinePrecision] * N[(1/90 * N[(N[Abs[angle], $MachinePrecision] * N[(Pi * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Abs[angle], $MachinePrecision], 450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864], N[(1/90 * N[(N[(N[(N[Abs[angle], $MachinePrecision] * Pi), $MachinePrecision] * t$95$0), $MachinePrecision] * N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1/90 * N[(N[Abs[angle], $MachinePrecision] * N[(Pi * N[(t$95$0 * N[(-1 * N[Abs[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
        
        \begin{array}{l}
        t_0 := \left|a\right| + \left|b\right|\\
        \mathsf{copysign}\left(1, angle\right) \cdot \begin{array}{l}
        \mathbf{if}\;\left|angle\right| \leq 44999999999999997619501552954440605329731224537770508792680074270517912479690686752281910390554624:\\
        \;\;\;\;\left(\left|b\right| - \left|a\right|\right) \cdot \left(\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot t\_0\right)\right)\right)\\
        
        \mathbf{elif}\;\left|angle\right| \leq 450000000000000016958053089881796353851548744843094964733530545522697246262216880657861102563284036476374305723951859506724049072546807429311473890536442725603127680570225934753847055352537767547108754807894734836540518200341427621717685623513184497194228104494423834156650142359422500864:\\
        \;\;\;\;\frac{1}{90} \cdot \left(\left(\left(\left|angle\right| \cdot \pi\right) \cdot t\_0\right) \cdot \left|b\right|\right)\\
        
        \mathbf{else}:\\
        \;\;\;\;\frac{1}{90} \cdot \left(\left|angle\right| \cdot \left(\pi \cdot \left(t\_0 \cdot \left(-1 \cdot \left|a\right|\right)\right)\right)\right)\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if angle < 4.4999999999999998e97

          1. Initial program 54.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. Step-by-step derivation
            1. lift-*.f64N/A

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

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

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

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

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

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

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

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

            \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
          4. Step-by-step derivation
            1. lift-134-z0z1z2z3z4N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          if 4.4999999999999998e97 < angle < 4.5000000000000002e287

          1. Initial program 54.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. Step-by-step derivation
            1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
          6. Applied rewrites54.2%

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

            \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \]
          8. Step-by-step derivation
            1. Applied rewrites37.2%

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \frac{1}{90} \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot b\right) \]
            3. Applied rewrites41.2%

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

            if 4.5000000000000002e287 < angle

            1. Initial program 54.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. Step-by-step derivation
              1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
            6. Applied rewrites54.2%

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

              \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(-1 \cdot \color{blue}{a}\right)\right)\right)\right) \]
            8. Step-by-step derivation
              1. lower-*.f6437.3%

                \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(-1 \cdot a\right)\right)\right)\right) \]
            9. Applied rewrites37.3%

              \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(-1 \cdot \color{blue}{a}\right)\right)\right)\right) \]
          9. Recombined 3 regimes into one program.
          10. Add Preprocessing

          Alternative 10: 62.6% accurate, 14.6× speedup?

          \[\left(\left|b\right| - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(a + \left|b\right|\right)\right)\right)\right) \]
          (FPCore (a b angle)
            :precision binary64
            (* (- (fabs b) a) (* 1/90 (* angle (* PI (+ a (fabs b)))))))
          double code(double a, double b, double angle) {
          	return (fabs(b) - a) * (0.011111111111111112 * (angle * (((double) M_PI) * (a + fabs(b)))));
          }
          
          public static double code(double a, double b, double angle) {
          	return (Math.abs(b) - a) * (0.011111111111111112 * (angle * (Math.PI * (a + Math.abs(b)))));
          }
          
          def code(a, b, angle):
          	return (math.fabs(b) - a) * (0.011111111111111112 * (angle * (math.pi * (a + math.fabs(b)))))
          
          function code(a, b, angle)
          	return Float64(Float64(abs(b) - a) * Float64(0.011111111111111112 * Float64(angle * Float64(pi * Float64(a + abs(b))))))
          end
          
          function tmp = code(a, b, angle)
          	tmp = (abs(b) - a) * (0.011111111111111112 * (angle * (pi * (a + abs(b)))));
          end
          
          code[a_, b_, angle_] := N[(N[(N[Abs[b], $MachinePrecision] - a), $MachinePrecision] * N[(1/90 * N[(angle * N[(Pi * N[(a + N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
          
          \left(\left|b\right| - a\right) \cdot \left(\frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(a + \left|b\right|\right)\right)\right)\right)
          
          Derivation
          1. Initial program 54.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. Step-by-step derivation
            1. lift-*.f64N/A

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

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

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

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

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

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

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

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

            \[\leadsto \color{blue}{\mathsf{134\_z0z1z2z3z4}\left(\sin \left(\left(angle \cdot \pi\right) \cdot \frac{1}{90}\right), b, b, a, a\right)} \]
          4. Step-by-step derivation
            1. lift-134-z0z1z2z3z4N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          Alternative 11: 62.5% accurate, 14.6× speedup?

          \[\frac{1}{90} \cdot \left(\left(\pi \cdot \left(a + \left|b\right|\right)\right) \cdot \left(\left(\left|b\right| - a\right) \cdot angle\right)\right) \]
          (FPCore (a b angle)
            :precision binary64
            (* 1/90 (* (* PI (+ a (fabs b))) (* (- (fabs b) a) angle))))
          double code(double a, double b, double angle) {
          	return 0.011111111111111112 * ((((double) M_PI) * (a + fabs(b))) * ((fabs(b) - a) * angle));
          }
          
          public static double code(double a, double b, double angle) {
          	return 0.011111111111111112 * ((Math.PI * (a + Math.abs(b))) * ((Math.abs(b) - a) * angle));
          }
          
          def code(a, b, angle):
          	return 0.011111111111111112 * ((math.pi * (a + math.fabs(b))) * ((math.fabs(b) - a) * angle))
          
          function code(a, b, angle)
          	return Float64(0.011111111111111112 * Float64(Float64(pi * Float64(a + abs(b))) * Float64(Float64(abs(b) - a) * angle)))
          end
          
          function tmp = code(a, b, angle)
          	tmp = 0.011111111111111112 * ((pi * (a + abs(b))) * ((abs(b) - a) * angle));
          end
          
          code[a_, b_, angle_] := N[(1/90 * N[(N[(Pi * N[(a + N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(N[Abs[b], $MachinePrecision] - a), $MachinePrecision] * angle), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
          
          \frac{1}{90} \cdot \left(\left(\pi \cdot \left(a + \left|b\right|\right)\right) \cdot \left(\left(\left|b\right| - a\right) \cdot angle\right)\right)
          
          Derivation
          1. Initial program 54.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. Step-by-step derivation
            1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
          6. Applied rewrites54.2%

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

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

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

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

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

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

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

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

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

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

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

          Alternative 12: 56.6% accurate, 10.5× speedup?

          \[\begin{array}{l} t_0 := \left|a\right| + \left|b\right|\\ \mathbf{if}\;\left|b\right| \leq 920000000000000012194172518790057045799306659821299225420975556855664091087607883247395862037184893378553456937101100189413504230300998018716177162909772320919725008294726605769539584:\\ \;\;\;\;\frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(t\_0 \cdot \left(\left|b\right| - \left|a\right|\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(angle \cdot \frac{1}{90}\right) \cdot \left(\pi \cdot t\_0\right)\right) \cdot \left|b\right|\\ \end{array} \]
          (FPCore (a b angle)
            :precision binary64
            (let* ((t_0 (+ (fabs a) (fabs b))))
            (if (<=
                 (fabs b)
                 920000000000000012194172518790057045799306659821299225420975556855664091087607883247395862037184893378553456937101100189413504230300998018716177162909772320919725008294726605769539584)
              (* 1/90 (* angle (* PI (* t_0 (- (fabs b) (fabs a))))))
              (* (* (* angle 1/90) (* PI t_0)) (fabs b)))))
          double code(double a, double b, double angle) {
          	double t_0 = fabs(a) + fabs(b);
          	double tmp;
          	if (fabs(b) <= 9.2e+182) {
          		tmp = 0.011111111111111112 * (angle * (((double) M_PI) * (t_0 * (fabs(b) - fabs(a)))));
          	} else {
          		tmp = ((angle * 0.011111111111111112) * (((double) M_PI) * t_0)) * fabs(b);
          	}
          	return tmp;
          }
          
          public static double code(double a, double b, double angle) {
          	double t_0 = Math.abs(a) + Math.abs(b);
          	double tmp;
          	if (Math.abs(b) <= 9.2e+182) {
          		tmp = 0.011111111111111112 * (angle * (Math.PI * (t_0 * (Math.abs(b) - Math.abs(a)))));
          	} else {
          		tmp = ((angle * 0.011111111111111112) * (Math.PI * t_0)) * Math.abs(b);
          	}
          	return tmp;
          }
          
          def code(a, b, angle):
          	t_0 = math.fabs(a) + math.fabs(b)
          	tmp = 0
          	if math.fabs(b) <= 9.2e+182:
          		tmp = 0.011111111111111112 * (angle * (math.pi * (t_0 * (math.fabs(b) - math.fabs(a)))))
          	else:
          		tmp = ((angle * 0.011111111111111112) * (math.pi * t_0)) * math.fabs(b)
          	return tmp
          
          function code(a, b, angle)
          	t_0 = Float64(abs(a) + abs(b))
          	tmp = 0.0
          	if (abs(b) <= 9.2e+182)
          		tmp = Float64(0.011111111111111112 * Float64(angle * Float64(pi * Float64(t_0 * Float64(abs(b) - abs(a))))));
          	else
          		tmp = Float64(Float64(Float64(angle * 0.011111111111111112) * Float64(pi * t_0)) * abs(b));
          	end
          	return tmp
          end
          
          function tmp_2 = code(a, b, angle)
          	t_0 = abs(a) + abs(b);
          	tmp = 0.0;
          	if (abs(b) <= 9.2e+182)
          		tmp = 0.011111111111111112 * (angle * (pi * (t_0 * (abs(b) - abs(a)))));
          	else
          		tmp = ((angle * 0.011111111111111112) * (pi * t_0)) * abs(b);
          	end
          	tmp_2 = tmp;
          end
          
          code[a_, b_, angle_] := Block[{t$95$0 = N[(N[Abs[a], $MachinePrecision] + N[Abs[b], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Abs[b], $MachinePrecision], 920000000000000012194172518790057045799306659821299225420975556855664091087607883247395862037184893378553456937101100189413504230300998018716177162909772320919725008294726605769539584], N[(1/90 * N[(angle * N[(Pi * N[(t$95$0 * N[(N[Abs[b], $MachinePrecision] - N[Abs[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(angle * 1/90), $MachinePrecision] * N[(Pi * t$95$0), $MachinePrecision]), $MachinePrecision] * N[Abs[b], $MachinePrecision]), $MachinePrecision]]]
          
          \begin{array}{l}
          t_0 := \left|a\right| + \left|b\right|\\
          \mathbf{if}\;\left|b\right| \leq 920000000000000012194172518790057045799306659821299225420975556855664091087607883247395862037184893378553456937101100189413504230300998018716177162909772320919725008294726605769539584:\\
          \;\;\;\;\frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(t\_0 \cdot \left(\left|b\right| - \left|a\right|\right)\right)\right)\right)\\
          
          \mathbf{else}:\\
          \;\;\;\;\left(\left(angle \cdot \frac{1}{90}\right) \cdot \left(\pi \cdot t\_0\right)\right) \cdot \left|b\right|\\
          
          
          \end{array}
          
          Derivation
          1. Split input into 2 regimes
          2. if b < 9.2000000000000001e182

            1. Initial program 54.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. Step-by-step derivation
              1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
            6. Applied rewrites54.2%

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

            if 9.2000000000000001e182 < b

            1. Initial program 54.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. Step-by-step derivation
              1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
            6. Applied rewrites54.2%

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

              \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \]
            8. Step-by-step derivation
              1. Applied rewrites37.2%

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

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \left(\left(angle \cdot \frac{1}{90}\right) \cdot \left(\pi \cdot \left(a + b\right)\right)\right) \cdot b \]
              3. Applied rewrites41.3%

                \[\leadsto \left(\left(angle \cdot \frac{1}{90}\right) \cdot \left(\pi \cdot \left(a + b\right)\right)\right) \cdot \color{blue}{b} \]
            9. Recombined 2 regimes into one program.
            10. Add Preprocessing

            Alternative 13: 40.7% accurate, 15.1× speedup?

            \[\left(\left(angle \cdot \left(\pi \cdot \left(\left|a\right| + \left|b\right|\right)\right)\right) \cdot \left|b\right|\right) \cdot \frac{1}{90} \]
            (FPCore (a b angle)
              :precision binary64
              (* (* (* angle (* PI (+ (fabs a) (fabs b)))) (fabs b)) 1/90))
            double code(double a, double b, double angle) {
            	return ((angle * (((double) M_PI) * (fabs(a) + fabs(b)))) * fabs(b)) * 0.011111111111111112;
            }
            
            public static double code(double a, double b, double angle) {
            	return ((angle * (Math.PI * (Math.abs(a) + Math.abs(b)))) * Math.abs(b)) * 0.011111111111111112;
            }
            
            def code(a, b, angle):
            	return ((angle * (math.pi * (math.fabs(a) + math.fabs(b)))) * math.fabs(b)) * 0.011111111111111112
            
            function code(a, b, angle)
            	return Float64(Float64(Float64(angle * Float64(pi * Float64(abs(a) + abs(b)))) * abs(b)) * 0.011111111111111112)
            end
            
            function tmp = code(a, b, angle)
            	tmp = ((angle * (pi * (abs(a) + abs(b)))) * abs(b)) * 0.011111111111111112;
            end
            
            code[a_, b_, angle_] := N[(N[(N[(angle * N[(Pi * N[(N[Abs[a], $MachinePrecision] + N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Abs[b], $MachinePrecision]), $MachinePrecision] * 1/90), $MachinePrecision]
            
            \left(\left(angle \cdot \left(\pi \cdot \left(\left|a\right| + \left|b\right|\right)\right)\right) \cdot \left|b\right|\right) \cdot \frac{1}{90}
            
            Derivation
            1. Initial program 54.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. Step-by-step derivation
              1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
            6. Applied rewrites54.2%

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

              \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \]
            8. Step-by-step derivation
              1. Applied rewrites37.2%

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

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

                  \[\leadsto \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \cdot \color{blue}{\frac{1}{90}} \]
                3. lower-*.f6437.2%

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

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

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

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

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

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

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

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

                  \[\leadsto \left(\left(angle \cdot \left(\pi \cdot \left(a + b\right)\right)\right) \cdot b\right) \cdot \frac{1}{90} \]
              3. Applied rewrites41.2%

                \[\leadsto \left(\left(angle \cdot \left(\pi \cdot \left(a + b\right)\right)\right) \cdot b\right) \cdot \color{blue}{\frac{1}{90}} \]
              4. Add Preprocessing

              Alternative 14: 40.7% accurate, 15.1× speedup?

              \[\frac{1}{90} \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(\left|a\right| + \left|b\right|\right)\right) \cdot \left|b\right|\right) \]
              (FPCore (a b angle)
                :precision binary64
                (* 1/90 (* (* (* angle PI) (+ (fabs a) (fabs b))) (fabs b))))
              double code(double a, double b, double angle) {
              	return 0.011111111111111112 * (((angle * ((double) M_PI)) * (fabs(a) + fabs(b))) * fabs(b));
              }
              
              public static double code(double a, double b, double angle) {
              	return 0.011111111111111112 * (((angle * Math.PI) * (Math.abs(a) + Math.abs(b))) * Math.abs(b));
              }
              
              def code(a, b, angle):
              	return 0.011111111111111112 * (((angle * math.pi) * (math.fabs(a) + math.fabs(b))) * math.fabs(b))
              
              function code(a, b, angle)
              	return Float64(0.011111111111111112 * Float64(Float64(Float64(angle * pi) * Float64(abs(a) + abs(b))) * abs(b)))
              end
              
              function tmp = code(a, b, angle)
              	tmp = 0.011111111111111112 * (((angle * pi) * (abs(a) + abs(b))) * abs(b));
              end
              
              code[a_, b_, angle_] := N[(1/90 * N[(N[(N[(angle * Pi), $MachinePrecision] * N[(N[Abs[a], $MachinePrecision] + N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
              
              \frac{1}{90} \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(\left|a\right| + \left|b\right|\right)\right) \cdot \left|b\right|\right)
              
              Derivation
              1. Initial program 54.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. Step-by-step derivation
                1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
              6. Applied rewrites54.2%

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

                \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \]
              8. Step-by-step derivation
                1. Applied rewrites37.2%

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \frac{1}{90} \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot b\right) \]
                3. Applied rewrites41.2%

                  \[\leadsto \frac{1}{90} \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(a + b\right)\right) \cdot \color{blue}{b}\right) \]
                4. Add Preprocessing

                Alternative 15: 40.2% accurate, 16.2× speedup?

                \[\frac{1}{90} \cdot \left(\left(\pi \cdot \left(a + \left|b\right|\right)\right) \cdot \left(\left|b\right| \cdot angle\right)\right) \]
                (FPCore (a b angle)
                  :precision binary64
                  (* 1/90 (* (* PI (+ a (fabs b))) (* (fabs b) angle))))
                double code(double a, double b, double angle) {
                	return 0.011111111111111112 * ((((double) M_PI) * (a + fabs(b))) * (fabs(b) * angle));
                }
                
                public static double code(double a, double b, double angle) {
                	return 0.011111111111111112 * ((Math.PI * (a + Math.abs(b))) * (Math.abs(b) * angle));
                }
                
                def code(a, b, angle):
                	return 0.011111111111111112 * ((math.pi * (a + math.fabs(b))) * (math.fabs(b) * angle))
                
                function code(a, b, angle)
                	return Float64(0.011111111111111112 * Float64(Float64(pi * Float64(a + abs(b))) * Float64(abs(b) * angle)))
                end
                
                function tmp = code(a, b, angle)
                	tmp = 0.011111111111111112 * ((pi * (a + abs(b))) * (abs(b) * angle));
                end
                
                code[a_, b_, angle_] := N[(1/90 * N[(N[(Pi * N[(a + N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[Abs[b], $MachinePrecision] * angle), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                
                \frac{1}{90} \cdot \left(\left(\pi \cdot \left(a + \left|b\right|\right)\right) \cdot \left(\left|b\right| \cdot angle\right)\right)
                
                Derivation
                1. Initial program 54.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. Step-by-step derivation
                  1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
                6. Applied rewrites54.2%

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

                  \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \]
                8. Step-by-step derivation
                  1. Applied rewrites37.2%

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

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

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

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

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

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

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

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

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

                      \[\leadsto \frac{1}{90} \cdot \left(\left(\pi \cdot \left(a + b\right)\right) \cdot \left(b \cdot \color{blue}{angle}\right)\right) \]
                  3. Applied rewrites40.0%

                    \[\leadsto \frac{1}{90} \cdot \left(\left(\pi \cdot \left(a + b\right)\right) \cdot \color{blue}{\left(b \cdot angle\right)}\right) \]
                  4. Add Preprocessing

                  Alternative 16: 37.4% accurate, 16.2× speedup?

                  \[\frac{1}{90} \cdot \left(\left(angle \cdot \left(\left|b\right| \cdot \left(a + \left|b\right|\right)\right)\right) \cdot \pi\right) \]
                  (FPCore (a b angle)
                    :precision binary64
                    (* 1/90 (* (* angle (* (fabs b) (+ a (fabs b)))) PI)))
                  double code(double a, double b, double angle) {
                  	return 0.011111111111111112 * ((angle * (fabs(b) * (a + fabs(b)))) * ((double) M_PI));
                  }
                  
                  public static double code(double a, double b, double angle) {
                  	return 0.011111111111111112 * ((angle * (Math.abs(b) * (a + Math.abs(b)))) * Math.PI);
                  }
                  
                  def code(a, b, angle):
                  	return 0.011111111111111112 * ((angle * (math.fabs(b) * (a + math.fabs(b)))) * math.pi)
                  
                  function code(a, b, angle)
                  	return Float64(0.011111111111111112 * Float64(Float64(angle * Float64(abs(b) * Float64(a + abs(b)))) * pi))
                  end
                  
                  function tmp = code(a, b, angle)
                  	tmp = 0.011111111111111112 * ((angle * (abs(b) * (a + abs(b)))) * pi);
                  end
                  
                  code[a_, b_, angle_] := N[(1/90 * N[(N[(angle * N[(N[Abs[b], $MachinePrecision] * N[(a + N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * Pi), $MachinePrecision]), $MachinePrecision]
                  
                  \frac{1}{90} \cdot \left(\left(angle \cdot \left(\left|b\right| \cdot \left(a + \left|b\right|\right)\right)\right) \cdot \pi\right)
                  
                  Derivation
                  1. Initial program 54.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. Step-by-step derivation
                    1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
                  6. Applied rewrites54.2%

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

                    \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \]
                  8. Step-by-step derivation
                    1. Applied rewrites37.2%

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

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

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

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

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

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

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

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

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

                        \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(b \cdot \left(a + b\right)\right)\right) \cdot \pi\right) \]
                    3. Applied rewrites37.2%

                      \[\leadsto \frac{1}{90} \cdot \left(\left(angle \cdot \left(b \cdot \left(a + b\right)\right)\right) \cdot \color{blue}{\pi}\right) \]
                    4. Add Preprocessing

                    Alternative 17: 37.4% accurate, 16.2× speedup?

                    \[\frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + \left|b\right|\right) \cdot \left|b\right|\right)\right)\right) \]
                    (FPCore (a b angle)
                      :precision binary64
                      (* 1/90 (* angle (* PI (* (+ a (fabs b)) (fabs b))))))
                    double code(double a, double b, double angle) {
                    	return 0.011111111111111112 * (angle * (((double) M_PI) * ((a + fabs(b)) * fabs(b))));
                    }
                    
                    public static double code(double a, double b, double angle) {
                    	return 0.011111111111111112 * (angle * (Math.PI * ((a + Math.abs(b)) * Math.abs(b))));
                    }
                    
                    def code(a, b, angle):
                    	return 0.011111111111111112 * (angle * (math.pi * ((a + math.fabs(b)) * math.fabs(b))))
                    
                    function code(a, b, angle)
                    	return Float64(0.011111111111111112 * Float64(angle * Float64(pi * Float64(Float64(a + abs(b)) * abs(b)))))
                    end
                    
                    function tmp = code(a, b, angle)
                    	tmp = 0.011111111111111112 * (angle * (pi * ((a + abs(b)) * abs(b))));
                    end
                    
                    code[a_, b_, angle_] := N[(1/90 * N[(angle * N[(Pi * N[(N[(a + N[Abs[b], $MachinePrecision]), $MachinePrecision] * N[Abs[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                    
                    \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + \left|b\right|\right) \cdot \left|b\right|\right)\right)\right)
                    
                    Derivation
                    1. Initial program 54.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. Step-by-step derivation
                      1. lift-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot \left(b - \color{blue}{a}\right)\right)\right)\right) \]
                    6. Applied rewrites54.2%

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

                      \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \]
                    8. Step-by-step derivation
                      1. Applied rewrites37.2%

                        \[\leadsto \frac{1}{90} \cdot \left(angle \cdot \left(\pi \cdot \left(\left(a + b\right) \cdot b\right)\right)\right) \]
                      2. Add Preprocessing

                      Reproduce

                      ?
                      herbie shell --seed 2025271 -o generate:evaluate
                      (FPCore (a b angle)
                        :name "ab-angle->ABCF B"
                        :precision binary64
                        (* (* (* 2 (- (pow b 2) (pow a 2))) (sin (* PI (/ angle 180)))) (cos (* PI (/ angle 180)))))