ab-angle->ABCF B

Percentage Accurate: 54.4% → 66.8%
Time: 7.8s
Alternatives: 13
Speedup: 16.8×

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

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

Initial Program: 54.4% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \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: 66.8% accurate, 1.8× speedup?

\[\begin{array}{l} b_m = \left|b\right| \\ \begin{array}{l} t_0 := angle \cdot \mathsf{PI}\left(\right)\\ \mathbf{if}\;b\_m \leq 5 \cdot 10^{+177}:\\ \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\sin \left(t\_0 \cdot 0.005555555555555556\right) \cdot \left(b\_m - a\right)\right) \cdot \left(\cos \left(-0.005555555555555556 \cdot t\_0\right) \cdot 2\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\ \end{array} \end{array} \]
b_m = (fabs.f64 b)
(FPCore (a b_m angle)
 :precision binary64
 (let* ((t_0 (* angle (PI))))
   (if (<= b_m 5e+177)
     (*
      (+ a b_m)
      (*
       (* (sin (* t_0 0.005555555555555556)) (- b_m a))
       (* (cos (* -0.005555555555555556 t_0)) 2.0)))
     (* (+ a b_m) (* (* (* (- b_m a) (PI)) angle) 0.011111111111111112)))))
\begin{array}{l}
b_m = \left|b\right|

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < 5.0000000000000003e177

    1. Initial program 57.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 inf

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

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

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

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

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

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

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

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

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

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

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

          if 5.0000000000000003e177 < b

          1. Initial program 42.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 inf

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

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

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

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

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

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

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

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

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

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

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

              Alternative 2: 58.6% accurate, 1.0× speedup?

              \[\begin{array}{l} b_m = \left|b\right| \\ \begin{array}{l} t_0 := 2 \cdot \left({b\_m}^{2} - {a}^{2}\right)\\ t_1 := \left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot a\\ \mathbf{if}\;t\_0 \leq -1 \cdot 10^{-218}:\\ \;\;\;\;t\_1 \cdot \left(a \cdot -0.011111111111111112\right)\\ \mathbf{elif}\;t\_0 \leq \infty:\\ \;\;\;\;\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m \cdot b\_m\right)\right) \cdot angle\right) \cdot 0.011111111111111112\\ \mathbf{else}:\\ \;\;\;\;\left(-0.011111111111111112 \cdot t\_1\right) \cdot a\\ \end{array} \end{array} \]
              b_m = (fabs.f64 b)
              (FPCore (a b_m angle)
               :precision binary64
               (let* ((t_0 (* 2.0 (- (pow b_m 2.0) (pow a 2.0)))) (t_1 (* (* (PI) angle) a)))
                 (if (<= t_0 -1e-218)
                   (* t_1 (* a -0.011111111111111112))
                   (if (<= t_0 INFINITY)
                     (* (* (* (PI) (* b_m b_m)) angle) 0.011111111111111112)
                     (* (* -0.011111111111111112 t_1) a)))))
              \begin{array}{l}
              b_m = \left|b\right|
              
              \\
              \begin{array}{l}
              t_0 := 2 \cdot \left({b\_m}^{2} - {a}^{2}\right)\\
              t_1 := \left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot a\\
              \mathbf{if}\;t\_0 \leq -1 \cdot 10^{-218}:\\
              \;\;\;\;t\_1 \cdot \left(a \cdot -0.011111111111111112\right)\\
              
              \mathbf{elif}\;t\_0 \leq \infty:\\
              \;\;\;\;\left(\left(\mathsf{PI}\left(\right) \cdot \left(b\_m \cdot b\_m\right)\right) \cdot angle\right) \cdot 0.011111111111111112\\
              
              \mathbf{else}:\\
              \;\;\;\;\left(-0.011111111111111112 \cdot t\_1\right) \cdot a\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 3 regimes
              2. if (*.f64 #s(literal 2 binary64) (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))) < -1e-218

                1. Initial program 57.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. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \color{blue}{\left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\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 rewrites66.3%

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

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

                    if -1e-218 < (*.f64 #s(literal 2 binary64) (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64)))) < +inf.0

                    1. Initial program 60.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. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto \color{blue}{\left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\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 rewrites58.6%

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

                      if +inf.0 < (*.f64 #s(literal 2 binary64) (-.f64 (pow.f64 b #s(literal 2 binary64)) (pow.f64 a #s(literal 2 binary64))))

                      1. Initial program 0.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. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto \color{blue}{\left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\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 rewrites76.9%

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

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

                        Alternative 3: 64.7% accurate, 1.8× speedup?

                        \[\begin{array}{l} b_m = \left|b\right| \\ \begin{array}{l} t_0 := \left(0.005555555555555556 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\\ \mathbf{if}\;angle \leq 10^{-69}:\\ \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\cos t\_0 \cdot \left(a + b\_m\right)\right) \cdot \left(\left(b\_m - a\right) \cdot 2\right)\right) \cdot \sin t\_0\\ \end{array} \end{array} \]
                        b_m = (fabs.f64 b)
                        (FPCore (a b_m angle)
                         :precision binary64
                         (let* ((t_0 (* (* 0.005555555555555556 (PI)) angle)))
                           (if (<= angle 1e-69)
                             (* (+ a b_m) (* (* (* (- b_m a) (PI)) angle) 0.011111111111111112))
                             (* (* (* (cos t_0) (+ a b_m)) (* (- b_m a) 2.0)) (sin t_0)))))
                        \begin{array}{l}
                        b_m = \left|b\right|
                        
                        \\
                        \begin{array}{l}
                        t_0 := \left(0.005555555555555556 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\\
                        \mathbf{if}\;angle \leq 10^{-69}:\\
                        \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\
                        
                        \mathbf{else}:\\
                        \;\;\;\;\left(\left(\cos t\_0 \cdot \left(a + b\_m\right)\right) \cdot \left(\left(b\_m - a\right) \cdot 2\right)\right) \cdot \sin t\_0\\
                        
                        
                        \end{array}
                        \end{array}
                        
                        Derivation
                        1. Split input into 2 regimes
                        2. if angle < 9.9999999999999996e-70

                          1. Initial program 61.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 inf

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

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

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

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

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

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

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

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

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

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

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

                                if 9.9999999999999996e-70 < angle

                                1. Initial program 43.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 inf

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

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

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

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

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

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

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

                                Alternative 4: 64.7% accurate, 1.8× speedup?

                                \[\begin{array}{l} b_m = \left|b\right| \\ \begin{array}{l} t_0 := \left(\mathsf{PI}\left(\right) \cdot 0.005555555555555556\right) \cdot angle\\ \mathbf{if}\;angle \leq 10^{-69}:\\ \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\sin t\_0 \cdot \cos t\_0\right) \cdot \left(\left(\left(b\_m + a\right) \cdot \left(b\_m - a\right)\right) \cdot 2\right)\\ \end{array} \end{array} \]
                                b_m = (fabs.f64 b)
                                (FPCore (a b_m angle)
                                 :precision binary64
                                 (let* ((t_0 (* (* (PI) 0.005555555555555556) angle)))
                                   (if (<= angle 1e-69)
                                     (* (+ a b_m) (* (* (* (- b_m a) (PI)) angle) 0.011111111111111112))
                                     (* (* (sin t_0) (cos t_0)) (* (* (+ b_m a) (- b_m a)) 2.0)))))
                                \begin{array}{l}
                                b_m = \left|b\right|
                                
                                \\
                                \begin{array}{l}
                                t_0 := \left(\mathsf{PI}\left(\right) \cdot 0.005555555555555556\right) \cdot angle\\
                                \mathbf{if}\;angle \leq 10^{-69}:\\
                                \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\
                                
                                \mathbf{else}:\\
                                \;\;\;\;\left(\sin t\_0 \cdot \cos t\_0\right) \cdot \left(\left(\left(b\_m + a\right) \cdot \left(b\_m - a\right)\right) \cdot 2\right)\\
                                
                                
                                \end{array}
                                \end{array}
                                
                                Derivation
                                1. Split input into 2 regimes
                                2. if angle < 9.9999999999999996e-70

                                  1. Initial program 61.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 inf

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

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

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

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

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

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

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

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

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

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

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

                                        if 9.9999999999999996e-70 < angle

                                        1. Initial program 43.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 inf

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

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

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

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

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

                                          \[\leadsto \color{blue}{\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot 0.005555555555555556\right) \cdot angle\right) \cdot \cos \left(\left(\mathsf{PI}\left(\right) \cdot 0.005555555555555556\right) \cdot angle\right)\right) \cdot \left(\left(\left(b + a\right) \cdot \left(b - a\right)\right) \cdot 2\right)} \]
                                      4. Recombined 2 regimes into one program.
                                      5. Add Preprocessing

                                      Alternative 5: 60.7% accurate, 1.9× speedup?

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

                                        1. Initial program 62.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. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

                                          \[\leadsto \color{blue}{\left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\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 rewrites66.0%

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

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

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

                                            1. Initial program 49.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. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                              Alternative 6: 66.5% accurate, 3.2× speedup?

                                              \[\begin{array}{l} b_m = \left|b\right| \\ \begin{array}{l} t_0 := angle \cdot \mathsf{PI}\left(\right)\\ \mathbf{if}\;a \leq 9.5 \cdot 10^{+231}:\\ \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(b\_m - a\right) \cdot 2\right) \cdot \left(1 \cdot \sin \left(t\_0 \cdot 0.005555555555555556\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(a \cdot \left(t\_0 \cdot a\right)\right) \cdot -0.011111111111111112\\ \end{array} \end{array} \]
                                              b_m = (fabs.f64 b)
                                              (FPCore (a b_m angle)
                                               :precision binary64
                                               (let* ((t_0 (* angle (PI))))
                                                 (if (<= a 9.5e+231)
                                                   (*
                                                    (+ a b_m)
                                                    (* (* (- b_m a) 2.0) (* 1.0 (sin (* t_0 0.005555555555555556)))))
                                                   (* (* a (* t_0 a)) -0.011111111111111112))))
                                              \begin{array}{l}
                                              b_m = \left|b\right|
                                              
                                              \\
                                              \begin{array}{l}
                                              t_0 := angle \cdot \mathsf{PI}\left(\right)\\
                                              \mathbf{if}\;a \leq 9.5 \cdot 10^{+231}:\\
                                              \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(b\_m - a\right) \cdot 2\right) \cdot \left(1 \cdot \sin \left(t\_0 \cdot 0.005555555555555556\right)\right)\right)\\
                                              
                                              \mathbf{else}:\\
                                              \;\;\;\;\left(a \cdot \left(t\_0 \cdot a\right)\right) \cdot -0.011111111111111112\\
                                              
                                              
                                              \end{array}
                                              \end{array}
                                              
                                              Derivation
                                              1. Split input into 2 regimes
                                              2. if a < 9.5000000000000002e231

                                                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. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

                                                        \[\leadsto \left(a + b\right) \cdot \left(\left(\left(b - a\right) \cdot 2\right) \cdot \left(1 \cdot \sin \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot 0.005555555555555556\right)\right)\right) \]

                                                      if 9.5000000000000002e231 < a

                                                      1. Initial program 48.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. associate-*r*N/A

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

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

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

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

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

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

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

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

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

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

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

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

                                                        \[\leadsto \color{blue}{\left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\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 rewrites78.3%

                                                          \[\leadsto \left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right)\right) \cdot \color{blue}{-0.011111111111111112} \]
                                                      8. Recombined 2 regimes into one program.
                                                      9. Add Preprocessing

                                                      Alternative 7: 63.8% accurate, 3.2× speedup?

                                                      \[\begin{array}{l} b_m = \left|b\right| \\ \begin{array}{l} \mathbf{if}\;angle \leq 5.8 \cdot 10^{+156}:\\ \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 1\right) \cdot \left(\left(\left(b\_m + a\right) \cdot \left(b\_m - a\right)\right) \cdot 2\right)\\ \end{array} \end{array} \]
                                                      b_m = (fabs.f64 b)
                                                      (FPCore (a b_m angle)
                                                       :precision binary64
                                                       (if (<= angle 5.8e+156)
                                                         (* (+ a b_m) (* (* (* (- b_m a) (PI)) angle) 0.011111111111111112))
                                                         (*
                                                          (* (sin (* (* (PI) 0.005555555555555556) angle)) 1.0)
                                                          (* (* (+ b_m a) (- b_m a)) 2.0))))
                                                      \begin{array}{l}
                                                      b_m = \left|b\right|
                                                      
                                                      \\
                                                      \begin{array}{l}
                                                      \mathbf{if}\;angle \leq 5.8 \cdot 10^{+156}:\\
                                                      \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\
                                                      
                                                      \mathbf{else}:\\
                                                      \;\;\;\;\left(\sin \left(\left(\mathsf{PI}\left(\right) \cdot 0.005555555555555556\right) \cdot angle\right) \cdot 1\right) \cdot \left(\left(\left(b\_m + a\right) \cdot \left(b\_m - a\right)\right) \cdot 2\right)\\
                                                      
                                                      
                                                      \end{array}
                                                      \end{array}
                                                      
                                                      Derivation
                                                      1. Split input into 2 regimes
                                                      2. if angle < 5.80000000000000021e156

                                                        1. Initial program 59.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. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

                                                              if 5.80000000000000021e156 < angle

                                                              1. Initial program 28.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 inf

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

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

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

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

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

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

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

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

                                                              Alternative 8: 63.7% accurate, 3.2× speedup?

                                                              \[\begin{array}{l} b_m = \left|b\right| \\ \begin{array}{l} \mathbf{if}\;angle \leq 5.8 \cdot 10^{+156}:\\ \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\mathsf{fma}\left(-a, a, b\_m \cdot b\_m\right) \cdot 2\right) \cdot \sin \left(\left(0.005555555555555556 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\\ \end{array} \end{array} \]
                                                              b_m = (fabs.f64 b)
                                                              (FPCore (a b_m angle)
                                                               :precision binary64
                                                               (if (<= angle 5.8e+156)
                                                                 (* (+ a b_m) (* (* (* (- b_m a) (PI)) angle) 0.011111111111111112))
                                                                 (*
                                                                  (* (fma (- a) a (* b_m b_m)) 2.0)
                                                                  (sin (* (* 0.005555555555555556 (PI)) angle)))))
                                                              \begin{array}{l}
                                                              b_m = \left|b\right|
                                                              
                                                              \\
                                                              \begin{array}{l}
                                                              \mathbf{if}\;angle \leq 5.8 \cdot 10^{+156}:\\
                                                              \;\;\;\;\left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)\\
                                                              
                                                              \mathbf{else}:\\
                                                              \;\;\;\;\left(\mathsf{fma}\left(-a, a, b\_m \cdot b\_m\right) \cdot 2\right) \cdot \sin \left(\left(0.005555555555555556 \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right)\\
                                                              
                                                              
                                                              \end{array}
                                                              \end{array}
                                                              
                                                              Derivation
                                                              1. Split input into 2 regimes
                                                              2. if angle < 5.80000000000000021e156

                                                                1. Initial program 59.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. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

                                                                      if 5.80000000000000021e156 < angle

                                                                      1. Initial program 28.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 inf

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

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

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

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

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

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

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

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

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

                                                                        Alternative 9: 62.4% accurate, 16.8× speedup?

                                                                        \[\begin{array}{l} b_m = \left|b\right| \\ \left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right) \end{array} \]
                                                                        b_m = (fabs.f64 b)
                                                                        (FPCore (a b_m angle)
                                                                         :precision binary64
                                                                         (* (+ a b_m) (* (* (* (- b_m a) (PI)) angle) 0.011111111111111112)))
                                                                        \begin{array}{l}
                                                                        b_m = \left|b\right|
                                                                        
                                                                        \\
                                                                        \left(a + b\_m\right) \cdot \left(\left(\left(\left(b\_m - a\right) \cdot \mathsf{PI}\left(\right)\right) \cdot angle\right) \cdot 0.011111111111111112\right)
                                                                        \end{array}
                                                                        
                                                                        Derivation
                                                                        1. Initial program 56.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. Taylor expanded in angle around inf

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

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

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

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

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

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

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

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

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

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

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

                                                                              Alternative 10: 39.6% accurate, 21.6× speedup?

                                                                              \[\begin{array}{l} b_m = \left|b\right| \\ \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot a\right) \cdot \left(a \cdot -0.011111111111111112\right) \end{array} \]
                                                                              b_m = (fabs.f64 b)
                                                                              (FPCore (a b_m angle)
                                                                               :precision binary64
                                                                               (* (* (* (PI) angle) a) (* a -0.011111111111111112)))
                                                                              \begin{array}{l}
                                                                              b_m = \left|b\right|
                                                                              
                                                                              \\
                                                                              \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot a\right) \cdot \left(a \cdot -0.011111111111111112\right)
                                                                              \end{array}
                                                                              
                                                                              Derivation
                                                                              1. Initial program 56.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. Taylor expanded in angle around 0

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                                                \[\leadsto \color{blue}{\left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\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 rewrites42.2%

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

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

                                                                                  Alternative 11: 39.6% accurate, 21.6× speedup?

                                                                                  \[\begin{array}{l} b_m = \left|b\right| \\ \left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right)\right) \cdot -0.011111111111111112 \end{array} \]
                                                                                  b_m = (fabs.f64 b)
                                                                                  (FPCore (a b_m angle)
                                                                                   :precision binary64
                                                                                   (* (* a (* (* angle (PI)) a)) -0.011111111111111112))
                                                                                  \begin{array}{l}
                                                                                  b_m = \left|b\right|
                                                                                  
                                                                                  \\
                                                                                  \left(a \cdot \left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot a\right)\right) \cdot -0.011111111111111112
                                                                                  \end{array}
                                                                                  
                                                                                  Derivation
                                                                                  1. Initial program 56.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. Taylor expanded in angle around 0

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                                                    \[\leadsto \color{blue}{\left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\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 rewrites42.2%

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

                                                                                    Alternative 12: 39.6% accurate, 21.6× speedup?

                                                                                    \[\begin{array}{l} b_m = \left|b\right| \\ \left(-0.011111111111111112 \cdot \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot a\right)\right) \cdot a \end{array} \]
                                                                                    b_m = (fabs.f64 b)
                                                                                    (FPCore (a b_m angle)
                                                                                     :precision binary64
                                                                                     (* (* -0.011111111111111112 (* (* (PI) angle) a)) a))
                                                                                    \begin{array}{l}
                                                                                    b_m = \left|b\right|
                                                                                    
                                                                                    \\
                                                                                    \left(-0.011111111111111112 \cdot \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot a\right)\right) \cdot a
                                                                                    \end{array}
                                                                                    
                                                                                    Derivation
                                                                                    1. Initial program 56.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. Taylor expanded in angle around 0

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                                                      \[\leadsto \color{blue}{\left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\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 rewrites42.2%

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

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

                                                                                        Alternative 13: 36.2% accurate, 21.6× speedup?

                                                                                        \[\begin{array}{l} b_m = \left|b\right| \\ \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right) \end{array} \]
                                                                                        b_m = (fabs.f64 b)
                                                                                        (FPCore (a b_m angle)
                                                                                         :precision binary64
                                                                                         (* (* -0.011111111111111112 (* a a)) (* angle (PI))))
                                                                                        \begin{array}{l}
                                                                                        b_m = \left|b\right|
                                                                                        
                                                                                        \\
                                                                                        \left(-0.011111111111111112 \cdot \left(a \cdot a\right)\right) \cdot \left(angle \cdot \mathsf{PI}\left(\right)\right)
                                                                                        \end{array}
                                                                                        
                                                                                        Derivation
                                                                                        1. Initial program 56.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. Taylor expanded in angle around 0

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                                                          \[\leadsto \color{blue}{\left(\left(0.011111111111111112 \cdot angle\right) \cdot \mathsf{PI}\left(\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 rewrites42.2%

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

                                                                                              \[\leadsto \left(-0.011111111111111112 \cdot \left(\left(\mathsf{PI}\left(\right) \cdot angle\right) \cdot a\right)\right) \cdot a \]
                                                                                            2. Taylor expanded in a around 0

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

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

                                                                                              Reproduce

                                                                                              ?
                                                                                              herbie shell --seed 2024360 
                                                                                              (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)))))