ab-angle->ABCF B

Percentage Accurate: 54.1% → 65.8%
Time: 13.1s
Alternatives: 20
Speedup: 10.3×

Specification

?
\[\begin{array}{l} \\ \begin{array}{l} t_0 := \mathsf{PI}\left(\right) \cdot \frac{angle}{180}\\ \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin t\_0\right) \cdot \cos t\_0 \end{array} \end{array} \]
(FPCore (a b angle)
 :precision binary64
 (let* ((t_0 (* (PI) (/ angle 180.0))))
   (* (* (* 2.0 (- (pow b 2.0) (pow a 2.0))) (sin t_0)) (cos t_0))))
\begin{array}{l}

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 20 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} \\ \begin{array}{l} t_0 := \mathsf{PI}\left(\right) \cdot \frac{angle}{180}\\ \left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin t\_0\right) \cdot \cos t\_0 \end{array} \end{array} \]
(FPCore (a b angle)
 :precision binary64
 (let* ((t_0 (* (PI) (/ angle 180.0))))
   (* (* (* 2.0 (- (pow b 2.0) (pow a 2.0))) (sin t_0)) (cos t_0))))
\begin{array}{l}

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

Alternative 1: 65.8% accurate, 2.2× speedup?

\[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \sqrt{\mathsf{PI}\left(\right)}\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+52}:\\ \;\;\;\;\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\\ \mathbf{elif}\;\frac{angle\_m}{180} \leq 10^{+162}:\\ \;\;\;\;\frac{\left(\sin \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right)}{-a\_m}\\ \mathbf{elif}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+217}:\\ \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m - a\_m\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m + a\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\sin \left(\left(\left(t\_0 \cdot t\_0\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\\ \end{array} \end{array} \end{array} \]
b_m = (fabs.f64 b)
a_m = (fabs.f64 a)
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a_m b_m angle_m)
 :precision binary64
 (let* ((t_0 (sqrt (PI))))
   (*
    angle_s
    (if (<= (/ angle_m 180.0) 1e+52)
      (*
       (* (sin (* (* (PI) angle_m) 0.011111111111111112)) (- b_m a_m))
       (+ b_m a_m))
      (if (<= (/ angle_m 180.0) 1e+162)
        (/
         (*
          (* (sin (* (* 0.011111111111111112 (PI)) angle_m)) (- b_m a_m))
          (* (+ b_m a_m) (- b_m a_m)))
         (- a_m))
        (if (<= (/ angle_m 180.0) 5e+217)
          (*
           (* (* (* (PI) (- b_m a_m)) angle_m) 0.011111111111111112)
           (+ b_m a_m))
          (*
           (*
            (sin (* (* (* t_0 t_0) angle_m) 0.011111111111111112))
            (- b_m a_m))
           (+ b_m a_m))))))))
\begin{array}{l}
b_m = \left|b\right|
\\
a_m = \left|a\right|
\\
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

\\
\begin{array}{l}
t_0 := \sqrt{\mathsf{PI}\left(\right)}\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+52}:\\
\;\;\;\;\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\\

\mathbf{elif}\;\frac{angle\_m}{180} \leq 10^{+162}:\\
\;\;\;\;\frac{\left(\sin \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right)}{-a\_m}\\

\mathbf{elif}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+217}:\\
\;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m - a\_m\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m + a\_m\right)\\

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


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

    1. Initial program 55.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 9.9999999999999999e51 < (/.f64 angle #s(literal 180 binary64)) < 9.9999999999999994e161

    1. Initial program 33.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{\left(\left(b - a\right) \cdot \left(b + a\right)\right) \cdot \left(\sin \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \left(b - a\right)\right)}{\color{blue}{-a}} \]
    9. Applied rewrites29.2%

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

    if 9.9999999999999994e161 < (/.f64 angle #s(literal 180 binary64)) < 5.00000000000000041e217

    1. Initial program 20.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \color{blue}{\mathsf{PI}\left(\right)}\right) \cdot angle\right) \cdot 0.011111111111111112\right) \]
    7. Applied rewrites37.3%

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

    if 5.00000000000000041e217 < (/.f64 angle #s(literal 180 binary64))

    1. Initial program 40.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 10^{+52}:\\ \;\;\;\;\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+162}:\\ \;\;\;\;\frac{\left(\sin \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \left(b - a\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)}{-a}\\ \mathbf{elif}\;\frac{angle}{180} \leq 5 \cdot 10^{+217}:\\ \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b - a\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b + a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\sin \left(\left(\left(\sqrt{\mathsf{PI}\left(\right)} \cdot \sqrt{\mathsf{PI}\left(\right)}\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 67.4% accurate, 0.8× speedup?

\[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := {\left(\sqrt[3]{\sqrt{\mathsf{PI}\left(\right)}}\right)}^{3}\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 6 \cdot 10^{+132}:\\ \;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\_m\right)\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \mathsf{fma}\left(\sqrt{a\_m}, \sqrt{a\_m}, b\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\sin \left(\left(\left(t\_0 \cdot t\_0\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\\ \end{array} \end{array} \end{array} \]
b_m = (fabs.f64 b)
a_m = (fabs.f64 a)
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a_m b_m angle_m)
 :precision binary64
 (let* ((t_0 (pow (cbrt (sqrt (PI))) 3.0)))
   (*
    angle_s
    (if (<= (/ angle_m 180.0) 6e+132)
      (*
       (*
        (sin
         (* 0.011111111111111112 (* (cbrt (* (* (PI) (PI)) (PI))) angle_m)))
        (- b_m a_m))
       (fma (sqrt a_m) (sqrt a_m) b_m))
      (*
       (* (sin (* (* (* t_0 t_0) angle_m) 0.011111111111111112)) (- b_m a_m))
       (+ b_m a_m))))))
\begin{array}{l}
b_m = \left|b\right|
\\
a_m = \left|a\right|
\\
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

\\
\begin{array}{l}
t_0 := {\left(\sqrt[3]{\sqrt{\mathsf{PI}\left(\right)}}\right)}^{3}\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;\frac{angle\_m}{180} \leq 6 \cdot 10^{+132}:\\
\;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\_m\right)\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \mathsf{fma}\left(\sqrt{a\_m}, \sqrt{a\_m}, b\_m\right)\\

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


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

    1. Initial program 54.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\color{blue}{\mathsf{PI}\left(\right)}}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
      7. lower-pow.f6473.9

        \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
    6. Applied rewrites73.9%

      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
    7. Step-by-step derivation
      1. lift-+.f64N/A

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \color{blue}{\sqrt{a}}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
      10. lower-sqrt.f6438.3

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \color{blue}{\sqrt{a}}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}\right) \cdot 0.011111111111111112\right)\right) \]
    8. Applied rewrites38.3%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right)} \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}\right) \cdot 0.011111111111111112\right)\right) \]
    9. Step-by-step derivation
      1. lift-pow.f64N/A

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

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

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}}\right) \cdot \frac{1}{90}\right)\right) \]
      4. lower-*.f6438.3

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \mathsf{PI}\left(\right)}\right) \cdot 0.011111111111111112\right)\right) \]
    10. Applied rewrites38.3%

      \[\leadsto \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}}\right) \cdot 0.011111111111111112\right)\right) \]

    if 5.9999999999999996e132 < (/.f64 angle #s(literal 180 binary64))

    1. Initial program 31.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot 0.011111111111111112\right)\right)} \]
    5. Step-by-step derivation
      1. rem-cube-cbrtN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \left({\left(\sqrt[3]{\sqrt{\mathsf{PI}\left(\right)}}\right)}^{3} \cdot {\left(\sqrt[3]{\color{blue}{\sqrt{\mathsf{PI}\left(\right)}}}\right)}^{3}\right)\right) \cdot 0.011111111111111112\right)\right) \]
    6. Applied rewrites36.5%

      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\left({\left(\sqrt[3]{\sqrt{\mathsf{PI}\left(\right)}}\right)}^{3} \cdot {\left(\sqrt[3]{\sqrt{\mathsf{PI}\left(\right)}}\right)}^{3}\right)}\right) \cdot 0.011111111111111112\right)\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification38.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 6 \cdot 10^{+132}:\\ \;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\right)\right) \cdot \left(b - a\right)\right) \cdot \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\sin \left(\left(\left({\left(\sqrt[3]{\sqrt{\mathsf{PI}\left(\right)}}\right)}^{3} \cdot {\left(\sqrt[3]{\sqrt{\mathsf{PI}\left(\right)}}\right)}^{3}\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 66.6% accurate, 0.8× speedup?

\[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := {b\_m}^{2} - {a\_m}^{2}\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;t\_0 \leq 2 \cdot 10^{-291}:\\ \;\;\;\;\left(\left(-a\_m\right) \cdot \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right)\right) \cdot \left(b\_m + a\_m\right)\\ \mathbf{elif}\;t\_0 \leq 2 \cdot 10^{+304}:\\ \;\;\;\;\sin \left(\left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \mathsf{PI}\left(\right)\right) \cdot 2\right) \cdot \left(b\_m \cdot b\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m - a\_m\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m + a\_m\right)\\ \end{array} \end{array} \end{array} \]
b_m = (fabs.f64 b)
a_m = (fabs.f64 a)
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a_m b_m angle_m)
 :precision binary64
 (let* ((t_0 (- (pow b_m 2.0) (pow a_m 2.0))))
   (*
    angle_s
    (if (<= t_0 2e-291)
      (*
       (* (- a_m) (sin (* (* (PI) angle_m) 0.011111111111111112)))
       (+ b_m a_m))
      (if (<= t_0 2e+304)
        (* (sin (* (* (* 0.005555555555555556 angle_m) (PI)) 2.0)) (* b_m b_m))
        (*
         (* (* (* (PI) (- b_m a_m)) angle_m) 0.011111111111111112)
         (+ b_m a_m)))))))
