ab-angle->ABCF A

Percentage Accurate: 79.9% → 79.8%
Time: 15.8s
Alternatives: 14
Speedup: 1.0×

Specification

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

\\
\begin{array}{l}
t_0 := \frac{angle}{180} \cdot \pi\\
{\left(a \cdot \sin t\_0\right)}^{2} + {\left(b \cdot \cos t\_0\right)}^{2}
\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 14 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: 79.9% accurate, 1.0× speedup?

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

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

Alternative 1: 79.8% accurate, 2.5× speedup?

\[\begin{array}{l} angle_m = \left|angle\right| \\ \begin{array}{l} \mathbf{if}\;\frac{angle\_m}{180} \leq 5000:\\ \;\;\;\;\mathsf{fma}\left(\left(\pi \cdot \pi\right) \cdot 3.08641975308642 \cdot 10^{-5}, \left(a \cdot angle\_m\right) \cdot \left(a \cdot angle\_m\right), b \cdot \left(b \cdot \left(0.5 + 0.5 \cdot \cos \left(2 \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.005555555555555556\right)\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\frac{1}{\mathsf{fma}\left(a, a \cdot \left(0.5 - 0.5 \cdot \cos \left(2 \cdot \left(\pi \cdot \left(angle\_m \cdot 0.005555555555555556\right)\right)\right)\right), b \cdot b\right)}}\\ \end{array} \end{array} \]
angle_m = (fabs.f64 angle)
(FPCore (a b angle_m)
 :precision binary64
 (if (<= (/ angle_m 180.0) 5000.0)
   (fma
    (* (* PI PI) 3.08641975308642e-5)
    (* (* a angle_m) (* a angle_m))
    (*
     b
     (*
      b
      (+ 0.5 (* 0.5 (cos (* 2.0 (* (* angle_m PI) 0.005555555555555556))))))))
   (/
    1.0
    (/
     1.0
     (fma
      a
      (*
       a
       (- 0.5 (* 0.5 (cos (* 2.0 (* PI (* angle_m 0.005555555555555556)))))))
      (* b b))))))
angle_m = fabs(angle);
double code(double a, double b, double angle_m) {
	double tmp;
	if ((angle_m / 180.0) <= 5000.0) {
		tmp = fma(((((double) M_PI) * ((double) M_PI)) * 3.08641975308642e-5), ((a * angle_m) * (a * angle_m)), (b * (b * (0.5 + (0.5 * cos((2.0 * ((angle_m * ((double) M_PI)) * 0.005555555555555556))))))));
	} else {
		tmp = 1.0 / (1.0 / fma(a, (a * (0.5 - (0.5 * cos((2.0 * (((double) M_PI) * (angle_m * 0.005555555555555556))))))), (b * b)));
	}
	return tmp;
}
angle_m = abs(angle)
function code(a, b, angle_m)
	tmp = 0.0
	if (Float64(angle_m / 180.0) <= 5000.0)
		tmp = fma(Float64(Float64(pi * pi) * 3.08641975308642e-5), Float64(Float64(a * angle_m) * Float64(a * angle_m)), Float64(b * Float64(b * Float64(0.5 + Float64(0.5 * cos(Float64(2.0 * Float64(Float64(angle_m * pi) * 0.005555555555555556))))))));
	else
		tmp = Float64(1.0 / Float64(1.0 / fma(a, Float64(a * Float64(0.5 - Float64(0.5 * cos(Float64(2.0 * Float64(pi * Float64(angle_m * 0.005555555555555556))))))), Float64(b * b))));
	end
	return tmp
end
angle_m = N[Abs[angle], $MachinePrecision]
code[a_, b_, angle$95$m_] := If[LessEqual[N[(angle$95$m / 180.0), $MachinePrecision], 5000.0], N[(N[(N[(Pi * Pi), $MachinePrecision] * 3.08641975308642e-5), $MachinePrecision] * N[(N[(a * angle$95$m), $MachinePrecision] * N[(a * angle$95$m), $MachinePrecision]), $MachinePrecision] + N[(b * N[(b * N[(0.5 + N[(0.5 * N[Cos[N[(2.0 * N[(N[(angle$95$m * Pi), $MachinePrecision] * 0.005555555555555556), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(1.0 / N[(a * N[(a * N[(0.5 - N[(0.5 * N[Cos[N[(2.0 * N[(Pi * N[(angle$95$m * 0.005555555555555556), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
angle_m = \left|angle\right|

\\
\begin{array}{l}
\mathbf{if}\;\frac{angle\_m}{180} \leq 5000:\\
\;\;\;\;\mathsf{fma}\left(\left(\pi \cdot \pi\right) \cdot 3.08641975308642 \cdot 10^{-5}, \left(a \cdot angle\_m\right) \cdot \left(a \cdot angle\_m\right), b \cdot \left(b \cdot \left(0.5 + 0.5 \cdot \cos \left(2 \cdot \left(\left(angle\_m \cdot \pi\right) \cdot 0.005555555555555556\right)\right)\right)\right)\right)\\

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


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

    1. Initial program 89.1%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto {\left(angle \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \left(\frac{1}{180} \cdot a\right)\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \mathsf{PI}\left(\right)\right)\right)}^{2} \]
      10. *-lowering-*.f6485.4

        \[\leadsto {\left(angle \cdot \left(\pi \cdot \color{blue}{\left(0.005555555555555556 \cdot a\right)}\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} \]
    5. Simplified85.4%

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(\left(\pi \cdot \pi\right) \cdot 3.08641975308642 \cdot 10^{-5}, \left(a \cdot angle\right) \cdot \left(a \cdot angle\right), b \cdot \left(b \cdot \left(0.5 + 0.5 \cdot \cos \left(2 \cdot \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right)\right)\right)\right)\right)} \]

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

    1. Initial program 59.4%

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{1}{\frac{1}{\mathsf{fma}\left(a, a \cdot \left(0.5 - 0.5 \cdot \cos \left(2 \cdot \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right)\right)\right), b \cdot b\right)}}} \]
    5. Recombined 2 regimes into one program.
    6. Add Preprocessing

    Alternative 2: 79.9% accurate, 0.7× speedup?

    \[\begin{array}{l} angle_m = \left|angle\right| \\ {\left(a \cdot \sin \left(\frac{angle\_m}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{1}{\frac{180}{angle\_m \cdot {\pi}^{0.8333333333333334}}} \cdot {\pi}^{0.16666666666666666}\right)\right)}^{2} \end{array} \]
    angle_m = (fabs.f64 angle)
    (FPCore (a b angle_m)
     :precision binary64
     (+
      (pow (* a (sin (* (/ angle_m 180.0) PI))) 2.0)
      (pow
       (*
        b
        (cos
         (*
          (/ 1.0 (/ 180.0 (* angle_m (pow PI 0.8333333333333334))))
          (pow PI 0.16666666666666666))))
       2.0)))
    angle_m = fabs(angle);
    double code(double a, double b, double angle_m) {
    	return pow((a * sin(((angle_m / 180.0) * ((double) M_PI)))), 2.0) + pow((b * cos(((1.0 / (180.0 / (angle_m * pow(((double) M_PI), 0.8333333333333334)))) * pow(((double) M_PI), 0.16666666666666666)))), 2.0);
    }
    
    angle_m = Math.abs(angle);
    public static double code(double a, double b, double angle_m) {
    	return Math.pow((a * Math.sin(((angle_m / 180.0) * Math.PI))), 2.0) + Math.pow((b * Math.cos(((1.0 / (180.0 / (angle_m * Math.pow(Math.PI, 0.8333333333333334)))) * Math.pow(Math.PI, 0.16666666666666666)))), 2.0);
    }
    
    angle_m = math.fabs(angle)
    def code(a, b, angle_m):
    	return math.pow((a * math.sin(((angle_m / 180.0) * math.pi))), 2.0) + math.pow((b * math.cos(((1.0 / (180.0 / (angle_m * math.pow(math.pi, 0.8333333333333334)))) * math.pow(math.pi, 0.16666666666666666)))), 2.0)
    
    angle_m = abs(angle)
    function code(a, b, angle_m)
    	return Float64((Float64(a * sin(Float64(Float64(angle_m / 180.0) * pi))) ^ 2.0) + (Float64(b * cos(Float64(Float64(1.0 / Float64(180.0 / Float64(angle_m * (pi ^ 0.8333333333333334)))) * (pi ^ 0.16666666666666666)))) ^ 2.0))
    end
    
    angle_m = abs(angle);
    function tmp = code(a, b, angle_m)
    	tmp = ((a * sin(((angle_m / 180.0) * pi))) ^ 2.0) + ((b * cos(((1.0 / (180.0 / (angle_m * (pi ^ 0.8333333333333334)))) * (pi ^ 0.16666666666666666)))) ^ 2.0);
    end
    
    angle_m = N[Abs[angle], $MachinePrecision]
    code[a_, b_, angle$95$m_] := N[(N[Power[N[(a * N[Sin[N[(N[(angle$95$m / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(b * N[Cos[N[(N[(1.0 / N[(180.0 / N[(angle$95$m * N[Power[Pi, 0.8333333333333334], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Power[Pi, 0.16666666666666666], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    angle_m = \left|angle\right|
    
    \\
    {\left(a \cdot \sin \left(\frac{angle\_m}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{1}{\frac{180}{angle\_m \cdot {\pi}^{0.8333333333333334}}} \cdot {\pi}^{0.16666666666666666}\right)\right)}^{2}
    \end{array}
    
    Derivation
    1. Initial program 82.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto {\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \color{blue}{\left(\left(\left(angle \cdot 0.005555555555555556\right) \cdot \sqrt{\pi}\right) \cdot \sqrt{\pi}\right)}\right)}^{2} \]
    7. Step-by-step derivation
      1. metadata-evalN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto {\left(a \cdot \sin \left(\frac{angle}{180} \cdot \mathsf{PI}\left(\right)\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{\sqrt{\mathsf{PI}\left(\right)}}{-1} \cdot \frac{\sqrt{\mathsf{PI}\left(\right)}}{\color{blue}{\frac{\mathsf{neg}\left(180\right)}{angle}}}\right)\right)}^{2} \]
      19. metadata-eval82.3

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

      \[\leadsto {\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \color{blue}{\left(\frac{\sqrt{\pi}}{-1} \cdot \frac{\sqrt{\pi}}{\frac{-180}{angle}}\right)}\right)}^{2} \]
    9. Step-by-step derivation
      1. associate-/r/N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto {\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \color{blue}{\left(\frac{1}{\frac{180}{angle \cdot {\pi}^{0.8333333333333334}}} \cdot {\pi}^{0.16666666666666666}\right)}\right)}^{2} \]
    11. Add Preprocessing

    Alternative 3: 79.8% accurate, 1.0× speedup?

    \[\begin{array}{l} angle_m = \left|angle\right| \\ {\left(a \cdot \sin \left(\pi \cdot \frac{1}{\frac{180}{angle\_m}}\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle\_m \cdot \pi}{180}\right)\right)}^{2} \end{array} \]
    angle_m = (fabs.f64 angle)
    (FPCore (a b angle_m)
     :precision binary64
     (+
      (pow (* a (sin (* PI (/ 1.0 (/ 180.0 angle_m))))) 2.0)
      (pow (* b (cos (/ (* angle_m PI) 180.0))) 2.0)))
    angle_m = fabs(angle);
    double code(double a, double b, double angle_m) {
    	return pow((a * sin((((double) M_PI) * (1.0 / (180.0 / angle_m))))), 2.0) + pow((b * cos(((angle_m * ((double) M_PI)) / 180.0))), 2.0);
    }
    
    angle_m = Math.abs(angle);
    public static double code(double a, double b, double angle_m) {
    	return Math.pow((a * Math.sin((Math.PI * (1.0 / (180.0 / angle_m))))), 2.0) + Math.pow((b * Math.cos(((angle_m * Math.PI) / 180.0))), 2.0);
    }
    
    angle_m = math.fabs(angle)
    def code(a, b, angle_m):
    	return math.pow((a * math.sin((math.pi * (1.0 / (180.0 / angle_m))))), 2.0) + math.pow((b * math.cos(((angle_m * math.pi) / 180.0))), 2.0)
    
    angle_m = abs(angle)
    function code(a, b, angle_m)
    	return Float64((Float64(a * sin(Float64(pi * Float64(1.0 / Float64(180.0 / angle_m))))) ^ 2.0) + (Float64(b * cos(Float64(Float64(angle_m * pi) / 180.0))) ^ 2.0))
    end
    
    angle_m = abs(angle);
    function tmp = code(a, b, angle_m)
    	tmp = ((a * sin((pi * (1.0 / (180.0 / angle_m))))) ^ 2.0) + ((b * cos(((angle_m * pi) / 180.0))) ^ 2.0);
    end
    
    angle_m = N[Abs[angle], $MachinePrecision]
    code[a_, b_, angle$95$m_] := N[(N[Power[N[(a * N[Sin[N[(Pi * N[(1.0 / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(b * N[Cos[N[(N[(angle$95$m * Pi), $MachinePrecision] / 180.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    angle_m = \left|angle\right|
    
    \\
    {\left(a \cdot \sin \left(\pi \cdot \frac{1}{\frac{180}{angle\_m}}\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle\_m \cdot \pi}{180}\right)\right)}^{2}
    \end{array}
    
    Derivation
    1. Initial program 82.3%

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

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

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

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

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

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

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

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

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

      \[\leadsto {\left(a \cdot \sin \left(\color{blue}{\frac{1}{\frac{180}{angle}}} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle \cdot \pi}{180}\right)\right)}^{2} \]
    7. Final simplification82.3%

      \[\leadsto {\left(a \cdot \sin \left(\pi \cdot \frac{1}{\frac{180}{angle}}\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle \cdot \pi}{180}\right)\right)}^{2} \]
    8. Add Preprocessing

    Alternative 4: 79.8% accurate, 1.0× speedup?

    \[\begin{array}{l} angle_m = \left|angle\right| \\ {\left(b \cdot \cos \left(\frac{angle\_m \cdot \pi}{180}\right)\right)}^{2} + {\left(a \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)}^{2} \end{array} \]
    angle_m = (fabs.f64 angle)
    (FPCore (a b angle_m)
     :precision binary64
     (+
      (pow (* b (cos (/ (* angle_m PI) 180.0))) 2.0)
      (pow (* a (sin (/ PI (/ 180.0 angle_m)))) 2.0)))
    angle_m = fabs(angle);
    double code(double a, double b, double angle_m) {
    	return pow((b * cos(((angle_m * ((double) M_PI)) / 180.0))), 2.0) + pow((a * sin((((double) M_PI) / (180.0 / angle_m)))), 2.0);
    }
    
    angle_m = Math.abs(angle);
    public static double code(double a, double b, double angle_m) {
    	return Math.pow((b * Math.cos(((angle_m * Math.PI) / 180.0))), 2.0) + Math.pow((a * Math.sin((Math.PI / (180.0 / angle_m)))), 2.0);
    }
    
    angle_m = math.fabs(angle)
    def code(a, b, angle_m):
    	return math.pow((b * math.cos(((angle_m * math.pi) / 180.0))), 2.0) + math.pow((a * math.sin((math.pi / (180.0 / angle_m)))), 2.0)
    
    angle_m = abs(angle)
    function code(a, b, angle_m)
    	return Float64((Float64(b * cos(Float64(Float64(angle_m * pi) / 180.0))) ^ 2.0) + (Float64(a * sin(Float64(pi / Float64(180.0 / angle_m)))) ^ 2.0))
    end
    
    angle_m = abs(angle);
    function tmp = code(a, b, angle_m)
    	tmp = ((b * cos(((angle_m * pi) / 180.0))) ^ 2.0) + ((a * sin((pi / (180.0 / angle_m)))) ^ 2.0);
    end
    
    angle_m = N[Abs[angle], $MachinePrecision]
    code[a_, b_, angle$95$m_] := N[(N[Power[N[(b * N[Cos[N[(N[(angle$95$m * Pi), $MachinePrecision] / 180.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(a * N[Sin[N[(Pi / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    angle_m = \left|angle\right|
    
    \\
    {\left(b \cdot \cos \left(\frac{angle\_m \cdot \pi}{180}\right)\right)}^{2} + {\left(a \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)}^{2}
    \end{array}
    
    Derivation
    1. Initial program 82.3%

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto {\left(a \cdot \sin \color{blue}{\left(\frac{\pi}{\frac{180}{angle}}\right)}\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle \cdot \pi}{180}\right)\right)}^{2} \]
    7. Final simplification82.3%

      \[\leadsto {\left(b \cdot \cos \left(\frac{angle \cdot \pi}{180}\right)\right)}^{2} + {\left(a \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right)}^{2} \]
    8. Add Preprocessing

    Alternative 5: 79.9% accurate, 1.0× speedup?

    \[\begin{array}{l} angle_m = \left|angle\right| \\ {\left(a \cdot \sin \left(\frac{angle\_m}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle\_m \cdot \pi}{180}\right)\right)}^{2} \end{array} \]
    angle_m = (fabs.f64 angle)
    (FPCore (a b angle_m)
     :precision binary64
     (+
      (pow (* a (sin (* (/ angle_m 180.0) PI))) 2.0)
      (pow (* b (cos (/ (* angle_m PI) 180.0))) 2.0)))
    angle_m = fabs(angle);
    double code(double a, double b, double angle_m) {
    	return pow((a * sin(((angle_m / 180.0) * ((double) M_PI)))), 2.0) + pow((b * cos(((angle_m * ((double) M_PI)) / 180.0))), 2.0);
    }
    
    angle_m = Math.abs(angle);
    public static double code(double a, double b, double angle_m) {
    	return Math.pow((a * Math.sin(((angle_m / 180.0) * Math.PI))), 2.0) + Math.pow((b * Math.cos(((angle_m * Math.PI) / 180.0))), 2.0);
    }
    
    angle_m = math.fabs(angle)
    def code(a, b, angle_m):
    	return math.pow((a * math.sin(((angle_m / 180.0) * math.pi))), 2.0) + math.pow((b * math.cos(((angle_m * math.pi) / 180.0))), 2.0)
    
    angle_m = abs(angle)
    function code(a, b, angle_m)
    	return Float64((Float64(a * sin(Float64(Float64(angle_m / 180.0) * pi))) ^ 2.0) + (Float64(b * cos(Float64(Float64(angle_m * pi) / 180.0))) ^ 2.0))
    end
    
    angle_m = abs(angle);
    function tmp = code(a, b, angle_m)
    	tmp = ((a * sin(((angle_m / 180.0) * pi))) ^ 2.0) + ((b * cos(((angle_m * pi) / 180.0))) ^ 2.0);
    end
    
    angle_m = N[Abs[angle], $MachinePrecision]
    code[a_, b_, angle$95$m_] := N[(N[Power[N[(a * N[Sin[N[(N[(angle$95$m / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(b * N[Cos[N[(N[(angle$95$m * Pi), $MachinePrecision] / 180.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    angle_m = \left|angle\right|
    
    \\
    {\left(a \cdot \sin \left(\frac{angle\_m}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle\_m \cdot \pi}{180}\right)\right)}^{2}
    \end{array}
    
    Derivation
    1. Initial program 82.3%

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

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

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

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

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

      \[\leadsto {\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \color{blue}{\left(\frac{angle \cdot \pi}{180}\right)}\right)}^{2} \]
    5. Add Preprocessing

    Alternative 6: 79.9% accurate, 1.0× speedup?

    \[\begin{array}{l} angle_m = \left|angle\right| \\ \begin{array}{l} t_0 := \frac{angle\_m}{180} \cdot \pi\\ {\left(a \cdot \sin t\_0\right)}^{2} + {\left(b \cdot \cos t\_0\right)}^{2} \end{array} \end{array} \]
    angle_m = (fabs.f64 angle)
    (FPCore (a b angle_m)
     :precision binary64
     (let* ((t_0 (* (/ angle_m 180.0) PI)))
       (+ (pow (* a (sin t_0)) 2.0) (pow (* b (cos t_0)) 2.0))))
    angle_m = fabs(angle);
    double code(double a, double b, double angle_m) {
    	double t_0 = (angle_m / 180.0) * ((double) M_PI);
    	return pow((a * sin(t_0)), 2.0) + pow((b * cos(t_0)), 2.0);
    }
    
    angle_m = Math.abs(angle);
    public static double code(double a, double b, double angle_m) {
    	double t_0 = (angle_m / 180.0) * Math.PI;
    	return Math.pow((a * Math.sin(t_0)), 2.0) + Math.pow((b * Math.cos(t_0)), 2.0);
    }
    
    angle_m = math.fabs(angle)
    def code(a, b, angle_m):
    	t_0 = (angle_m / 180.0) * math.pi
    	return math.pow((a * math.sin(t_0)), 2.0) + math.pow((b * math.cos(t_0)), 2.0)
    
    angle_m = abs(angle)
    function code(a, b, angle_m)
    	t_0 = Float64(Float64(angle_m / 180.0) * pi)
    	return Float64((Float64(a * sin(t_0)) ^ 2.0) + (Float64(b * cos(t_0)) ^ 2.0))
    end
    
    angle_m = abs(angle);
    function tmp = code(a, b, angle_m)
    	t_0 = (angle_m / 180.0) * pi;
    	tmp = ((a * sin(t_0)) ^ 2.0) + ((b * cos(t_0)) ^ 2.0);
    end
    
    angle_m = N[Abs[angle], $MachinePrecision]
    code[a_, b_, angle$95$m_] := Block[{t$95$0 = N[(N[(angle$95$m / 180.0), $MachinePrecision] * Pi), $MachinePrecision]}, N[(N[Power[N[(a * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(b * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]]
    
    \begin{array}{l}
    angle_m = \left|angle\right|
    
    \\
    \begin{array}{l}
    t_0 := \frac{angle\_m}{180} \cdot \pi\\
    {\left(a \cdot \sin t\_0\right)}^{2} + {\left(b \cdot \cos t\_0\right)}^{2}
    \end{array}
    \end{array}
    
    Derivation
    1. Initial program 82.3%

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

    Alternative 7: 79.8% accurate, 1.3× speedup?

    \[\begin{array}{l} angle_m = \left|angle\right| \\ {\left(a \cdot \sin \left(\pi \cdot \frac{1}{\frac{180}{angle\_m}}\right)\right)}^{2} + {b}^{2} \end{array} \]
    angle_m = (fabs.f64 angle)
    (FPCore (a b angle_m)
     :precision binary64
     (+ (pow (* a (sin (* PI (/ 1.0 (/ 180.0 angle_m))))) 2.0) (pow b 2.0)))
    angle_m = fabs(angle);
    double code(double a, double b, double angle_m) {
    	return pow((a * sin((((double) M_PI) * (1.0 / (180.0 / angle_m))))), 2.0) + pow(b, 2.0);
    }
    
    angle_m = Math.abs(angle);
    public static double code(double a, double b, double angle_m) {
    	return Math.pow((a * Math.sin((Math.PI * (1.0 / (180.0 / angle_m))))), 2.0) + Math.pow(b, 2.0);
    }
    
    angle_m = math.fabs(angle)
    def code(a, b, angle_m):
    	return math.pow((a * math.sin((math.pi * (1.0 / (180.0 / angle_m))))), 2.0) + math.pow(b, 2.0)
    
    angle_m = abs(angle)
    function code(a, b, angle_m)
    	return Float64((Float64(a * sin(Float64(pi * Float64(1.0 / Float64(180.0 / angle_m))))) ^ 2.0) + (b ^ 2.0))
    end
    
    angle_m = abs(angle);
    function tmp = code(a, b, angle_m)
    	tmp = ((a * sin((pi * (1.0 / (180.0 / angle_m))))) ^ 2.0) + (b ^ 2.0);
    end
    
    angle_m = N[Abs[angle], $MachinePrecision]
    code[a_, b_, angle$95$m_] := N[(N[Power[N[(a * N[Sin[N[(Pi * N[(1.0 / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[b, 2.0], $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    angle_m = \left|angle\right|
    
    \\
    {\left(a \cdot \sin \left(\pi \cdot \frac{1}{\frac{180}{angle\_m}}\right)\right)}^{2} + {b}^{2}
    \end{array}
    
    Derivation
    1. Initial program 82.3%

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto {\left(a \cdot \sin \left(\frac{1}{\frac{180}{angle}} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \color{blue}{1}\right)}^{2} \]
      2. Final simplification82.0%

        \[\leadsto {\left(a \cdot \sin \left(\pi \cdot \frac{1}{\frac{180}{angle}}\right)\right)}^{2} + {b}^{2} \]
      3. Add Preprocessing

      Alternative 8: 79.8% accurate, 1.3× speedup?

      \[\begin{array}{l} angle_m = \left|angle\right| \\ {\left(a \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)}^{2} + {b}^{2} \end{array} \]
      angle_m = (fabs.f64 angle)
      (FPCore (a b angle_m)
       :precision binary64
       (+ (pow (* a (sin (/ PI (/ 180.0 angle_m)))) 2.0) (pow b 2.0)))
      angle_m = fabs(angle);
      double code(double a, double b, double angle_m) {
      	return pow((a * sin((((double) M_PI) / (180.0 / angle_m)))), 2.0) + pow(b, 2.0);
      }
      
      angle_m = Math.abs(angle);
      public static double code(double a, double b, double angle_m) {
      	return Math.pow((a * Math.sin((Math.PI / (180.0 / angle_m)))), 2.0) + Math.pow(b, 2.0);
      }
      
      angle_m = math.fabs(angle)
      def code(a, b, angle_m):
      	return math.pow((a * math.sin((math.pi / (180.0 / angle_m)))), 2.0) + math.pow(b, 2.0)
      
      angle_m = abs(angle)
      function code(a, b, angle_m)
      	return Float64((Float64(a * sin(Float64(pi / Float64(180.0 / angle_m)))) ^ 2.0) + (b ^ 2.0))
      end
      
      angle_m = abs(angle);
      function tmp = code(a, b, angle_m)
      	tmp = ((a * sin((pi / (180.0 / angle_m)))) ^ 2.0) + (b ^ 2.0);
      end
      
      angle_m = N[Abs[angle], $MachinePrecision]
      code[a_, b_, angle$95$m_] := N[(N[Power[N[(a * N[Sin[N[(Pi / N[(180.0 / angle$95$m), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[b, 2.0], $MachinePrecision]), $MachinePrecision]
      
      \begin{array}{l}
      angle_m = \left|angle\right|
      
      \\
      {\left(a \cdot \sin \left(\frac{\pi}{\frac{180}{angle\_m}}\right)\right)}^{2} + {b}^{2}
      \end{array}
      
      Derivation
      1. Initial program 82.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

            \[\leadsto {\left(a \cdot \sin \left(\frac{\pi}{\color{blue}{\frac{180}{angle}}}\right)\right)}^{2} + {\left(b \cdot 1\right)}^{2} \]
        3. Applied egg-rr82.0%

          \[\leadsto {\left(a \cdot \sin \color{blue}{\left(\frac{\pi}{\frac{180}{angle}}\right)}\right)}^{2} + {\left(b \cdot 1\right)}^{2} \]
        4. Final simplification82.0%

          \[\leadsto {\left(a \cdot \sin \left(\frac{\pi}{\frac{180}{angle}}\right)\right)}^{2} + {b}^{2} \]
        5. Add Preprocessing

        Alternative 9: 79.8% accurate, 1.9× speedup?

        \[\begin{array}{l} angle_m = \left|angle\right| \\ {\left(a \cdot \sin \left(\frac{angle\_m}{180} \cdot \pi\right)\right)}^{2} + b \cdot b \end{array} \]
        angle_m = (fabs.f64 angle)
        (FPCore (a b angle_m)
         :precision binary64
         (+ (pow (* a (sin (* (/ angle_m 180.0) PI))) 2.0) (* b b)))
        angle_m = fabs(angle);
        double code(double a, double b, double angle_m) {
        	return pow((a * sin(((angle_m / 180.0) * ((double) M_PI)))), 2.0) + (b * b);
        }
        
        angle_m = Math.abs(angle);
        public static double code(double a, double b, double angle_m) {
        	return Math.pow((a * Math.sin(((angle_m / 180.0) * Math.PI))), 2.0) + (b * b);
        }
        
        angle_m = math.fabs(angle)
        def code(a, b, angle_m):
        	return math.pow((a * math.sin(((angle_m / 180.0) * math.pi))), 2.0) + (b * b)
        
        angle_m = abs(angle)
        function code(a, b, angle_m)
        	return Float64((Float64(a * sin(Float64(Float64(angle_m / 180.0) * pi))) ^ 2.0) + Float64(b * b))
        end
        
        angle_m = abs(angle);
        function tmp = code(a, b, angle_m)
        	tmp = ((a * sin(((angle_m / 180.0) * pi))) ^ 2.0) + (b * b);
        end
        
        angle_m = N[Abs[angle], $MachinePrecision]
        code[a_, b_, angle$95$m_] := N[(N[Power[N[(a * N[Sin[N[(N[(angle$95$m / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[(b * b), $MachinePrecision]), $MachinePrecision]
        
        \begin{array}{l}
        angle_m = \left|angle\right|
        
        \\
        {\left(a \cdot \sin \left(\frac{angle\_m}{180} \cdot \pi\right)\right)}^{2} + b \cdot b
        \end{array}
        
        Derivation
        1. Initial program 82.3%

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

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

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

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

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

              \[\leadsto {\left(a \cdot \sin \left(\frac{angle}{180} \cdot \mathsf{PI}\left(\right)\right)\right)}^{2} + \color{blue}{b} \cdot \left(b \cdot 1\right) \]
            4. *-rgt-identity82.0

              \[\leadsto {\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + b \cdot \color{blue}{b} \]
          3. Applied egg-rr82.0%

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

          Alternative 10: 66.6% accurate, 3.1× speedup?

          \[\begin{array}{l} angle_m = \left|angle\right| \\ \begin{array}{l} \mathbf{if}\;a \leq 2.95 \cdot 10^{+122}:\\ \;\;\;\;\mathsf{fma}\left(0.5 - 0.5 \cdot \cos \left(2 \cdot \left(\pi \cdot \left(angle\_m \cdot 0.005555555555555556\right)\right)\right), a \cdot a, b \cdot b\right)\\ \mathbf{else}:\\ \;\;\;\;\left(a \cdot angle\_m\right) \cdot \left(angle\_m \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right)\\ \end{array} \end{array} \]
          angle_m = (fabs.f64 angle)
          (FPCore (a b angle_m)
           :precision binary64
           (if (<= a 2.95e+122)
             (fma
              (- 0.5 (* 0.5 (cos (* 2.0 (* PI (* angle_m 0.005555555555555556))))))
              (* a a)
              (* b b))
             (* (* a angle_m) (* angle_m (* a (* PI (* PI 3.08641975308642e-5)))))))
          angle_m = fabs(angle);
          double code(double a, double b, double angle_m) {
          	double tmp;
          	if (a <= 2.95e+122) {
          		tmp = fma((0.5 - (0.5 * cos((2.0 * (((double) M_PI) * (angle_m * 0.005555555555555556)))))), (a * a), (b * b));
          	} else {
          		tmp = (a * angle_m) * (angle_m * (a * (((double) M_PI) * (((double) M_PI) * 3.08641975308642e-5))));
          	}
          	return tmp;
          }
          
          angle_m = abs(angle)
          function code(a, b, angle_m)
          	tmp = 0.0
          	if (a <= 2.95e+122)
          		tmp = fma(Float64(0.5 - Float64(0.5 * cos(Float64(2.0 * Float64(pi * Float64(angle_m * 0.005555555555555556)))))), Float64(a * a), Float64(b * b));
          	else
          		tmp = Float64(Float64(a * angle_m) * Float64(angle_m * Float64(a * Float64(pi * Float64(pi * 3.08641975308642e-5)))));
          	end
          	return tmp
          end
          
          angle_m = N[Abs[angle], $MachinePrecision]
          code[a_, b_, angle$95$m_] := If[LessEqual[a, 2.95e+122], N[(N[(0.5 - N[(0.5 * N[Cos[N[(2.0 * N[(Pi * N[(angle$95$m * 0.005555555555555556), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(a * a), $MachinePrecision] + N[(b * b), $MachinePrecision]), $MachinePrecision], N[(N[(a * angle$95$m), $MachinePrecision] * N[(angle$95$m * N[(a * N[(Pi * N[(Pi * 3.08641975308642e-5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
          
          \begin{array}{l}
          angle_m = \left|angle\right|
          
          \\
          \begin{array}{l}
          \mathbf{if}\;a \leq 2.95 \cdot 10^{+122}:\\
          \;\;\;\;\mathsf{fma}\left(0.5 - 0.5 \cdot \cos \left(2 \cdot \left(\pi \cdot \left(angle\_m \cdot 0.005555555555555556\right)\right)\right), a \cdot a, b \cdot b\right)\\
          
          \mathbf{else}:\\
          \;\;\;\;\left(a \cdot angle\_m\right) \cdot \left(angle\_m \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right)\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 2 regimes
          2. if a < 2.95000000000000016e122

            1. Initial program 79.9%

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

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

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

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

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

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

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

              if 2.95000000000000016e122 < a

              1. Initial program 96.9%

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto {\left(angle \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \left(\frac{1}{180} \cdot a\right)\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \mathsf{PI}\left(\right)\right)\right)}^{2} \]
                10. *-lowering-*.f6496.9

                  \[\leadsto {\left(angle \cdot \left(\pi \cdot \color{blue}{\left(0.005555555555555556 \cdot a\right)}\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} \]
              5. Simplified96.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{32400}\right)\right) \]
                14. *-lowering-*.f64N/A

                  \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{32400}\right)\right) \]
                15. PI-lowering-PI.f64N/A

                  \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{1}{32400}\right)\right) \]
                16. PI-lowering-PI.f6456.2

                  \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\pi \cdot \color{blue}{\pi}\right) \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \]
              8. Simplified56.2%

                \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\pi \cdot \pi\right) \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)} \]
              9. Step-by-step derivation
                1. pow2N/A

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)}\right) \cdot {a}^{2}\right) \]
                13. PI-lowering-PI.f64N/A

                  \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{1}{32400}\right)\right) \cdot {a}^{2}\right) \]
                14. pow2N/A

                  \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right) \cdot \color{blue}{\left(a \cdot a\right)}\right) \]
                15. *-lowering-*.f6465.4

                  \[\leadsto angle \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \cdot \color{blue}{\left(a \cdot a\right)}\right) \]
              10. Applied egg-rr65.4%

                \[\leadsto \color{blue}{angle \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \cdot \left(a \cdot a\right)\right)} \]
              11. Step-by-step derivation
                1. *-commutativeN/A

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

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

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

                  \[\leadsto \color{blue}{\left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right) \cdot a\right) \cdot \left(a \cdot angle\right)} \]
                5. associate-*l*N/A

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

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

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

                  \[\leadsto \left(angle \cdot \color{blue}{\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right)\right)}\right) \cdot \left(a \cdot angle\right) \]
                9. *-lowering-*.f64N/A

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

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

                  \[\leadsto \left(angle \cdot \left(a \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right)\right)\right) \cdot \left(a \cdot angle\right) \]
                12. *-lowering-*.f64N/A

                  \[\leadsto \left(angle \cdot \left(a \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)}\right)\right)\right) \cdot \left(a \cdot angle\right) \]
                13. PI-lowering-PI.f64N/A

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

                  \[\leadsto \left(angle \cdot \left(a \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right)\right)\right) \cdot \color{blue}{\left(angle \cdot a\right)} \]
                15. *-lowering-*.f6478.5

                  \[\leadsto \left(angle \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right) \cdot \color{blue}{\left(angle \cdot a\right)} \]
              12. Applied egg-rr78.5%

                \[\leadsto \color{blue}{\left(angle \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right) \cdot \left(angle \cdot a\right)} \]
            5. Recombined 2 regimes into one program.
            6. Final simplification70.3%

              \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 2.95 \cdot 10^{+122}:\\ \;\;\;\;\mathsf{fma}\left(0.5 - 0.5 \cdot \cos \left(2 \cdot \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right)\right), a \cdot a, b \cdot b\right)\\ \mathbf{else}:\\ \;\;\;\;\left(a \cdot angle\right) \cdot \left(angle \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right)\\ \end{array} \]
            7. Add Preprocessing

            Alternative 11: 66.6% accurate, 3.1× speedup?

            \[\begin{array}{l} angle_m = \left|angle\right| \\ \begin{array}{l} \mathbf{if}\;a \leq 3.1 \cdot 10^{+122}:\\ \;\;\;\;\mathsf{fma}\left(0.5 - 0.5 \cdot \cos \left(2 \cdot \left(angle\_m \cdot \left(\pi \cdot 0.005555555555555556\right)\right)\right), a \cdot a, b \cdot b\right)\\ \mathbf{else}:\\ \;\;\;\;\left(a \cdot angle\_m\right) \cdot \left(angle\_m \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right)\\ \end{array} \end{array} \]
            angle_m = (fabs.f64 angle)
            (FPCore (a b angle_m)
             :precision binary64
             (if (<= a 3.1e+122)
               (fma
                (- 0.5 (* 0.5 (cos (* 2.0 (* angle_m (* PI 0.005555555555555556))))))
                (* a a)
                (* b b))
               (* (* a angle_m) (* angle_m (* a (* PI (* PI 3.08641975308642e-5)))))))
            angle_m = fabs(angle);
            double code(double a, double b, double angle_m) {
            	double tmp;
            	if (a <= 3.1e+122) {
            		tmp = fma((0.5 - (0.5 * cos((2.0 * (angle_m * (((double) M_PI) * 0.005555555555555556)))))), (a * a), (b * b));
            	} else {
            		tmp = (a * angle_m) * (angle_m * (a * (((double) M_PI) * (((double) M_PI) * 3.08641975308642e-5))));
            	}
            	return tmp;
            }
            
            angle_m = abs(angle)
            function code(a, b, angle_m)
            	tmp = 0.0
            	if (a <= 3.1e+122)
            		tmp = fma(Float64(0.5 - Float64(0.5 * cos(Float64(2.0 * Float64(angle_m * Float64(pi * 0.005555555555555556)))))), Float64(a * a), Float64(b * b));
            	else
            		tmp = Float64(Float64(a * angle_m) * Float64(angle_m * Float64(a * Float64(pi * Float64(pi * 3.08641975308642e-5)))));
            	end
            	return tmp
            end
            
            angle_m = N[Abs[angle], $MachinePrecision]
            code[a_, b_, angle$95$m_] := If[LessEqual[a, 3.1e+122], N[(N[(0.5 - N[(0.5 * N[Cos[N[(2.0 * N[(angle$95$m * N[(Pi * 0.005555555555555556), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(a * a), $MachinePrecision] + N[(b * b), $MachinePrecision]), $MachinePrecision], N[(N[(a * angle$95$m), $MachinePrecision] * N[(angle$95$m * N[(a * N[(Pi * N[(Pi * 3.08641975308642e-5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
            
            \begin{array}{l}
            angle_m = \left|angle\right|
            
            \\
            \begin{array}{l}
            \mathbf{if}\;a \leq 3.1 \cdot 10^{+122}:\\
            \;\;\;\;\mathsf{fma}\left(0.5 - 0.5 \cdot \cos \left(2 \cdot \left(angle\_m \cdot \left(\pi \cdot 0.005555555555555556\right)\right)\right), a \cdot a, b \cdot b\right)\\
            
            \mathbf{else}:\\
            \;\;\;\;\left(a \cdot angle\_m\right) \cdot \left(angle\_m \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right)\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 2 regimes
            2. if a < 3.09999999999999999e122

              1. Initial program 79.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                if 3.09999999999999999e122 < a

                1. Initial program 96.9%

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto {\left(angle \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \left(\frac{1}{180} \cdot a\right)\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \mathsf{PI}\left(\right)\right)\right)}^{2} \]
                  10. *-lowering-*.f6496.9

                    \[\leadsto {\left(angle \cdot \left(\pi \cdot \color{blue}{\left(0.005555555555555556 \cdot a\right)}\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} \]
                5. Simplified96.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{32400}\right)\right) \]
                  14. *-lowering-*.f64N/A

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{32400}\right)\right) \]
                  15. PI-lowering-PI.f64N/A

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{1}{32400}\right)\right) \]
                  16. PI-lowering-PI.f6456.2

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\pi \cdot \color{blue}{\pi}\right) \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \]
                8. Simplified56.2%

                  \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\pi \cdot \pi\right) \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)} \]
                9. Step-by-step derivation
                  1. pow2N/A

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)}\right) \cdot {a}^{2}\right) \]
                  13. PI-lowering-PI.f64N/A

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{1}{32400}\right)\right) \cdot {a}^{2}\right) \]
                  14. pow2N/A

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right) \cdot \color{blue}{\left(a \cdot a\right)}\right) \]
                  15. *-lowering-*.f6465.4

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \cdot \color{blue}{\left(a \cdot a\right)}\right) \]
                10. Applied egg-rr65.4%

                  \[\leadsto \color{blue}{angle \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \cdot \left(a \cdot a\right)\right)} \]
                11. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

                    \[\leadsto \color{blue}{\left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right) \cdot a\right) \cdot \left(a \cdot angle\right)} \]
                  5. associate-*l*N/A

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

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

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

                    \[\leadsto \left(angle \cdot \color{blue}{\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right)\right)}\right) \cdot \left(a \cdot angle\right) \]
                  9. *-lowering-*.f64N/A

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

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

                    \[\leadsto \left(angle \cdot \left(a \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right)\right)\right) \cdot \left(a \cdot angle\right) \]
                  12. *-lowering-*.f64N/A

                    \[\leadsto \left(angle \cdot \left(a \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)}\right)\right)\right) \cdot \left(a \cdot angle\right) \]
                  13. PI-lowering-PI.f64N/A

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

                    \[\leadsto \left(angle \cdot \left(a \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right)\right)\right) \cdot \color{blue}{\left(angle \cdot a\right)} \]
                  15. *-lowering-*.f6478.5

                    \[\leadsto \left(angle \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right) \cdot \color{blue}{\left(angle \cdot a\right)} \]
                12. Applied egg-rr78.5%

                  \[\leadsto \color{blue}{\left(angle \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right) \cdot \left(angle \cdot a\right)} \]
              7. Recombined 2 regimes into one program.
              8. Final simplification70.3%

                \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 3.1 \cdot 10^{+122}:\\ \;\;\;\;\mathsf{fma}\left(0.5 - 0.5 \cdot \cos \left(2 \cdot \left(angle \cdot \left(\pi \cdot 0.005555555555555556\right)\right)\right), a \cdot a, b \cdot b\right)\\ \mathbf{else}:\\ \;\;\;\;\left(a \cdot angle\right) \cdot \left(angle \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right)\\ \end{array} \]
              9. Add Preprocessing

              Alternative 12: 62.8% accurate, 12.1× speedup?

              \[\begin{array}{l} angle_m = \left|angle\right| \\ \begin{array}{l} \mathbf{if}\;a \leq 3.1 \cdot 10^{+122}:\\ \;\;\;\;b \cdot b\\ \mathbf{else}:\\ \;\;\;\;\left(a \cdot angle\_m\right) \cdot \left(angle\_m \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right)\\ \end{array} \end{array} \]
              angle_m = (fabs.f64 angle)
              (FPCore (a b angle_m)
               :precision binary64
               (if (<= a 3.1e+122)
                 (* b b)
                 (* (* a angle_m) (* angle_m (* a (* PI (* PI 3.08641975308642e-5)))))))
              angle_m = fabs(angle);
              double code(double a, double b, double angle_m) {
              	double tmp;
              	if (a <= 3.1e+122) {
              		tmp = b * b;
              	} else {
              		tmp = (a * angle_m) * (angle_m * (a * (((double) M_PI) * (((double) M_PI) * 3.08641975308642e-5))));
              	}
              	return tmp;
              }
              
              angle_m = Math.abs(angle);
              public static double code(double a, double b, double angle_m) {
              	double tmp;
              	if (a <= 3.1e+122) {
              		tmp = b * b;
              	} else {
              		tmp = (a * angle_m) * (angle_m * (a * (Math.PI * (Math.PI * 3.08641975308642e-5))));
              	}
              	return tmp;
              }
              
              angle_m = math.fabs(angle)
              def code(a, b, angle_m):
              	tmp = 0
              	if a <= 3.1e+122:
              		tmp = b * b
              	else:
              		tmp = (a * angle_m) * (angle_m * (a * (math.pi * (math.pi * 3.08641975308642e-5))))
              	return tmp
              
              angle_m = abs(angle)
              function code(a, b, angle_m)
              	tmp = 0.0
              	if (a <= 3.1e+122)
              		tmp = Float64(b * b);
              	else
              		tmp = Float64(Float64(a * angle_m) * Float64(angle_m * Float64(a * Float64(pi * Float64(pi * 3.08641975308642e-5)))));
              	end
              	return tmp
              end
              
              angle_m = abs(angle);
              function tmp_2 = code(a, b, angle_m)
              	tmp = 0.0;
              	if (a <= 3.1e+122)
              		tmp = b * b;
              	else
              		tmp = (a * angle_m) * (angle_m * (a * (pi * (pi * 3.08641975308642e-5))));
              	end
              	tmp_2 = tmp;
              end
              
              angle_m = N[Abs[angle], $MachinePrecision]
              code[a_, b_, angle$95$m_] := If[LessEqual[a, 3.1e+122], N[(b * b), $MachinePrecision], N[(N[(a * angle$95$m), $MachinePrecision] * N[(angle$95$m * N[(a * N[(Pi * N[(Pi * 3.08641975308642e-5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
              
              \begin{array}{l}
              angle_m = \left|angle\right|
              
              \\
              \begin{array}{l}
              \mathbf{if}\;a \leq 3.1 \cdot 10^{+122}:\\
              \;\;\;\;b \cdot b\\
              
              \mathbf{else}:\\
              \;\;\;\;\left(a \cdot angle\_m\right) \cdot \left(angle\_m \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right)\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if a < 3.09999999999999999e122

                1. Initial program 79.9%

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

                  \[\leadsto \color{blue}{{b}^{2}} \]
                4. Step-by-step derivation
                  1. unpow2N/A

                    \[\leadsto \color{blue}{b \cdot b} \]
                  2. *-lowering-*.f6463.4

                    \[\leadsto \color{blue}{b \cdot b} \]
                5. Simplified63.4%

                  \[\leadsto \color{blue}{b \cdot b} \]

                if 3.09999999999999999e122 < a

                1. Initial program 96.9%

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto {\left(angle \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \left(\frac{1}{180} \cdot a\right)\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \mathsf{PI}\left(\right)\right)\right)}^{2} \]
                  10. *-lowering-*.f6496.9

                    \[\leadsto {\left(angle \cdot \left(\pi \cdot \color{blue}{\left(0.005555555555555556 \cdot a\right)}\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} \]
                5. Simplified96.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{32400}\right)\right) \]
                  14. *-lowering-*.f64N/A

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{32400}\right)\right) \]
                  15. PI-lowering-PI.f64N/A

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{1}{32400}\right)\right) \]
                  16. PI-lowering-PI.f6456.2

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\pi \cdot \color{blue}{\pi}\right) \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \]
                8. Simplified56.2%

                  \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\pi \cdot \pi\right) \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)} \]
                9. Step-by-step derivation
                  1. pow2N/A

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)}\right) \cdot {a}^{2}\right) \]
                  13. PI-lowering-PI.f64N/A

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{1}{32400}\right)\right) \cdot {a}^{2}\right) \]
                  14. pow2N/A

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right) \cdot \color{blue}{\left(a \cdot a\right)}\right) \]
                  15. *-lowering-*.f6465.4

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \cdot \color{blue}{\left(a \cdot a\right)}\right) \]
                10. Applied egg-rr65.4%

                  \[\leadsto \color{blue}{angle \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \cdot \left(a \cdot a\right)\right)} \]
                11. Step-by-step derivation
                  1. *-commutativeN/A

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

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

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

                    \[\leadsto \color{blue}{\left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right) \cdot a\right) \cdot \left(a \cdot angle\right)} \]
                  5. associate-*l*N/A

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

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

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

                    \[\leadsto \left(angle \cdot \color{blue}{\left(a \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right)\right)}\right) \cdot \left(a \cdot angle\right) \]
                  9. *-lowering-*.f64N/A

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

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

                    \[\leadsto \left(angle \cdot \left(a \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right)\right)\right) \cdot \left(a \cdot angle\right) \]
                  12. *-lowering-*.f64N/A

                    \[\leadsto \left(angle \cdot \left(a \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)}\right)\right)\right) \cdot \left(a \cdot angle\right) \]
                  13. PI-lowering-PI.f64N/A

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

                    \[\leadsto \left(angle \cdot \left(a \cdot \left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right)\right)\right) \cdot \color{blue}{\left(angle \cdot a\right)} \]
                  15. *-lowering-*.f6478.5

                    \[\leadsto \left(angle \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right) \cdot \color{blue}{\left(angle \cdot a\right)} \]
                12. Applied egg-rr78.5%

                  \[\leadsto \color{blue}{\left(angle \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right) \cdot \left(angle \cdot a\right)} \]
              3. Recombined 2 regimes into one program.
              4. Final simplification65.6%

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

              Alternative 13: 62.2% accurate, 12.1× speedup?

              \[\begin{array}{l} angle_m = \left|angle\right| \\ \begin{array}{l} \mathbf{if}\;a \leq 3 \cdot 10^{+122}:\\ \;\;\;\;b \cdot b\\ \mathbf{else}:\\ \;\;\;\;angle\_m \cdot \left(a \cdot \left(angle\_m \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right)\right)\\ \end{array} \end{array} \]
              angle_m = (fabs.f64 angle)
              (FPCore (a b angle_m)
               :precision binary64
               (if (<= a 3e+122)
                 (* b b)
                 (* angle_m (* a (* angle_m (* a (* PI (* PI 3.08641975308642e-5))))))))
              angle_m = fabs(angle);
              double code(double a, double b, double angle_m) {
              	double tmp;
              	if (a <= 3e+122) {
              		tmp = b * b;
              	} else {
              		tmp = angle_m * (a * (angle_m * (a * (((double) M_PI) * (((double) M_PI) * 3.08641975308642e-5)))));
              	}
              	return tmp;
              }
              
              angle_m = Math.abs(angle);
              public static double code(double a, double b, double angle_m) {
              	double tmp;
              	if (a <= 3e+122) {
              		tmp = b * b;
              	} else {
              		tmp = angle_m * (a * (angle_m * (a * (Math.PI * (Math.PI * 3.08641975308642e-5)))));
              	}
              	return tmp;
              }
              
              angle_m = math.fabs(angle)
              def code(a, b, angle_m):
              	tmp = 0
              	if a <= 3e+122:
              		tmp = b * b
              	else:
              		tmp = angle_m * (a * (angle_m * (a * (math.pi * (math.pi * 3.08641975308642e-5)))))
              	return tmp
              
              angle_m = abs(angle)
              function code(a, b, angle_m)
              	tmp = 0.0
              	if (a <= 3e+122)
              		tmp = Float64(b * b);
              	else
              		tmp = Float64(angle_m * Float64(a * Float64(angle_m * Float64(a * Float64(pi * Float64(pi * 3.08641975308642e-5))))));
              	end
              	return tmp
              end
              
              angle_m = abs(angle);
              function tmp_2 = code(a, b, angle_m)
              	tmp = 0.0;
              	if (a <= 3e+122)
              		tmp = b * b;
              	else
              		tmp = angle_m * (a * (angle_m * (a * (pi * (pi * 3.08641975308642e-5)))));
              	end
              	tmp_2 = tmp;
              end
              
              angle_m = N[Abs[angle], $MachinePrecision]
              code[a_, b_, angle$95$m_] := If[LessEqual[a, 3e+122], N[(b * b), $MachinePrecision], N[(angle$95$m * N[(a * N[(angle$95$m * N[(a * N[(Pi * N[(Pi * 3.08641975308642e-5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
              
              \begin{array}{l}
              angle_m = \left|angle\right|
              
              \\
              \begin{array}{l}
              \mathbf{if}\;a \leq 3 \cdot 10^{+122}:\\
              \;\;\;\;b \cdot b\\
              
              \mathbf{else}:\\
              \;\;\;\;angle\_m \cdot \left(a \cdot \left(angle\_m \cdot \left(a \cdot \left(\pi \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right)\right)\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if a < 2.99999999999999986e122

                1. Initial program 79.9%

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

                  \[\leadsto \color{blue}{{b}^{2}} \]
                4. Step-by-step derivation
                  1. unpow2N/A

                    \[\leadsto \color{blue}{b \cdot b} \]
                  2. *-lowering-*.f6463.4

                    \[\leadsto \color{blue}{b \cdot b} \]
                5. Simplified63.4%

                  \[\leadsto \color{blue}{b \cdot b} \]

                if 2.99999999999999986e122 < a

                1. Initial program 96.9%

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto {\left(angle \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \left(\frac{1}{180} \cdot a\right)\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \mathsf{PI}\left(\right)\right)\right)}^{2} \]
                  10. *-lowering-*.f6496.9

                    \[\leadsto {\left(angle \cdot \left(\pi \cdot \color{blue}{\left(0.005555555555555556 \cdot a\right)}\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} \]
                5. Simplified96.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{32400}\right)\right) \]
                  14. *-lowering-*.f64N/A

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\color{blue}{\left(\mathsf{PI}\left(\right) \cdot \mathsf{PI}\left(\right)\right)} \cdot \frac{1}{32400}\right)\right) \]
                  15. PI-lowering-PI.f64N/A

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \mathsf{PI}\left(\right)\right) \cdot \frac{1}{32400}\right)\right) \]
                  16. PI-lowering-PI.f6456.2

                    \[\leadsto \left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\pi \cdot \color{blue}{\pi}\right) \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \]
                8. Simplified56.2%

                  \[\leadsto \color{blue}{\left(a \cdot a\right) \cdot \left(\left(angle \cdot angle\right) \cdot \left(\left(\pi \cdot \pi\right) \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)} \]
                9. Step-by-step derivation
                  1. pow2N/A

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)}\right) \cdot {a}^{2}\right) \]
                  13. PI-lowering-PI.f64N/A

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\color{blue}{\mathsf{PI}\left(\right)} \cdot \frac{1}{32400}\right)\right) \cdot {a}^{2}\right) \]
                  14. pow2N/A

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \mathsf{PI}\left(\right)\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right) \cdot \color{blue}{\left(a \cdot a\right)}\right) \]
                  15. *-lowering-*.f6465.4

                    \[\leadsto angle \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \cdot \color{blue}{\left(a \cdot a\right)}\right) \]
                10. Applied egg-rr65.4%

                  \[\leadsto \color{blue}{angle \cdot \left(\left(\left(angle \cdot \pi\right) \cdot \left(\pi \cdot 3.08641975308642 \cdot 10^{-5}\right)\right) \cdot \left(a \cdot a\right)\right)} \]
                11. Step-by-step derivation
                  1. associate-*r*N/A

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

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

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

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

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

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

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

                    \[\leadsto angle \cdot \left(\left(angle \cdot \left(a \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)\right)}\right)\right) \cdot a\right) \]
                  9. PI-lowering-PI.f64N/A

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

                    \[\leadsto angle \cdot \left(\left(angle \cdot \left(a \cdot \left(\mathsf{PI}\left(\right) \cdot \color{blue}{\left(\mathsf{PI}\left(\right) \cdot \frac{1}{32400}\right)}\right)\right)\right) \cdot a\right) \]
                  11. PI-lowering-PI.f6470.9

                    \[\leadsto angle \cdot \left(\left(angle \cdot \left(a \cdot \left(\pi \cdot \left(\color{blue}{\pi} \cdot 3.08641975308642 \cdot 10^{-5}\right)\right)\right)\right) \cdot a\right) \]
                12. Applied egg-rr70.9%

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

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

              Alternative 14: 57.1% accurate, 74.7× speedup?

              \[\begin{array}{l} angle_m = \left|angle\right| \\ b \cdot b \end{array} \]
              angle_m = (fabs.f64 angle)
              (FPCore (a b angle_m) :precision binary64 (* b b))
              angle_m = fabs(angle);
              double code(double a, double b, double angle_m) {
              	return b * b;
              }
              
              angle_m = abs(angle)
              real(8) function code(a, b, angle_m)
                  real(8), intent (in) :: a
                  real(8), intent (in) :: b
                  real(8), intent (in) :: angle_m
                  code = b * b
              end function
              
              angle_m = Math.abs(angle);
              public static double code(double a, double b, double angle_m) {
              	return b * b;
              }
              
              angle_m = math.fabs(angle)
              def code(a, b, angle_m):
              	return b * b
              
              angle_m = abs(angle)
              function code(a, b, angle_m)
              	return Float64(b * b)
              end
              
              angle_m = abs(angle);
              function tmp = code(a, b, angle_m)
              	tmp = b * b;
              end
              
              angle_m = N[Abs[angle], $MachinePrecision]
              code[a_, b_, angle$95$m_] := N[(b * b), $MachinePrecision]
              
              \begin{array}{l}
              angle_m = \left|angle\right|
              
              \\
              b \cdot b
              \end{array}
              
              Derivation
              1. Initial program 82.3%

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

                \[\leadsto \color{blue}{{b}^{2}} \]
              4. Step-by-step derivation
                1. unpow2N/A

                  \[\leadsto \color{blue}{b \cdot b} \]
                2. *-lowering-*.f6462.0

                  \[\leadsto \color{blue}{b \cdot b} \]
              5. Simplified62.0%

                \[\leadsto \color{blue}{b \cdot b} \]
              6. Add Preprocessing

              Reproduce

              ?
              herbie shell --seed 2024204 
              (FPCore (a b angle)
                :name "ab-angle->ABCF A"
                :precision binary64
                (+ (pow (* a (sin (* (/ angle 180.0) PI))) 2.0) (pow (* b (cos (* (/ angle 180.0) PI))) 2.0)))