\begin{array}{l}
b_m = \left|b\right|
\\
a_m = \left|a\right|
\\
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

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

\mathbf{elif}\;t\_0 \leq 2 \cdot 10^{+304}:\\
\;\;\;\;\sin \left(\left(\left(0.005555555555555556 \cdot angle\_m\right) \cdot \mathsf{PI}\left(\right)\right) \cdot 2\right) \cdot \left(b\_m \cdot b\_m\right)\\

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


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

    1. Initial program 61.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(a + b\right) \cdot \left(\color{blue}{\left(-a\right)} \cdot \sin \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot 0.011111111111111112\right)\right) \]
    7. Applied rewrites71.9%

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

    if 1.99999999999999992e-291 < (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64))) < 1.9999999999999999e304

    1. Initial program 44.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(b \cdot b\right) \cdot \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \color{blue}{\cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)}\right)\right) \]
    7. Applied rewrites44.6%

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

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

    1. Initial program 41.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \color{blue}{\mathsf{PI}\left(\right)}\right) \cdot angle\right) \cdot 0.011111111111111112\right) \]
    7. Applied rewrites77.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;{b}^{2} - {a}^{2} \leq 2 \cdot 10^{-291}:\\ \;\;\;\;\left(\left(-a\right) \cdot \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot 0.011111111111111112\right)\right) \cdot \left(b + a\right)\\ \mathbf{elif}\;{b}^{2} - {a}^{2} \leq 2 \cdot 10^{+304}:\\ \;\;\;\;\sin \left(\left(\left(0.005555555555555556 \cdot angle\right) \cdot \mathsf{PI}\left(\right)\right) \cdot 2\right) \cdot \left(b \cdot b\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b - a\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b + a\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 67.5% accurate, 1.0× speedup?

\[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+163}:\\ \;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\_m\right)\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \mathsf{fma}\left(\sqrt{a\_m}, \sqrt{a\_m}, b\_m\right)\\ \mathbf{else}:\\ \;\;\;\;1 \cdot \left(\sin \left(e^{-\log \left(\frac{180}{angle\_m}\right)} \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\frac{1}{{\left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right)}^{-1}} \cdot 2\right)\right)\\ \end{array} \end{array} \]
b_m = (fabs.f64 b)
a_m = (fabs.f64 a)
angle\_m = (fabs.f64 angle)
angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
(FPCore (angle_s a_m b_m angle_m)
 :precision binary64
 (*
  angle_s
  (if (<= (/ angle_m 180.0) 5e+163)
    (*
     (*
      (sin (* 0.011111111111111112 (* (cbrt (* (* (PI) (PI)) (PI))) angle_m)))
      (- b_m a_m))
     (fma (sqrt a_m) (sqrt a_m) b_m))
    (*
     1.0
     (*
      (sin (* (exp (- (log (/ 180.0 angle_m)))) (PI)))
      (* (/ 1.0 (pow (* (+ b_m a_m) (- b_m a_m)) -1.0)) 2.0))))))
\begin{array}{l}
b_m = \left|b\right|
\\
a_m = \left|a\right|
\\
angle\_m = \left|angle\right|
\\
angle\_s = \mathsf{copysign}\left(1, angle\right)

\\
angle\_s \cdot \begin{array}{l}
\mathbf{if}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+163}:\\
\;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\_m\right)\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \mathsf{fma}\left(\sqrt{a\_m}, \sqrt{a\_m}, b\_m\right)\\

\mathbf{else}:\\
\;\;\;\;1 \cdot \left(\sin \left(e^{-\log \left(\frac{180}{angle\_m}\right)} \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\frac{1}{{\left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right)}^{-1}} \cdot 2\right)\right)\\


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

    1. Initial program 54.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\color{blue}{\mathsf{PI}\left(\right)}}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
      7. lower-pow.f6473.2

        \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
    6. Applied rewrites73.2%

      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
    7. Step-by-step derivation
      1. lift-+.f64N/A

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \color{blue}{\sqrt{a}}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
      10. lower-sqrt.f6438.4

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \color{blue}{\sqrt{a}}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}\right) \cdot 0.011111111111111112\right)\right) \]
    8. Applied rewrites38.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right)} \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}\right) \cdot 0.011111111111111112\right)\right) \]
    9. Step-by-step derivation
      1. lift-pow.f64N/A

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

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

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}}\right) \cdot \frac{1}{90}\right)\right) \]
      4. lower-*.f6438.4

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \mathsf{PI}\left(\right)}\right) \cdot 0.011111111111111112\right)\right) \]
    10. Applied rewrites38.4%

      \[\leadsto \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}}\right) \cdot 0.011111111111111112\right)\right) \]

    if 5e163 < (/.f64 angle #s(literal 180 binary64))

    1. Initial program 31.7%

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(2 \cdot \frac{1}{\color{blue}{{\left({b}^{2} - {a}^{2}\right)}^{-1}}}\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
      9. lower-pow.f6431.7

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(\left(2 \cdot \frac{1}{{\left(\left(b - a\right) \cdot \left(a + b\right)\right)}^{-1}}\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \color{blue}{e^{\log \left(\frac{180}{angle}\right) \cdot -1}}\right)\right) \cdot 1 \]
    7. Recombined 2 regimes into one program.
    8. Final simplification39.1%

      \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 5 \cdot 10^{+163}:\\ \;\;\;\;\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\right)\right) \cdot \left(b - a\right)\right) \cdot \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right)\\ \mathbf{else}:\\ \;\;\;\;1 \cdot \left(\sin \left(e^{-\log \left(\frac{180}{angle}\right)} \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\frac{1}{{\left(\left(b + a\right) \cdot \left(b - a\right)\right)}^{-1}} \cdot 2\right)\right)\\ \end{array} \]
    9. Add Preprocessing

    Alternative 5: 67.4% accurate, 1.7× speedup?

    \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\_m\right)\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \mathsf{fma}\left(\sqrt{a\_m}, \sqrt{a\_m}, b\_m\right)\right) \end{array} \]
    b_m = (fabs.f64 b)
    a_m = (fabs.f64 a)
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a_m b_m angle_m)
     :precision binary64
     (*
      angle_s
      (*
       (*
        (sin (* 0.011111111111111112 (* (cbrt (* (* (PI) (PI)) (PI))) angle_m)))
        (- b_m a_m))
       (fma (sqrt a_m) (sqrt a_m) b_m))))
    \begin{array}{l}
    b_m = \left|b\right|
    \\
    a_m = \left|a\right|
    \\
    angle\_m = \left|angle\right|
    \\
    angle\_s = \mathsf{copysign}\left(1, angle\right)
    
    \\
    angle\_s \cdot \left(\left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\_m\right)\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \mathsf{fma}\left(\sqrt{a\_m}, \sqrt{a\_m}, b\_m\right)\right)
    \end{array}
    
    Derivation
    1. Initial program 51.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\color{blue}{\mathsf{PI}\left(\right)}}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
      7. lower-pow.f6467.9

        \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
    6. Applied rewrites67.9%

      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
    7. Step-by-step derivation
      1. lift-+.f64N/A

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \color{blue}{\sqrt{a}}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
      10. lower-sqrt.f6435.5

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \color{blue}{\sqrt{a}}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}\right) \cdot 0.011111111111111112\right)\right) \]
    8. Applied rewrites35.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right)} \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}\right) \cdot 0.011111111111111112\right)\right) \]
    9. Step-by-step derivation
      1. lift-pow.f64N/A

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

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

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}}\right) \cdot \frac{1}{90}\right)\right) \]
      4. lower-*.f6435.5

        \[\leadsto \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \mathsf{PI}\left(\right)}\right) \cdot 0.011111111111111112\right)\right) \]
    10. Applied rewrites35.5%

      \[\leadsto \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}}\right) \cdot 0.011111111111111112\right)\right) \]
    11. Final simplification35.5%

      \[\leadsto \left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\right)\right) \cdot \left(b - a\right)\right) \cdot \mathsf{fma}\left(\sqrt{a}, \sqrt{a}, b\right) \]
    12. Add Preprocessing

    Alternative 6: 58.6% accurate, 1.9× speedup?

    \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;{b\_m}^{2} - {a\_m}^{2} \leq -5 \cdot 10^{+275}:\\ \;\;\;\;\left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot a\_m\right) \cdot \left(-0.011111111111111112 \cdot a\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right)\right) \cdot angle\_m\\ \end{array} \end{array} \]
    b_m = (fabs.f64 b)
    a_m = (fabs.f64 a)
    angle\_m = (fabs.f64 angle)
    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
    (FPCore (angle_s a_m b_m angle_m)
     :precision binary64
     (*
      angle_s
      (if (<= (- (pow b_m 2.0) (pow a_m 2.0)) -5e+275)
        (* (* (* (PI) angle_m) a_m) (* -0.011111111111111112 a_m))
        (*
         (* (* 0.011111111111111112 (PI)) (* (+ b_m a_m) (- b_m a_m)))
         angle_m))))
    \begin{array}{l}
    b_m = \left|b\right|
    \\
    a_m = \left|a\right|
    \\
    angle\_m = \left|angle\right|
    \\
    angle\_s = \mathsf{copysign}\left(1, angle\right)
    
    \\
    angle\_s \cdot \begin{array}{l}
    \mathbf{if}\;{b\_m}^{2} - {a\_m}^{2} \leq -5 \cdot 10^{+275}:\\
    \;\;\;\;\left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot a\_m\right) \cdot \left(-0.011111111111111112 \cdot a\_m\right)\\
    
    \mathbf{else}:\\
    \;\;\;\;\left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right)\right) \cdot angle\_m\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64))) < -5.0000000000000003e275

      1. Initial program 56.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          1. Initial program 50.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
          5. Applied rewrites51.0%

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

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

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

          Alternative 7: 58.4% accurate, 1.9× speedup?

          \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;{b\_m}^{2} - {a\_m}^{2} \leq -2 \cdot 10^{+58}:\\ \;\;\;\;\left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot a\_m\right) \cdot \left(-0.011111111111111112 \cdot a\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(0.011111111111111112 \cdot angle\_m\right)\\ \end{array} \end{array} \]
          b_m = (fabs.f64 b)
          a_m = (fabs.f64 a)
          angle\_m = (fabs.f64 angle)
          angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
          (FPCore (angle_s a_m b_m angle_m)
           :precision binary64
           (*
            angle_s
            (if (<= (- (pow b_m 2.0) (pow a_m 2.0)) -2e+58)
              (* (* (* (PI) angle_m) a_m) (* -0.011111111111111112 a_m))
              (*
               (* (* (+ b_m a_m) (- b_m a_m)) (PI))
               (* 0.011111111111111112 angle_m)))))
          \begin{array}{l}
          b_m = \left|b\right|
          \\
          a_m = \left|a\right|
          \\
          angle\_m = \left|angle\right|
          \\
          angle\_s = \mathsf{copysign}\left(1, angle\right)
          
          \\
          angle\_s \cdot \begin{array}{l}
          \mathbf{if}\;{b\_m}^{2} - {a\_m}^{2} \leq -2 \cdot 10^{+58}:\\
          \;\;\;\;\left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot a\_m\right) \cdot \left(-0.011111111111111112 \cdot a\_m\right)\\
          
          \mathbf{else}:\\
          \;\;\;\;\left(\left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(0.011111111111111112 \cdot angle\_m\right)\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 2 regimes
          2. if (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64))) < -1.99999999999999989e58

            1. Initial program 51.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
            5. Applied rewrites49.0%

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

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

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

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

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

                1. Initial program 51.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                Alternative 8: 67.4% accurate, 1.9× speedup?

                \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(b\_m + a\_m\right) \cdot \left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\_m\right)\right) \cdot \left(b\_m - a\_m\right)\right)\right) \end{array} \]
                b_m = (fabs.f64 b)
                a_m = (fabs.f64 a)
                angle\_m = (fabs.f64 angle)
                angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                (FPCore (angle_s a_m b_m angle_m)
                 :precision binary64
                 (*
                  angle_s
                  (*
                   (+ b_m a_m)
                   (*
                    (sin (* 0.011111111111111112 (* (cbrt (* (* (PI) (PI)) (PI))) angle_m)))
                    (- b_m a_m)))))
                \begin{array}{l}
                b_m = \left|b\right|
                \\
                a_m = \left|a\right|
                \\
                angle\_m = \left|angle\right|
                \\
                angle\_s = \mathsf{copysign}\left(1, angle\right)
                
                \\
                angle\_s \cdot \left(\left(b\_m + a\_m\right) \cdot \left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\_m\right)\right) \cdot \left(b\_m - a\_m\right)\right)\right)
                \end{array}
                
                Derivation
                1. Initial program 51.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\color{blue}{\mathsf{PI}\left(\right)}}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
                  7. lower-pow.f6467.9

                    \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
                6. Applied rewrites67.9%

                  \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
                7. Step-by-step derivation
                  1. lift-pow.f64N/A

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

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

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

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

                  \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}}\right) \cdot 0.011111111111111112\right)\right) \]
                9. Final simplification67.9%

                  \[\leadsto \left(b + a\right) \cdot \left(\sin \left(0.011111111111111112 \cdot \left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)} \cdot angle\right)\right) \cdot \left(b - a\right)\right) \]
                10. Add Preprocessing

                Alternative 9: 57.4% accurate, 2.0× speedup?

                \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;{b\_m}^{2} - {a\_m}^{2} \leq -5 \cdot 10^{-253}:\\ \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot a\_m\right) \cdot a\_m\right) \cdot -0.011111111111111112\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(b\_m \cdot b\_m\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\\ \end{array} \end{array} \]
                b_m = (fabs.f64 b)
                a_m = (fabs.f64 a)
                angle\_m = (fabs.f64 angle)
                angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                (FPCore (angle_s a_m b_m angle_m)
                 :precision binary64
                 (*
                  angle_s
                  (if (<= (- (pow b_m 2.0) (pow a_m 2.0)) -5e-253)
                    (* (* (* (* (PI) angle_m) a_m) a_m) -0.011111111111111112)
                    (* (* (* (* b_m b_m) (PI)) angle_m) 0.011111111111111112))))
                \begin{array}{l}
                b_m = \left|b\right|
                \\
                a_m = \left|a\right|
                \\
                angle\_m = \left|angle\right|
                \\
                angle\_s = \mathsf{copysign}\left(1, angle\right)
                
                \\
                angle\_s \cdot \begin{array}{l}
                \mathbf{if}\;{b\_m}^{2} - {a\_m}^{2} \leq -5 \cdot 10^{-253}:\\
                \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot a\_m\right) \cdot a\_m\right) \cdot -0.011111111111111112\\
                
                \mathbf{else}:\\
                \;\;\;\;\left(\left(\left(b\_m \cdot b\_m\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\\
                
                
                \end{array}
                \end{array}
                
                Derivation
                1. Split input into 2 regimes
                2. if (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64))) < -4.99999999999999971e-253

                  1. Initial program 54.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                          \[\leadsto \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right) \cdot a\right) \cdot -0.011111111111111112 \]

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

                        1. Initial program 49.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        Alternative 10: 57.4% accurate, 2.0× speedup?

                        \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;{b\_m}^{2} - {a\_m}^{2} \leq -5 \cdot 10^{-253}:\\ \;\;\;\;\left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot a\_m\right) \cdot \left(-0.011111111111111112 \cdot a\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(b\_m \cdot b\_m\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\\ \end{array} \end{array} \]
                        b_m = (fabs.f64 b)
                        a_m = (fabs.f64 a)
                        angle\_m = (fabs.f64 angle)
                        angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                        (FPCore (angle_s a_m b_m angle_m)
                         :precision binary64
                         (*
                          angle_s
                          (if (<= (- (pow b_m 2.0) (pow a_m 2.0)) -5e-253)
                            (* (* (* (PI) angle_m) a_m) (* -0.011111111111111112 a_m))
                            (* (* (* (* b_m b_m) (PI)) angle_m) 0.011111111111111112))))
                        \begin{array}{l}
                        b_m = \left|b\right|
                        \\
                        a_m = \left|a\right|
                        \\
                        angle\_m = \left|angle\right|
                        \\
                        angle\_s = \mathsf{copysign}\left(1, angle\right)
                        
                        \\
                        angle\_s \cdot \begin{array}{l}
                        \mathbf{if}\;{b\_m}^{2} - {a\_m}^{2} \leq -5 \cdot 10^{-253}:\\
                        \;\;\;\;\left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot a\_m\right) \cdot \left(-0.011111111111111112 \cdot a\_m\right)\\
                        
                        \mathbf{else}:\\
                        \;\;\;\;\left(\left(\left(b\_m \cdot b\_m\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\\
                        
                        
                        \end{array}
                        \end{array}
                        
                        Derivation
                        1. Split input into 2 regimes
                        2. if (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64))) < -4.99999999999999971e-253

                          1. Initial program 54.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                              1. Initial program 49.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                              Alternative 11: 64.8% accurate, 2.0× speedup?

                              \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;{a\_m}^{2} \leq 2 \cdot 10^{-290}:\\ \;\;\;\;\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot b\_m\right) \cdot \left(b\_m + a\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m - a\_m\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m + a\_m\right)\\ \end{array} \end{array} \]
                              b_m = (fabs.f64 b)
                              a_m = (fabs.f64 a)
                              angle\_m = (fabs.f64 angle)
                              angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                              (FPCore (angle_s a_m b_m angle_m)
                               :precision binary64
                               (*
                                angle_s
                                (if (<= (pow a_m 2.0) 2e-290)
                                  (* (* (sin (* (* (PI) angle_m) 0.011111111111111112)) b_m) (+ b_m a_m))
                                  (*
                                   (* (* (* (PI) (- b_m a_m)) angle_m) 0.011111111111111112)
                                   (+ b_m a_m)))))
                              \begin{array}{l}
                              b_m = \left|b\right|
                              \\
                              a_m = \left|a\right|
                              \\
                              angle\_m = \left|angle\right|
                              \\
                              angle\_s = \mathsf{copysign}\left(1, angle\right)
                              
                              \\
                              angle\_s \cdot \begin{array}{l}
                              \mathbf{if}\;{a\_m}^{2} \leq 2 \cdot 10^{-290}:\\
                              \;\;\;\;\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot b\_m\right) \cdot \left(b\_m + a\_m\right)\\
                              
                              \mathbf{else}:\\
                              \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m - a\_m\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m + a\_m\right)\\
                              
                              
                              \end{array}
                              \end{array}
                              
                              Derivation
                              1. Split input into 2 regimes
                              2. if (pow.f64 a #s(literal 2 binary64)) < 2.0000000000000001e-290

                                1. Initial program 58.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \left(a + b\right) \cdot \left(\sin \left(\left(\color{blue}{\mathsf{PI}\left(\right)} \cdot angle\right) \cdot 0.011111111111111112\right) \cdot b\right) \]
                                7. Applied rewrites62.7%

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

                                if 2.0000000000000001e-290 < (pow.f64 a #s(literal 2 binary64))

                                1. Initial program 49.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \color{blue}{\mathsf{PI}\left(\right)}\right) \cdot angle\right) \cdot 0.011111111111111112\right) \]
                                7. Applied rewrites64.3%

                                  \[\leadsto \left(a + b\right) \cdot \color{blue}{\left(\left(\left(\left(b - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)} \]
                              3. Recombined 2 regimes into one program.
                              4. Final simplification63.9%

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

                              Alternative 12: 66.9% accurate, 2.2× speedup?

                              \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+52}:\\ \;\;\;\;\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\\ \mathbf{elif}\;\frac{angle\_m}{180} \leq 2 \cdot 10^{+150}:\\ \;\;\;\;\frac{\left(\sin \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right)}{-a\_m}\\ \mathbf{else}:\\ \;\;\;\;\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle\_m}{180}\right) \cdot \left(\mathsf{fma}\left(\left(b\_m - a\_m\right) \cdot \sqrt{a\_m}, \sqrt{a\_m}, \left(b\_m - a\_m\right) \cdot b\_m\right) \cdot 2\right)\right) \cdot 1\\ \end{array} \end{array} \]
                              b_m = (fabs.f64 b)
                              a_m = (fabs.f64 a)
                              angle\_m = (fabs.f64 angle)
                              angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                              (FPCore (angle_s a_m b_m angle_m)
                               :precision binary64
                               (*
                                angle_s
                                (if (<= (/ angle_m 180.0) 1e+52)
                                  (*
                                   (* (sin (* (* (PI) angle_m) 0.011111111111111112)) (- b_m a_m))
                                   (+ b_m a_m))
                                  (if (<= (/ angle_m 180.0) 2e+150)
                                    (/
                                     (*
                                      (* (sin (* (* 0.011111111111111112 (PI)) angle_m)) (- b_m a_m))
                                      (* (+ b_m a_m) (- b_m a_m)))
                                     (- a_m))
                                    (*
                                     (*
                                      (sin (* (PI) (/ angle_m 180.0)))
                                      (*
                                       (fma (* (- b_m a_m) (sqrt a_m)) (sqrt a_m) (* (- b_m a_m) b_m))
                                       2.0))
                                     1.0)))))
                              \begin{array}{l}
                              b_m = \left|b\right|
                              \\
                              a_m = \left|a\right|
                              \\
                              angle\_m = \left|angle\right|
                              \\
                              angle\_s = \mathsf{copysign}\left(1, angle\right)
                              
                              \\
                              angle\_s \cdot \begin{array}{l}
                              \mathbf{if}\;\frac{angle\_m}{180} \leq 10^{+52}:\\
                              \;\;\;\;\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\\
                              
                              \mathbf{elif}\;\frac{angle\_m}{180} \leq 2 \cdot 10^{+150}:\\
                              \;\;\;\;\frac{\left(\sin \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right)}{-a\_m}\\
                              
                              \mathbf{else}:\\
                              \;\;\;\;\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle\_m}{180}\right) \cdot \left(\mathsf{fma}\left(\left(b\_m - a\_m\right) \cdot \sqrt{a\_m}, \sqrt{a\_m}, \left(b\_m - a\_m\right) \cdot b\_m\right) \cdot 2\right)\right) \cdot 1\\
                              
                              
                              \end{array}
                              \end{array}
                              
                              Derivation
                              1. Split input into 3 regimes
                              2. if (/.f64 angle #s(literal 180 binary64)) < 9.9999999999999999e51

                                1. Initial program 55.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                if 9.9999999999999999e51 < (/.f64 angle #s(literal 180 binary64)) < 1.99999999999999996e150

                                1. Initial program 33.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \frac{\left(\left(b - a\right) \cdot \left(b + a\right)\right) \cdot \left(\sin \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \left(b - a\right)\right)}{\color{blue}{-a}} \]
                                9. Applied rewrites30.9%

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

                                if 1.99999999999999996e150 < (/.f64 angle #s(literal 180 binary64))

                                1. Initial program 30.5%

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

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

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

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

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

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

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

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

                                    \[\leadsto \left(\left(2 \cdot \frac{1}{\color{blue}{{\left({b}^{2} - {a}^{2}\right)}^{-1}}}\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                  9. lower-pow.f6430.5

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                      \[\leadsto \left(\left(2 \cdot \frac{1}{\color{blue}{\frac{1}{\left(b - a\right) \cdot \left(a + b\right)}}}\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot 1 \]
                                    4. remove-double-div26.7

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \left(\left(2 \cdot \color{blue}{\mathsf{fma}\left(\left(b - a\right) \cdot \sqrt{a}, \sqrt{a}, \left(b - a\right) \cdot b\right)}\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot 1 \]
                                7. Recombined 3 regimes into one program.
                                8. Final simplification64.7%

                                  \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 10^{+52}:\\ \;\;\;\;\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\ \mathbf{elif}\;\frac{angle}{180} \leq 2 \cdot 10^{+150}:\\ \;\;\;\;\frac{\left(\sin \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \left(b - a\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)}{-a}\\ \mathbf{else}:\\ \;\;\;\;\left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \left(\mathsf{fma}\left(\left(b - a\right) \cdot \sqrt{a}, \sqrt{a}, \left(b - a\right) \cdot b\right) \cdot 2\right)\right) \cdot 1\\ \end{array} \]
                                9. Add Preprocessing

                                Alternative 13: 67.2% accurate, 3.0× speedup?

                                \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \sqrt{\mathsf{PI}\left(\right)}\\ angle\_s \cdot \left(\left(\sin \left(\left(\left(0.011111111111111112 \cdot angle\_m\right) \cdot t\_0\right) \cdot t\_0\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\right) \end{array} \end{array} \]
                                b_m = (fabs.f64 b)
                                a_m = (fabs.f64 a)
                                angle\_m = (fabs.f64 angle)
                                angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                (FPCore (angle_s a_m b_m angle_m)
                                 :precision binary64
                                 (let* ((t_0 (sqrt (PI))))
                                   (*
                                    angle_s
                                    (*
                                     (* (sin (* (* (* 0.011111111111111112 angle_m) t_0) t_0)) (- b_m a_m))
                                     (+ b_m a_m)))))
                                \begin{array}{l}
                                b_m = \left|b\right|
                                \\
                                a_m = \left|a\right|
                                \\
                                angle\_m = \left|angle\right|
                                \\
                                angle\_s = \mathsf{copysign}\left(1, angle\right)
                                
                                \\
                                \begin{array}{l}
                                t_0 := \sqrt{\mathsf{PI}\left(\right)}\\
                                angle\_s \cdot \left(\left(\sin \left(\left(\left(0.011111111111111112 \cdot angle\_m\right) \cdot t\_0\right) \cdot t\_0\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\right)
                                \end{array}
                                \end{array}
                                
                                Derivation
                                1. Initial program 51.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\color{blue}{\mathsf{PI}\left(\right)}}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
                                  7. lower-pow.f6467.9

                                    \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
                                6. Applied rewrites67.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(\left(0.011111111111111112 \cdot angle\right) \cdot \sqrt{\mathsf{PI}\left(\right)}\right) \cdot \color{blue}{\sqrt{\mathsf{PI}\left(\right)}}\right)\right) \]
                                8. Applied rewrites66.1%

                                  \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \color{blue}{\left(\left(\left(0.011111111111111112 \cdot angle\right) \cdot \sqrt{\mathsf{PI}\left(\right)}\right) \cdot \sqrt{\mathsf{PI}\left(\right)}\right)}\right) \]
                                9. Final simplification66.1%

                                  \[\leadsto \left(\sin \left(\left(\left(0.011111111111111112 \cdot angle\right) \cdot \sqrt{\mathsf{PI}\left(\right)}\right) \cdot \sqrt{\mathsf{PI}\left(\right)}\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right) \]
                                10. Add Preprocessing

                                Alternative 14: 67.4% accurate, 3.1× speedup?

                                \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 2 \cdot 10^{-11}:\\ \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m - a\_m\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m + a\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right)\\ \end{array} \end{array} \]
                                b_m = (fabs.f64 b)
                                a_m = (fabs.f64 a)
                                angle\_m = (fabs.f64 angle)
                                angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                (FPCore (angle_s a_m b_m angle_m)
                                 :precision binary64
                                 (*
                                  angle_s
                                  (if (<= (/ angle_m 180.0) 2e-11)
                                    (* (* (* (* (PI) (- b_m a_m)) angle_m) 0.011111111111111112) (+ b_m a_m))
                                    (*
                                     (* (+ b_m a_m) (- b_m a_m))
                                     (sin (* (* (PI) angle_m) 0.011111111111111112))))))
                                \begin{array}{l}
                                b_m = \left|b\right|
                                \\
                                a_m = \left|a\right|
                                \\
                                angle\_m = \left|angle\right|
                                \\
                                angle\_s = \mathsf{copysign}\left(1, angle\right)
                                
                                \\
                                angle\_s \cdot \begin{array}{l}
                                \mathbf{if}\;\frac{angle\_m}{180} \leq 2 \cdot 10^{-11}:\\
                                \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m - a\_m\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m + a\_m\right)\\
                                
                                \mathbf{else}:\\
                                \;\;\;\;\left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right)\\
                                
                                
                                \end{array}
                                \end{array}
                                
                                Derivation
                                1. Split input into 2 regimes
                                2. if (/.f64 angle #s(literal 180 binary64)) < 1.99999999999999988e-11

                                  1. Initial program 56.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \color{blue}{\mathsf{PI}\left(\right)}\right) \cdot angle\right) \cdot 0.011111111111111112\right) \]
                                  7. Applied rewrites72.7%

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

                                  if 1.99999999999999988e-11 < (/.f64 angle #s(literal 180 binary64))

                                  1. Initial program 36.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                Alternative 15: 67.4% accurate, 3.6× speedup?

                                \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\right) \end{array} \]
                                b_m = (fabs.f64 b)
                                a_m = (fabs.f64 a)
                                angle\_m = (fabs.f64 angle)
                                angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                (FPCore (angle_s a_m b_m angle_m)
                                 :precision binary64
                                 (*
                                  angle_s
                                  (*
                                   (* (sin (* (* (PI) angle_m) 0.011111111111111112)) (- b_m a_m))
                                   (+ b_m a_m))))
                                \begin{array}{l}
                                b_m = \left|b\right|
                                \\
                                a_m = \left|a\right|
                                \\
                                angle\_m = \left|angle\right|
                                \\
                                angle\_s = \mathsf{copysign}\left(1, angle\right)
                                
                                \\
                                angle\_s \cdot \left(\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\right)
                                \end{array}
                                
                                Derivation
                                1. Initial program 51.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                  \[\leadsto \color{blue}{\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot 0.011111111111111112\right)\right)} \]
                                5. Final simplification65.8%

                                  \[\leadsto \left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right) \]
                                6. Add Preprocessing

                                Alternative 16: 67.7% accurate, 3.6× speedup?

                                \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(\sin \left(\left(0.011111111111111112 \cdot angle\_m\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\right) \end{array} \]
                                b_m = (fabs.f64 b)
                                a_m = (fabs.f64 a)
                                angle\_m = (fabs.f64 angle)
                                angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                (FPCore (angle_s a_m b_m angle_m)
                                 :precision binary64
                                 (*
                                  angle_s
                                  (*
                                   (* (sin (* (* 0.011111111111111112 angle_m) (PI))) (- b_m a_m))
                                   (+ b_m a_m))))
                                \begin{array}{l}
                                b_m = \left|b\right|
                                \\
                                a_m = \left|a\right|
                                \\
                                angle\_m = \left|angle\right|
                                \\
                                angle\_s = \mathsf{copysign}\left(1, angle\right)
                                
                                \\
                                angle\_s \cdot \left(\left(\sin \left(\left(0.011111111111111112 \cdot angle\_m\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\right)
                                \end{array}
                                
                                Derivation
                                1. Initial program 51.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\color{blue}{\mathsf{PI}\left(\right)}}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
                                  7. lower-pow.f6467.9

                                    \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
                                6. Applied rewrites67.9%

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

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

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

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

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

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

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

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

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

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

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

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

                                  \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \color{blue}{\left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\right)\right)}\right) \]
                                9. Final simplification65.5%

                                  \[\leadsto \left(\sin \left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right) \]
                                10. Add Preprocessing

                                Alternative 17: 63.2% accurate, 5.2× speedup?

                                \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \left(\left(\mathsf{fma}\left(\left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle\_m \cdot angle\_m\right)\right) \cdot \mathsf{PI}\left(\right), \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right), 0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 150000:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;\frac{angle\_m}{180} \leq 10^{+218}:\\ \;\;\;\;\left(\left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(0.011111111111111112 \cdot angle\_m\right)\\ \mathbf{else}:\\ \;\;\;\;t\_0\\ \end{array} \end{array} \end{array} \]
                                b_m = (fabs.f64 b)
                                a_m = (fabs.f64 a)
                                angle\_m = (fabs.f64 angle)
                                angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                (FPCore (angle_s a_m b_m angle_m)
                                 :precision binary64
                                 (let* ((t_0
                                         (*
                                          (*
                                           (*
                                            (fma
                                             (* (* -2.2862368541380886e-7 (* angle_m angle_m)) (PI))
                                             (* (PI) (PI))
                                             (* 0.011111111111111112 (PI)))
                                            angle_m)
                                           (- b_m a_m))
                                          (+ b_m a_m))))
                                   (*
                                    angle_s
                                    (if (<= (/ angle_m 180.0) 150000.0)
                                      t_0
                                      (if (<= (/ angle_m 180.0) 1e+218)
                                        (*
                                         (* (* (+ b_m a_m) (- b_m a_m)) (PI))
                                         (* 0.011111111111111112 angle_m))
                                        t_0)))))
                                \begin{array}{l}
                                b_m = \left|b\right|
                                \\
                                a_m = \left|a\right|
                                \\
                                angle\_m = \left|angle\right|
                                \\
                                angle\_s = \mathsf{copysign}\left(1, angle\right)
                                
                                \\
                                \begin{array}{l}
                                t_0 := \left(\left(\mathsf{fma}\left(\left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle\_m \cdot angle\_m\right)\right) \cdot \mathsf{PI}\left(\right), \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right), 0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\\
                                angle\_s \cdot \begin{array}{l}
                                \mathbf{if}\;\frac{angle\_m}{180} \leq 150000:\\
                                \;\;\;\;t\_0\\
                                
                                \mathbf{elif}\;\frac{angle\_m}{180} \leq 10^{+218}:\\
                                \;\;\;\;\left(\left(\left(b\_m + a\_m\right) \cdot \left(b\_m - a\_m\right)\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(0.011111111111111112 \cdot angle\_m\right)\\
                                
                                \mathbf{else}:\\
                                \;\;\;\;t\_0\\
                                
                                
                                \end{array}
                                \end{array}
                                \end{array}
                                
                                Derivation
                                1. Split input into 2 regimes
                                2. if (/.f64 angle #s(literal 180 binary64)) < 1.5e5 or 1.00000000000000008e218 < (/.f64 angle #s(literal 180 binary64))

                                  1. Initial program 56.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\mathsf{PI}\left(\right)}\right) \cdot \frac{1}{90}\right)\right) \]
                                    2. add-cbrt-cubeN/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}}\right) \cdot \frac{1}{90}\right)\right) \]
                                    3. lower-cbrt.f64N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}}\right) \cdot \frac{1}{90}\right)\right) \]
                                    4. rem-cube-cbrtN/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{{\left(\sqrt[3]{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \mathsf{PI}\left(\right)}\right)}^{3}}}\right) \cdot \frac{1}{90}\right)\right) \]
                                    5. add-cbrt-cubeN/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\color{blue}{\mathsf{PI}\left(\right)}}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
                                    6. lift-PI.f64N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{{\color{blue}{\mathsf{PI}\left(\right)}}^{3}}\right) \cdot \frac{1}{90}\right)\right) \]
                                    7. lower-pow.f6474.9

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \sqrt[3]{\color{blue}{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
                                  6. Applied rewrites74.9%

                                    \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \color{blue}{\sqrt[3]{{\mathsf{PI}\left(\right)}^{3}}}\right) \cdot 0.011111111111111112\right)\right) \]
                                  7. Taylor expanded in angle around 0

                                    \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(angle \cdot \left(\frac{-1}{4374000} \cdot \left({angle}^{2} \cdot {\mathsf{PI}\left(\right)}^{3}\right) + \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)}\right) \]
                                  8. Step-by-step derivation
                                    1. *-commutativeN/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\left(\frac{-1}{4374000} \cdot \left({angle}^{2} \cdot {\mathsf{PI}\left(\right)}^{3}\right) + \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)}\right) \]
                                    2. lower-*.f64N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\left(\frac{-1}{4374000} \cdot \left({angle}^{2} \cdot {\mathsf{PI}\left(\right)}^{3}\right) + \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)}\right) \]
                                    3. associate-*r*N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\left(\color{blue}{\left(\frac{-1}{4374000} \cdot {angle}^{2}\right) \cdot {\mathsf{PI}\left(\right)}^{3}} + \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\right) \]
                                    4. lower-fma.f64N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\color{blue}{\mathsf{fma}\left(\frac{-1}{4374000} \cdot {angle}^{2}, {\mathsf{PI}\left(\right)}^{3}, \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)} \cdot angle\right)\right) \]
                                    5. lower-*.f64N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{fma}\left(\color{blue}{\frac{-1}{4374000} \cdot {angle}^{2}}, {\mathsf{PI}\left(\right)}^{3}, \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\right) \]
                                    6. unpow2N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{fma}\left(\frac{-1}{4374000} \cdot \color{blue}{\left(angle \cdot angle\right)}, {\mathsf{PI}\left(\right)}^{3}, \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\right) \]
                                    7. lower-*.f64N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{fma}\left(\frac{-1}{4374000} \cdot \color{blue}{\left(angle \cdot angle\right)}, {\mathsf{PI}\left(\right)}^{3}, \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\right) \]
                                    8. lower-pow.f64N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{fma}\left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right), \color{blue}{{\mathsf{PI}\left(\right)}^{3}}, \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\right) \]
                                    9. lower-PI.f64N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{fma}\left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right), {\color{blue}{\mathsf{PI}\left(\right)}}^{3}, \frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\right) \]
                                    10. lower-*.f64N/A

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{fma}\left(\frac{-1}{4374000} \cdot \left(angle \cdot angle\right), {\mathsf{PI}\left(\right)}^{3}, \color{blue}{\frac{1}{90} \cdot \mathsf{PI}\left(\right)}\right) \cdot angle\right)\right) \]
                                    11. lower-PI.f6467.0

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{fma}\left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right), {\mathsf{PI}\left(\right)}^{3}, 0.011111111111111112 \cdot \color{blue}{\mathsf{PI}\left(\right)}\right) \cdot angle\right)\right) \]
                                  9. Applied rewrites67.0%

                                    \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \color{blue}{\left(\mathsf{fma}\left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right), {\mathsf{PI}\left(\right)}^{3}, 0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)}\right) \]
                                  10. Step-by-step derivation
                                    1. Applied rewrites67.0%

                                      \[\leadsto \left(a + b\right) \cdot \left(\left(b - a\right) \cdot \left(\mathsf{fma}\left(\left(\left(angle \cdot angle\right) \cdot -2.2862368541380886 \cdot 10^{-7}\right) \cdot \mathsf{PI}\left(\right), \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right), 0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\right) \]

                                    if 1.5e5 < (/.f64 angle #s(literal 180 binary64)) < 1.00000000000000008e218

                                    1. Initial program 29.2%

                                      \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                    2. Add Preprocessing
                                    3. Taylor expanded in angle around 0

                                      \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
                                    4. Step-by-step derivation
                                      1. *-commutativeN/A

                                        \[\leadsto \color{blue}{\left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right) \cdot \frac{1}{90}} \]
                                      2. associate-*r*N/A

                                        \[\leadsto \color{blue}{angle \cdot \left(\left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \frac{1}{90}\right)} \]
                                      3. *-commutativeN/A

                                        \[\leadsto angle \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
                                      4. associate-*r*N/A

                                        \[\leadsto angle \cdot \color{blue}{\left(\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
                                      5. associate-*r*N/A

                                        \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                      6. lower-*.f64N/A

                                        \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                      7. lower-*.f64N/A

                                        \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)} \cdot \left({b}^{2} - {a}^{2}\right) \]
                                      8. lower-*.f64N/A

                                        \[\leadsto \left(angle \cdot \color{blue}{\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)}\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                      9. lower-PI.f64N/A

                                        \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                      10. unpow2N/A

                                        \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right) \]
                                      11. unpow2N/A

                                        \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
                                      12. difference-of-squaresN/A

                                        \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                      13. lower-*.f64N/A

                                        \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                      14. lower-+.f64N/A

                                        \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                      15. lower--.f6431.7

                                        \[\leadsto \left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                    5. Applied rewrites31.7%

                                      \[\leadsto \color{blue}{\left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                    6. Step-by-step derivation
                                      1. Applied rewrites31.7%

                                        \[\leadsto \left(0.011111111111111112 \cdot angle\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \left(\left(b - a\right) \cdot \left(b + a\right)\right)\right)} \]
                                    7. Recombined 2 regimes into one program.
                                    8. Final simplification60.5%

                                      \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 150000:\\ \;\;\;\;\left(\left(\mathsf{fma}\left(\left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \mathsf{PI}\left(\right), \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right), 0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\ \mathbf{elif}\;\frac{angle}{180} \leq 10^{+218}:\\ \;\;\;\;\left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot \mathsf{PI}\left(\right)\right) \cdot \left(0.011111111111111112 \cdot angle\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\mathsf{fma}\left(\left(-2.2862368541380886 \cdot 10^{-7} \cdot \left(angle \cdot angle\right)\right) \cdot \mathsf{PI}\left(\right), \mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right), 0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\ \end{array} \]
                                    9. Add Preprocessing

                                    Alternative 18: 62.8% accurate, 10.3× speedup?

                                    \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+223}:\\ \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m - a\_m\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m + a\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(-a\_m\right) \cdot \left(b\_m + a\_m\right)\right) \cdot \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right)\\ \end{array} \end{array} \]
                                    b_m = (fabs.f64 b)
                                    a_m = (fabs.f64 a)
                                    angle\_m = (fabs.f64 angle)
                                    angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                    (FPCore (angle_s a_m b_m angle_m)
                                     :precision binary64
                                     (*
                                      angle_s
                                      (if (<= (/ angle_m 180.0) 5e+223)
                                        (* (* (* (* (PI) (- b_m a_m)) angle_m) 0.011111111111111112) (+ b_m a_m))
                                        (* (* (- a_m) (+ b_m a_m)) (* (* 0.011111111111111112 (PI)) angle_m)))))
                                    \begin{array}{l}
                                    b_m = \left|b\right|
                                    \\
                                    a_m = \left|a\right|
                                    \\
                                    angle\_m = \left|angle\right|
                                    \\
                                    angle\_s = \mathsf{copysign}\left(1, angle\right)
                                    
                                    \\
                                    angle\_s \cdot \begin{array}{l}
                                    \mathbf{if}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+223}:\\
                                    \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m - a\_m\right)\right) \cdot angle\_m\right) \cdot 0.011111111111111112\right) \cdot \left(b\_m + a\_m\right)\\
                                    
                                    \mathbf{else}:\\
                                    \;\;\;\;\left(\left(-a\_m\right) \cdot \left(b\_m + a\_m\right)\right) \cdot \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\right)\\
                                    
                                    
                                    \end{array}
                                    \end{array}
                                    
                                    Derivation
                                    1. Split input into 2 regimes
                                    2. if (/.f64 angle #s(literal 180 binary64)) < 4.99999999999999985e223

                                      1. Initial program 52.2%

                                        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                      2. Add Preprocessing
                                      3. Step-by-step derivation
                                        1. lift-*.f64N/A

                                          \[\leadsto \color{blue}{\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)} \]
                                        2. lift-*.f64N/A

                                          \[\leadsto \color{blue}{\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                        3. associate-*l*N/A

                                          \[\leadsto \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)} \]
                                        4. lift-*.f64N/A

                                          \[\leadsto \color{blue}{\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right)} \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \]
                                        5. *-commutativeN/A

                                          \[\leadsto \color{blue}{\left(\left({b}^{2} - {a}^{2}\right) \cdot 2\right)} \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \]
                                        6. associate-*l*N/A

                                          \[\leadsto \color{blue}{\left({b}^{2} - {a}^{2}\right) \cdot \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right)} \]
                                        7. lift--.f64N/A

                                          \[\leadsto \color{blue}{\left({b}^{2} - {a}^{2}\right)} \cdot \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
                                        8. lift-pow.f64N/A

                                          \[\leadsto \left(\color{blue}{{b}^{2}} - {a}^{2}\right) \cdot \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
                                        9. unpow2N/A

                                          \[\leadsto \left(\color{blue}{b \cdot b} - {a}^{2}\right) \cdot \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
                                        10. lift-pow.f64N/A

                                          \[\leadsto \left(b \cdot b - \color{blue}{{a}^{2}}\right) \cdot \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
                                        11. unpow2N/A

                                          \[\leadsto \left(b \cdot b - \color{blue}{a \cdot a}\right) \cdot \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
                                        12. difference-of-squaresN/A

                                          \[\leadsto \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \cdot \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right) \]
                                        13. associate-*l*N/A

                                          \[\leadsto \color{blue}{\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right)\right)} \]
                                        14. lower-*.f64N/A

                                          \[\leadsto \color{blue}{\left(b + a\right) \cdot \left(\left(b - a\right) \cdot \left(2 \cdot \left(\sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right)\right)\right)} \]
                                      4. Applied rewrites67.1%

                                        \[\leadsto \color{blue}{\left(a + b\right) \cdot \left(\left(b - a\right) \cdot \sin \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot 0.011111111111111112\right)\right)} \]
                                      5. Taylor expanded in angle around 0

                                        \[\leadsto \left(a + b\right) \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left(b - a\right)\right)\right)\right)} \]
                                      6. Step-by-step derivation
                                        1. *-commutativeN/A

                                          \[\leadsto \left(a + b\right) \cdot \color{blue}{\left(\left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90}\right)} \]
                                        2. lower-*.f64N/A

                                          \[\leadsto \left(a + b\right) \cdot \color{blue}{\left(\left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left(b - a\right)\right)\right) \cdot \frac{1}{90}\right)} \]
                                        3. *-commutativeN/A

                                          \[\leadsto \left(a + b\right) \cdot \left(\color{blue}{\left(\left(\mathsf{PI}\left(\right) \cdot \left(b - a\right)\right) \cdot angle\right)} \cdot \frac{1}{90}\right) \]
                                        4. lower-*.f64N/A

                                          \[\leadsto \left(a + b\right) \cdot \left(\color{blue}{\left(\left(\mathsf{PI}\left(\right) \cdot \left(b - a\right)\right) \cdot angle\right)} \cdot \frac{1}{90}\right) \]
                                        5. *-commutativeN/A

                                          \[\leadsto \left(a + b\right) \cdot \left(\left(\color{blue}{\left(\left(b - a\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot angle\right) \cdot \frac{1}{90}\right) \]
                                        6. lower-*.f64N/A

                                          \[\leadsto \left(a + b\right) \cdot \left(\left(\color{blue}{\left(\left(b - a\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot angle\right) \cdot \frac{1}{90}\right) \]
                                        7. lower--.f64N/A

                                          \[\leadsto \left(a + b\right) \cdot \left(\left(\left(\color{blue}{\left(b - a\right)} \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \frac{1}{90}\right) \]
                                        8. lower-PI.f6464.3

                                          \[\leadsto \left(a + b\right) \cdot \left(\left(\left(\left(b - a\right) \cdot \color{blue}{\mathsf{PI}\left(\right)}\right) \cdot angle\right) \cdot 0.011111111111111112\right) \]
                                      7. Applied rewrites64.3%

                                        \[\leadsto \left(a + b\right) \cdot \color{blue}{\left(\left(\left(\left(b - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)} \]

                                      if 4.99999999999999985e223 < (/.f64 angle #s(literal 180 binary64))

                                      1. Initial program 40.0%

                                        \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                      2. Add Preprocessing
                                      3. Taylor expanded in angle around 0

                                        \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
                                      4. Step-by-step derivation
                                        1. *-commutativeN/A

                                          \[\leadsto \color{blue}{\left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right) \cdot \frac{1}{90}} \]
                                        2. associate-*r*N/A

                                          \[\leadsto \color{blue}{angle \cdot \left(\left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \frac{1}{90}\right)} \]
                                        3. *-commutativeN/A

                                          \[\leadsto angle \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
                                        4. associate-*r*N/A

                                          \[\leadsto angle \cdot \color{blue}{\left(\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
                                        5. associate-*r*N/A

                                          \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                        6. lower-*.f64N/A

                                          \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                        7. lower-*.f64N/A

                                          \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)} \cdot \left({b}^{2} - {a}^{2}\right) \]
                                        8. lower-*.f64N/A

                                          \[\leadsto \left(angle \cdot \color{blue}{\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)}\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                        9. lower-PI.f64N/A

                                          \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                        10. unpow2N/A

                                          \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right) \]
                                        11. unpow2N/A

                                          \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
                                        12. difference-of-squaresN/A

                                          \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                        13. lower-*.f64N/A

                                          \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                        14. lower-+.f64N/A

                                          \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                        15. lower--.f6420.6

                                          \[\leadsto \left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                      5. Applied rewrites20.6%

                                        \[\leadsto \color{blue}{\left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                      6. Taylor expanded in a around inf

                                        \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \left(-1 \cdot \color{blue}{a}\right)\right) \]
                                      7. Step-by-step derivation
                                        1. Applied rewrites21.2%

                                          \[\leadsto \left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \left(-a\right)\right) \]
                                      8. Recombined 2 regimes into one program.
                                      9. Final simplification61.8%

                                        \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 5 \cdot 10^{+223}:\\ \;\;\;\;\left(\left(\left(\mathsf{PI}\left(\right) \cdot \left(b - a\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right) \cdot \left(b + a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(-a\right) \cdot \left(b + a\right)\right) \cdot \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\\ \end{array} \]
                                      10. Add Preprocessing

                                      Alternative 19: 62.8% accurate, 10.3× speedup?

                                      \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ \begin{array}{l} t_0 := \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\\ angle\_s \cdot \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+223}:\\ \;\;\;\;\left(t\_0 \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(-a\_m\right) \cdot \left(b\_m + a\_m\right)\right) \cdot t\_0\\ \end{array} \end{array} \end{array} \]
                                      b_m = (fabs.f64 b)
                                      a_m = (fabs.f64 a)
                                      angle\_m = (fabs.f64 angle)
                                      angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                      (FPCore (angle_s a_m b_m angle_m)
                                       :precision binary64
                                       (let* ((t_0 (* (* 0.011111111111111112 (PI)) angle_m)))
                                         (*
                                          angle_s
                                          (if (<= (/ angle_m 180.0) 5e+223)
                                            (* (* t_0 (- b_m a_m)) (+ b_m a_m))
                                            (* (* (- a_m) (+ b_m a_m)) t_0)))))
                                      \begin{array}{l}
                                      b_m = \left|b\right|
                                      \\
                                      a_m = \left|a\right|
                                      \\
                                      angle\_m = \left|angle\right|
                                      \\
                                      angle\_s = \mathsf{copysign}\left(1, angle\right)
                                      
                                      \\
                                      \begin{array}{l}
                                      t_0 := \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\_m\\
                                      angle\_s \cdot \begin{array}{l}
                                      \mathbf{if}\;\frac{angle\_m}{180} \leq 5 \cdot 10^{+223}:\\
                                      \;\;\;\;\left(t\_0 \cdot \left(b\_m - a\_m\right)\right) \cdot \left(b\_m + a\_m\right)\\
                                      
                                      \mathbf{else}:\\
                                      \;\;\;\;\left(\left(-a\_m\right) \cdot \left(b\_m + a\_m\right)\right) \cdot t\_0\\
                                      
                                      
                                      \end{array}
                                      \end{array}
                                      \end{array}
                                      
                                      Derivation
                                      1. Split input into 2 regimes
                                      2. if (/.f64 angle #s(literal 180 binary64)) < 4.99999999999999985e223

                                        1. Initial program 52.2%

                                          \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                        2. Add Preprocessing
                                        3. Taylor expanded in angle around 0

                                          \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
                                        4. Step-by-step derivation
                                          1. *-commutativeN/A

                                            \[\leadsto \color{blue}{\left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right) \cdot \frac{1}{90}} \]
                                          2. associate-*r*N/A

                                            \[\leadsto \color{blue}{angle \cdot \left(\left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \frac{1}{90}\right)} \]
                                          3. *-commutativeN/A

                                            \[\leadsto angle \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
                                          4. associate-*r*N/A

                                            \[\leadsto angle \cdot \color{blue}{\left(\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
                                          5. associate-*r*N/A

                                            \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                          6. lower-*.f64N/A

                                            \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                          7. lower-*.f64N/A

                                            \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)} \cdot \left({b}^{2} - {a}^{2}\right) \]
                                          8. lower-*.f64N/A

                                            \[\leadsto \left(angle \cdot \color{blue}{\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)}\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                          9. lower-PI.f64N/A

                                            \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                          10. unpow2N/A

                                            \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right) \]
                                          11. unpow2N/A

                                            \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
                                          12. difference-of-squaresN/A

                                            \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                          13. lower-*.f64N/A

                                            \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                          14. lower-+.f64N/A

                                            \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                          15. lower--.f6454.1

                                            \[\leadsto \left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                        5. Applied rewrites54.1%

                                          \[\leadsto \color{blue}{\left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                        6. Step-by-step derivation
                                          1. Applied rewrites64.3%

                                            \[\leadsto \left(b + a\right) \cdot \color{blue}{\left(\left(b - a\right) \cdot \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\right)} \]

                                          if 4.99999999999999985e223 < (/.f64 angle #s(literal 180 binary64))

                                          1. Initial program 40.0%

                                            \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                          2. Add Preprocessing
                                          3. Taylor expanded in angle around 0

                                            \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
                                          4. Step-by-step derivation
                                            1. *-commutativeN/A

                                              \[\leadsto \color{blue}{\left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right) \cdot \frac{1}{90}} \]
                                            2. associate-*r*N/A

                                              \[\leadsto \color{blue}{angle \cdot \left(\left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \frac{1}{90}\right)} \]
                                            3. *-commutativeN/A

                                              \[\leadsto angle \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
                                            4. associate-*r*N/A

                                              \[\leadsto angle \cdot \color{blue}{\left(\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
                                            5. associate-*r*N/A

                                              \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                            6. lower-*.f64N/A

                                              \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                            7. lower-*.f64N/A

                                              \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)} \cdot \left({b}^{2} - {a}^{2}\right) \]
                                            8. lower-*.f64N/A

                                              \[\leadsto \left(angle \cdot \color{blue}{\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)}\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                            9. lower-PI.f64N/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                            10. unpow2N/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right) \]
                                            11. unpow2N/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
                                            12. difference-of-squaresN/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                            13. lower-*.f64N/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                            14. lower-+.f64N/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                            15. lower--.f6420.6

                                              \[\leadsto \left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                          5. Applied rewrites20.6%

                                            \[\leadsto \color{blue}{\left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                          6. Taylor expanded in a around inf

                                            \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \left(-1 \cdot \color{blue}{a}\right)\right) \]
                                          7. Step-by-step derivation
                                            1. Applied rewrites21.2%

                                              \[\leadsto \left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \left(-a\right)\right) \]
                                          8. Recombined 2 regimes into one program.
                                          9. Final simplification61.8%

                                            \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{angle}{180} \leq 5 \cdot 10^{+223}:\\ \;\;\;\;\left(\left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot \left(b - a\right)\right) \cdot \left(b + a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(-a\right) \cdot \left(b + a\right)\right) \cdot \left(\left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\\ \end{array} \]
                                          10. Add Preprocessing

                                          Alternative 20: 38.7% accurate, 21.6× speedup?

                                          \[\begin{array}{l} b_m = \left|b\right| \\ a_m = \left|a\right| \\ angle\_m = \left|angle\right| \\ angle\_s = \mathsf{copysign}\left(1, angle\right) \\ angle\_s \cdot \left(\left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot a\_m\right) \cdot \left(-0.011111111111111112 \cdot a\_m\right)\right) \end{array} \]
                                          b_m = (fabs.f64 b)
                                          a_m = (fabs.f64 a)
                                          angle\_m = (fabs.f64 angle)
                                          angle\_s = (copysign.f64 #s(literal 1 binary64) angle)
                                          (FPCore (angle_s a_m b_m angle_m)
                                           :precision binary64
                                           (* angle_s (* (* (* (PI) angle_m) a_m) (* -0.011111111111111112 a_m))))
                                          \begin{array}{l}
                                          b_m = \left|b\right|
                                          \\
                                          a_m = \left|a\right|
                                          \\
                                          angle\_m = \left|angle\right|
                                          \\
                                          angle\_s = \mathsf{copysign}\left(1, angle\right)
                                          
                                          \\
                                          angle\_s \cdot \left(\left(\left(\mathsf{PI}\left(\right) \cdot angle\_m\right) \cdot a\_m\right) \cdot \left(-0.011111111111111112 \cdot a\_m\right)\right)
                                          \end{array}
                                          
                                          Derivation
                                          1. Initial program 51.5%

                                            \[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\mathsf{PI}\left(\right) \cdot \frac{angle}{180}\right) \]
                                          2. Add Preprocessing
                                          3. Taylor expanded in angle around 0

                                            \[\leadsto \color{blue}{\frac{1}{90} \cdot \left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
                                          4. Step-by-step derivation
                                            1. *-commutativeN/A

                                              \[\leadsto \color{blue}{\left(angle \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right) \cdot \frac{1}{90}} \]
                                            2. associate-*r*N/A

                                              \[\leadsto \color{blue}{angle \cdot \left(\left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \frac{1}{90}\right)} \]
                                            3. *-commutativeN/A

                                              \[\leadsto angle \cdot \color{blue}{\left(\frac{1}{90} \cdot \left(\mathsf{PI}\left(\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)\right)} \]
                                            4. associate-*r*N/A

                                              \[\leadsto angle \cdot \color{blue}{\left(\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)\right)} \]
                                            5. associate-*r*N/A

                                              \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                            6. lower-*.f64N/A

                                              \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left({b}^{2} - {a}^{2}\right)} \]
                                            7. lower-*.f64N/A

                                              \[\leadsto \color{blue}{\left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right)} \cdot \left({b}^{2} - {a}^{2}\right) \]
                                            8. lower-*.f64N/A

                                              \[\leadsto \left(angle \cdot \color{blue}{\left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)}\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                            9. lower-PI.f64N/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)\right) \cdot \left({b}^{2} - {a}^{2}\right) \]
                                            10. unpow2N/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{b \cdot b} - {a}^{2}\right) \]
                                            11. unpow2N/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(b \cdot b - \color{blue}{a \cdot a}\right) \]
                                            12. difference-of-squaresN/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                            13. lower-*.f64N/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \color{blue}{\left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                            14. lower-+.f64N/A

                                              \[\leadsto \left(angle \cdot \left(\frac{1}{90} \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\color{blue}{\left(b + a\right)} \cdot \left(b - a\right)\right) \]
                                            15. lower--.f6452.1

                                              \[\leadsto \left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \color{blue}{\left(b - a\right)}\right) \]
                                          5. Applied rewrites52.1%

                                            \[\leadsto \color{blue}{\left(angle \cdot \left(0.011111111111111112 \cdot \mathsf{PI}\left(\right)\right)\right) \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)} \]
                                          6. Taylor expanded in a around inf

                                            \[\leadsto \frac{-1}{90} \cdot \color{blue}{\left({a}^{2} \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)\right)} \]
                                          7. Step-by-step derivation
                                            1. Applied rewrites32.0%

                                              \[\leadsto \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot angle\right)} \]
                                            2. Step-by-step derivation
                                              1. Applied rewrites36.4%

                                                \[\leadsto \left(-0.011111111111111112 \cdot a\right) \cdot \left(a \cdot \color{blue}{\left(angle \cdot \mathsf{PI}\left(\right)\right)}\right) \]
                                              2. Final simplification36.4%

                                                \[\leadsto \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot a\right) \cdot \left(-0.011111111111111112 \cdot a\right) \]
                                              3. Add Preprocessing

                                              Reproduce

                                              ?
                                              herbie shell --seed 2024288 
                                              (FPCore (a b angle)
                                                :name "ab-angle->ABCF B"
                                                :precision binary64
                                                (* (* (* 2.0 (- (pow b 2.0) (pow a 2.0))) (sin (* (PI) (/ angle 180.0)))) (cos (* (PI) (/ angle 180.0)))))