powComplex, imaginary part

Percentage Accurate: 41.2% → 64.8%
Time: 21.0s
Alternatives: 24
Speedup: 2.9×

Specification

?
\[\begin{array}{l} \\ \begin{array}{l} t_0 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ e^{t\_0 \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(t\_0 \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \end{array} \end{array} \]
(FPCore (x.re x.im y.re y.im)
 :precision binary64
 (let* ((t_0 (log (sqrt (+ (* x.re x.re) (* x.im x.im))))))
   (*
    (exp (- (* t_0 y.re) (* (atan2 x.im x.re) y.im)))
    (sin (+ (* t_0 y.im) (* (atan2 x.im x.re) y.re))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
	double t_0 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
	return exp(((t_0 * y_46_re) - (atan2(x_46_im, x_46_re) * y_46_im))) * sin(((t_0 * y_46_im) + (atan2(x_46_im, x_46_re) * y_46_re)));
}
real(8) function code(x_46re, x_46im, y_46re, y_46im)
    real(8), intent (in) :: x_46re
    real(8), intent (in) :: x_46im
    real(8), intent (in) :: y_46re
    real(8), intent (in) :: y_46im
    real(8) :: t_0
    t_0 = log(sqrt(((x_46re * x_46re) + (x_46im * x_46im))))
    code = exp(((t_0 * y_46re) - (atan2(x_46im, x_46re) * y_46im))) * sin(((t_0 * y_46im) + (atan2(x_46im, x_46re) * y_46re)))
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
	double t_0 = Math.log(Math.sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
	return Math.exp(((t_0 * y_46_re) - (Math.atan2(x_46_im, x_46_re) * y_46_im))) * Math.sin(((t_0 * y_46_im) + (Math.atan2(x_46_im, x_46_re) * y_46_re)));
}
def code(x_46_re, x_46_im, y_46_re, y_46_im):
	t_0 = math.log(math.sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))
	return math.exp(((t_0 * y_46_re) - (math.atan2(x_46_im, x_46_re) * y_46_im))) * math.sin(((t_0 * y_46_im) + (math.atan2(x_46_im, x_46_re) * y_46_re)))
function code(x_46_re, x_46_im, y_46_re, y_46_im)
	t_0 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
	return Float64(exp(Float64(Float64(t_0 * y_46_re) - Float64(atan(x_46_im, x_46_re) * y_46_im))) * sin(Float64(Float64(t_0 * y_46_im) + Float64(atan(x_46_im, x_46_re) * y_46_re))))
end
function tmp = code(x_46_re, x_46_im, y_46_re, y_46_im)
	t_0 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
	tmp = exp(((t_0 * y_46_re) - (atan2(x_46_im, x_46_re) * y_46_im))) * sin(((t_0 * y_46_im) + (atan2(x_46_im, x_46_re) * y_46_re)));
end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, N[(N[Exp[N[(N[(t$95$0 * y$46$re), $MachinePrecision] - N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(N[(t$95$0 * y$46$im), $MachinePrecision] + N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
e^{t\_0 \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(t\_0 \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)
\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 24 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: 41.2% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ e^{t\_0 \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(t\_0 \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \end{array} \end{array} \]
(FPCore (x.re x.im y.re y.im)
 :precision binary64
 (let* ((t_0 (log (sqrt (+ (* x.re x.re) (* x.im x.im))))))
   (*
    (exp (- (* t_0 y.re) (* (atan2 x.im x.re) y.im)))
    (sin (+ (* t_0 y.im) (* (atan2 x.im x.re) y.re))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
	double t_0 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
	return exp(((t_0 * y_46_re) - (atan2(x_46_im, x_46_re) * y_46_im))) * sin(((t_0 * y_46_im) + (atan2(x_46_im, x_46_re) * y_46_re)));
}
real(8) function code(x_46re, x_46im, y_46re, y_46im)
    real(8), intent (in) :: x_46re
    real(8), intent (in) :: x_46im
    real(8), intent (in) :: y_46re
    real(8), intent (in) :: y_46im
    real(8) :: t_0
    t_0 = log(sqrt(((x_46re * x_46re) + (x_46im * x_46im))))
    code = exp(((t_0 * y_46re) - (atan2(x_46im, x_46re) * y_46im))) * sin(((t_0 * y_46im) + (atan2(x_46im, x_46re) * y_46re)))
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
	double t_0 = Math.log(Math.sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
	return Math.exp(((t_0 * y_46_re) - (Math.atan2(x_46_im, x_46_re) * y_46_im))) * Math.sin(((t_0 * y_46_im) + (Math.atan2(x_46_im, x_46_re) * y_46_re)));
}
def code(x_46_re, x_46_im, y_46_re, y_46_im):
	t_0 = math.log(math.sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))
	return math.exp(((t_0 * y_46_re) - (math.atan2(x_46_im, x_46_re) * y_46_im))) * math.sin(((t_0 * y_46_im) + (math.atan2(x_46_im, x_46_re) * y_46_re)))
function code(x_46_re, x_46_im, y_46_re, y_46_im)
	t_0 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
	return Float64(exp(Float64(Float64(t_0 * y_46_re) - Float64(atan(x_46_im, x_46_re) * y_46_im))) * sin(Float64(Float64(t_0 * y_46_im) + Float64(atan(x_46_im, x_46_re) * y_46_re))))
end
function tmp = code(x_46_re, x_46_im, y_46_re, y_46_im)
	t_0 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
	tmp = exp(((t_0 * y_46_re) - (atan2(x_46_im, x_46_re) * y_46_im))) * sin(((t_0 * y_46_im) + (atan2(x_46_im, x_46_re) * y_46_re)));
end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, N[(N[Exp[N[(N[(t$95$0 * y$46$re), $MachinePrecision] - N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(N[(t$95$0 * y$46$im), $MachinePrecision] + N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
e^{t\_0 \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(t\_0 \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)
\end{array}
\end{array}

Alternative 1: 64.8% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_3 := e^{t\_2 \cdot y.re - t\_0}\\ t_4 := t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\ \mathbf{if}\;t\_4 \leq -0.9:\\ \;\;\;\;t\_3 \cdot \left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right)\\ \mathbf{elif}\;t\_4 \leq -2 \cdot 10^{-159}:\\ \;\;\;\;e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\log \left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right)\\ \mathbf{elif}\;t\_4 \leq 0:\\ \;\;\;\;t\_3 \cdot t\_1\\ \mathbf{elif}\;t\_4 \leq 1:\\ \;\;\;\;\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right) \cdot \left(y.im \cdot 0.5\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}\\ \mathbf{elif}\;t\_4 \leq \infty:\\ \;\;\;\;t\_3 \cdot \sin t\_1\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\ \end{array} \end{array} \]
(FPCore (x.re x.im y.re y.im)
 :precision binary64
 (let* ((t_0 (* (atan2 x.im x.re) y.im))
        (t_1 (* y.re (atan2 x.im x.re)))
        (t_2 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
        (t_3 (exp (- (* t_2 y.re) t_0)))
        (t_4 (* t_3 (sin (+ (* t_2 y.im) t_1)))))
   (if (<= t_4 -0.9)
     (*
      t_3
      (*
       y.re
       (fma
        -0.16666666666666666
        (* (* y.re y.re) (pow (atan2 x.im x.re) 3.0))
        (atan2 x.im x.re))))
     (if (<= t_4 -2e-159)
       (*
        (exp (* y.im (- 0.0 (atan2 x.im x.re))))
        (sin
         (*
          y.re
          (fma
           y.im
           (/ (log (sqrt (fma x.im x.im (* x.re x.re)))) y.re)
           (atan2 x.im x.re)))))
       (if (<= t_4 0.0)
         (* t_3 t_1)
         (if (<= t_4 1.0)
           (/
            (sin
             (fma
              y.re
              (atan2 x.im x.re)
              (* (log (fma x.re x.re (* x.im x.im))) (* y.im 0.5))))
            (exp (fma (atan2 x.im x.re) y.im 0.0)))
           (if (<= t_4 INFINITY)
             (* t_3 (sin t_1))
             (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_1))))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
	double t_1 = y_46_re * atan2(x_46_im, x_46_re);
	double t_2 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
	double t_3 = exp(((t_2 * y_46_re) - t_0));
	double t_4 = t_3 * sin(((t_2 * y_46_im) + t_1));
	double tmp;
	if (t_4 <= -0.9) {
		tmp = t_3 * (y_46_re * fma(-0.16666666666666666, ((y_46_re * y_46_re) * pow(atan2(x_46_im, x_46_re), 3.0)), atan2(x_46_im, x_46_re)));
	} else if (t_4 <= -2e-159) {
		tmp = exp((y_46_im * (0.0 - atan2(x_46_im, x_46_re)))) * sin((y_46_re * fma(y_46_im, (log(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re)))) / y_46_re), atan2(x_46_im, x_46_re))));
	} else if (t_4 <= 0.0) {
		tmp = t_3 * t_1;
	} else if (t_4 <= 1.0) {
		tmp = sin(fma(y_46_re, atan2(x_46_im, x_46_re), (log(fma(x_46_re, x_46_re, (x_46_im * x_46_im))) * (y_46_im * 0.5)))) / exp(fma(atan2(x_46_im, x_46_re), y_46_im, 0.0));
	} else if (t_4 <= ((double) INFINITY)) {
		tmp = t_3 * sin(t_1);
	} else {
		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_1;
	}
	return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im)
	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
	t_1 = Float64(y_46_re * atan(x_46_im, x_46_re))
	t_2 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
	t_3 = exp(Float64(Float64(t_2 * y_46_re) - t_0))
	t_4 = Float64(t_3 * sin(Float64(Float64(t_2 * y_46_im) + t_1)))
	tmp = 0.0
	if (t_4 <= -0.9)
		tmp = Float64(t_3 * Float64(y_46_re * fma(-0.16666666666666666, Float64(Float64(y_46_re * y_46_re) * (atan(x_46_im, x_46_re) ^ 3.0)), atan(x_46_im, x_46_re))));
	elseif (t_4 <= -2e-159)
		tmp = Float64(exp(Float64(y_46_im * Float64(0.0 - atan(x_46_im, x_46_re)))) * sin(Float64(y_46_re * fma(y_46_im, Float64(log(sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re)))) / y_46_re), atan(x_46_im, x_46_re)))));
	elseif (t_4 <= 0.0)
		tmp = Float64(t_3 * t_1);
	elseif (t_4 <= 1.0)
		tmp = Float64(sin(fma(y_46_re, atan(x_46_im, x_46_re), Float64(log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im))) * Float64(y_46_im * 0.5)))) / exp(fma(atan(x_46_im, x_46_re), y_46_im, 0.0)));
	elseif (t_4 <= Inf)
		tmp = Float64(t_3 * sin(t_1));
	else
		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_1);
	end
	return tmp
end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[Exp[N[(N[(t$95$2 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$4 = N[(t$95$3 * N[Sin[N[(N[(t$95$2 * y$46$im), $MachinePrecision] + t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$4, -0.9], N[(t$95$3 * N[(y$46$re * N[(-0.16666666666666666 * N[(N[(y$46$re * y$46$re), $MachinePrecision] * N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision] + N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$4, -2e-159], N[(N[Exp[N[(y$46$im * N[(0.0 - N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(y$46$re * N[(y$46$im * N[(N[Log[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] / y$46$re), $MachinePrecision] + N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$4, 0.0], N[(t$95$3 * t$95$1), $MachinePrecision], If[LessEqual[t$95$4, 1.0], N[(N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[(y$46$im * 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Exp[N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im + 0.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$4, Infinity], N[(t$95$3 * N[Sin[t$95$1], $MachinePrecision]), $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$1), $MachinePrecision]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
t_3 := e^{t\_2 \cdot y.re - t\_0}\\
t_4 := t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\
\mathbf{if}\;t\_4 \leq -0.9:\\
\;\;\;\;t\_3 \cdot \left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right)\\

\mathbf{elif}\;t\_4 \leq -2 \cdot 10^{-159}:\\
\;\;\;\;e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\log \left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right)\\

\mathbf{elif}\;t\_4 \leq 0:\\
\;\;\;\;t\_3 \cdot t\_1\\

\mathbf{elif}\;t\_4 \leq 1:\\
\;\;\;\;\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right) \cdot \left(y.im \cdot 0.5\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}\\

\mathbf{elif}\;t\_4 \leq \infty:\\
\;\;\;\;t\_3 \cdot \sin t\_1\\

\mathbf{else}:\\
\;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.900000000000000022

    1. Initial program 50.1%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6450.1

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified50.1%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    6. Taylor expanded in y.re around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \left(\frac{-1}{6} \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right) + \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]
    7. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \left(\frac{-1}{6} \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right) + \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]
      2. accelerator-lowering-fma.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\mathsf{fma}\left(\frac{-1}{6}, {y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)}\right) \]
      3. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \color{blue}{{y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      4. unpow2N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \color{blue}{\left(y.re \cdot y.re\right)} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      5. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \color{blue}{\left(y.re \cdot y.re\right)} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      6. pow-lowering-pow.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot \color{blue}{{\tan^{-1}_* \frac{x.im}{x.re}}^{3}}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      7. atan2-lowering-atan2.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      8. atan2-lowering-atan2.f6463.8

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right)\right) \]
    8. Simplified63.8%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]

    if -0.900000000000000022 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -1.99999999999999998e-159

    1. Initial program 94.1%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.re around 0

      \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    4. Step-by-step derivation
      1. mul-1-negN/A

        \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      2. neg-sub0N/A

        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      3. --lowering--.f64N/A

        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      5. atan2-lowering-atan2.f6494.1

        \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    5. Simplified94.1%

      \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    6. Taylor expanded in y.re around inf

      \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \color{blue}{\left(y.re \cdot \left(\frac{y.im \cdot \log \left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}{y.re} + \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]
    7. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \color{blue}{\left(y.re \cdot \left(\frac{y.im \cdot \log \left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}{y.re} + \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]
      2. associate-/l*N/A

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(y.re \cdot \left(\color{blue}{y.im \cdot \frac{\log \left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}{y.re}} + \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      3. accelerator-lowering-fma.f64N/A

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(y.re \cdot \color{blue}{\mathsf{fma}\left(y.im, \frac{\log \left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)}\right) \]
      4. /-lowering-/.f64N/A

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \color{blue}{\frac{\log \left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}{y.re}}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      5. log-lowering-log.f64N/A

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\color{blue}{\log \left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      6. sqrt-lowering-sqrt.f64N/A

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\log \color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      7. unpow2N/A

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\log \left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      8. accelerator-lowering-fma.f64N/A

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\log \left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      9. unpow2N/A

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\log \left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      10. *-lowering-*.f64N/A

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\log \left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      11. atan2-lowering-atan2.f6495.1

        \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\log \left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}{y.re}, \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right)\right) \]
    8. Simplified95.1%

      \[\leadsto e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \color{blue}{\left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\log \left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]

    if -1.99999999999999998e-159 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0

    1. Initial program 100.0%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f64100.0

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified100.0%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    6. Taylor expanded in y.re around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    7. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f64100.0

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    8. Simplified100.0%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

    if -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < 1

    1. Initial program 87.9%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.re around 0

      \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    4. Step-by-step derivation
      1. mul-1-negN/A

        \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      2. neg-sub0N/A

        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      3. --lowering--.f64N/A

        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      5. atan2-lowering-atan2.f6485.9

        \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    5. Simplified85.9%

      \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    6. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \color{blue}{\sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \]
      2. exp-diffN/A

        \[\leadsto \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \color{blue}{\frac{e^{0}}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}} \]
      3. 1-expN/A

        \[\leadsto \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \frac{\color{blue}{1}}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \]
      4. *-commutativeN/A

        \[\leadsto \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \frac{1}{e^{\color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}} \]
      5. un-div-invN/A

        \[\leadsto \color{blue}{\frac{\sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}} \]
      6. *-commutativeN/A

        \[\leadsto \frac{\sin \left(\color{blue}{y.im \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
      7. pow1/2N/A

        \[\leadsto \frac{\sin \left(y.im \cdot \log \color{blue}{\left({\left(x.re \cdot x.re + x.im \cdot x.im\right)}^{\frac{1}{2}}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
      8. log-powN/A

        \[\leadsto \frac{\sin \left(y.im \cdot \color{blue}{\left(\frac{1}{2} \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
      9. associate-*l*N/A

        \[\leadsto \frac{\sin \left(\color{blue}{\left(y.im \cdot \frac{1}{2}\right) \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
    7. Applied egg-rr86.0%

      \[\leadsto \color{blue}{\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, \left(y.im \cdot 0.5\right) \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}} \]

    if 1 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < +inf.0

    1. Initial program 73.9%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6473.9

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified73.9%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

    if +inf.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

    1. Initial program 0.0%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6439.7

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified39.7%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    6. Taylor expanded in y.re around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    7. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6441.9

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    8. Simplified41.9%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    9. Taylor expanded in x.re around inf

      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    10. Step-by-step derivation
      1. unpow2N/A

        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
      2. *-lowering-*.f6443.7

        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    11. Simplified43.7%

      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    12. Step-by-step derivation
      1. rem-sqrt-squareN/A

        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
      2. fabs-lowering-fabs.f6458.9

        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    13. Applied egg-rr58.9%

      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
  3. Recombined 6 regimes into one program.
  4. Final simplification71.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -0.9:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -2 \cdot 10^{-159}:\\ \;\;\;\;e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)} \cdot \sin \left(y.re \cdot \mathsf{fma}\left(y.im, \frac{\log \left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}{y.re}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 1:\\ \;\;\;\;\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right) \cdot \left(y.im \cdot 0.5\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq \infty:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 64.0% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_3 := e^{t\_2 \cdot y.re - t\_0}\\ t_4 := t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\ t_5 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\ \mathbf{if}\;t\_4 \leq -2 \cdot 10^{-159}:\\ \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, t\_5, t\_1\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;t\_4 \leq 0:\\ \;\;\;\;t\_3 \cdot t\_1\\ \mathbf{elif}\;t\_4 \leq 1:\\ \;\;\;\;\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, t\_5 \cdot \left(y.im \cdot 0.5\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}\\ \mathbf{elif}\;t\_4 \leq \infty:\\ \;\;\;\;t\_3 \cdot \sin t\_1\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\ \end{array} \end{array} \]
(FPCore (x.re x.im y.re y.im)
 :precision binary64
 (let* ((t_0 (* (atan2 x.im x.re) y.im))
        (t_1 (* y.re (atan2 x.im x.re)))
        (t_2 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
        (t_3 (exp (- (* t_2 y.re) t_0)))
        (t_4 (* t_3 (sin (+ (* t_2 y.im) t_1))))
        (t_5 (log (fma x.re x.re (* x.im x.im)))))
   (if (<= t_4 -2e-159)
     (*
      (sin (fma (* y.im 0.5) t_5 t_1))
      (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re))
     (if (<= t_4 0.0)
       (* t_3 t_1)
       (if (<= t_4 1.0)
         (/
          (sin (fma y.re (atan2 x.im x.re) (* t_5 (* y.im 0.5))))
          (exp (fma (atan2 x.im x.re) y.im 0.0)))
         (if (<= t_4 INFINITY)
           (* t_3 (sin t_1))
           (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_1)))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
	double t_1 = y_46_re * atan2(x_46_im, x_46_re);
	double t_2 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
	double t_3 = exp(((t_2 * y_46_re) - t_0));
	double t_4 = t_3 * sin(((t_2 * y_46_im) + t_1));
	double t_5 = log(fma(x_46_re, x_46_re, (x_46_im * x_46_im)));
	double tmp;
	if (t_4 <= -2e-159) {
		tmp = sin(fma((y_46_im * 0.5), t_5, t_1)) * pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
	} else if (t_4 <= 0.0) {
		tmp = t_3 * t_1;
	} else if (t_4 <= 1.0) {
		tmp = sin(fma(y_46_re, atan2(x_46_im, x_46_re), (t_5 * (y_46_im * 0.5)))) / exp(fma(atan2(x_46_im, x_46_re), y_46_im, 0.0));
	} else if (t_4 <= ((double) INFINITY)) {
		tmp = t_3 * sin(t_1);
	} else {
		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_1;
	}
	return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im)
	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
	t_1 = Float64(y_46_re * atan(x_46_im, x_46_re))
	t_2 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
	t_3 = exp(Float64(Float64(t_2 * y_46_re) - t_0))
	t_4 = Float64(t_3 * sin(Float64(Float64(t_2 * y_46_im) + t_1)))
	t_5 = log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im)))
	tmp = 0.0
	if (t_4 <= -2e-159)
		tmp = Float64(sin(fma(Float64(y_46_im * 0.5), t_5, t_1)) * (sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re));
	elseif (t_4 <= 0.0)
		tmp = Float64(t_3 * t_1);
	elseif (t_4 <= 1.0)
		tmp = Float64(sin(fma(y_46_re, atan(x_46_im, x_46_re), Float64(t_5 * Float64(y_46_im * 0.5)))) / exp(fma(atan(x_46_im, x_46_re), y_46_im, 0.0)));
	elseif (t_4 <= Inf)
		tmp = Float64(t_3 * sin(t_1));
	else
		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_1);
	end
	return tmp
end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[Exp[N[(N[(t$95$2 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$4 = N[(t$95$3 * N[Sin[N[(N[(t$95$2 * y$46$im), $MachinePrecision] + t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$4, -2e-159], N[(N[Sin[N[(N[(y$46$im * 0.5), $MachinePrecision] * t$95$5 + t$95$1), $MachinePrecision]], $MachinePrecision] * N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$4, 0.0], N[(t$95$3 * t$95$1), $MachinePrecision], If[LessEqual[t$95$4, 1.0], N[(N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(t$95$5 * N[(y$46$im * 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Exp[N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im + 0.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$4, Infinity], N[(t$95$3 * N[Sin[t$95$1], $MachinePrecision]), $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$1), $MachinePrecision]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
t_3 := e^{t\_2 \cdot y.re - t\_0}\\
t_4 := t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\
t_5 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\
\mathbf{if}\;t\_4 \leq -2 \cdot 10^{-159}:\\
\;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, t\_5, t\_1\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\

\mathbf{elif}\;t\_4 \leq 0:\\
\;\;\;\;t\_3 \cdot t\_1\\

\mathbf{elif}\;t\_4 \leq 1:\\
\;\;\;\;\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, t\_5 \cdot \left(y.im \cdot 0.5\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}\\

\mathbf{elif}\;t\_4 \leq \infty:\\
\;\;\;\;t\_3 \cdot \sin t\_1\\

\mathbf{else}:\\
\;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -1.99999999999999998e-159

    1. Initial program 69.9%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{y.im \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      2. pow1/2N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \log \color{blue}{\left({\left(x.re \cdot x.re + x.im \cdot x.im\right)}^{\frac{1}{2}}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      3. log-powN/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \color{blue}{\left(\frac{1}{2} \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      4. associate-*r*N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{\left(y.im \cdot \frac{1}{2}\right) \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      5. accelerator-lowering-fma.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
      6. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(\color{blue}{y.im \cdot \frac{1}{2}}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
      7. log-lowering-log.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \color{blue}{\log \left(x.re \cdot x.re + x.im \cdot x.im\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
      8. accelerator-lowering-fma.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
      9. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
      10. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re}\right)\right) \]
      11. atan2-lowering-atan2.f6469.9

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}} \cdot y.re\right)\right) \]
    4. Applied egg-rr69.9%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
    5. Taylor expanded in y.im around 0

      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
    6. Step-by-step derivation
      1. pow-lowering-pow.f64N/A

        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
      2. sqrt-lowering-sqrt.f64N/A

        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
      3. unpow2N/A

        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
      4. accelerator-lowering-fma.f64N/A

        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
      5. unpow2N/A

        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
      6. *-lowering-*.f6463.6

        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
    7. Simplified63.6%

      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]

    if -1.99999999999999998e-159 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0

    1. Initial program 100.0%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f64100.0

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified100.0%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    6. Taylor expanded in y.re around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    7. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f64100.0

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    8. Simplified100.0%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

    if -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < 1

    1. Initial program 87.9%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.re around 0

      \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    4. Step-by-step derivation
      1. mul-1-negN/A

        \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      2. neg-sub0N/A

        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      3. --lowering--.f64N/A

        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      5. atan2-lowering-atan2.f6485.9

        \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    5. Simplified85.9%

      \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    6. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \color{blue}{\sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \]
      2. exp-diffN/A

        \[\leadsto \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \color{blue}{\frac{e^{0}}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}} \]
      3. 1-expN/A

        \[\leadsto \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \frac{\color{blue}{1}}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \]
      4. *-commutativeN/A

        \[\leadsto \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \frac{1}{e^{\color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}} \]
      5. un-div-invN/A

        \[\leadsto \color{blue}{\frac{\sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}} \]
      6. *-commutativeN/A

        \[\leadsto \frac{\sin \left(\color{blue}{y.im \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
      7. pow1/2N/A

        \[\leadsto \frac{\sin \left(y.im \cdot \log \color{blue}{\left({\left(x.re \cdot x.re + x.im \cdot x.im\right)}^{\frac{1}{2}}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
      8. log-powN/A

        \[\leadsto \frac{\sin \left(y.im \cdot \color{blue}{\left(\frac{1}{2} \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
      9. associate-*l*N/A

        \[\leadsto \frac{\sin \left(\color{blue}{\left(y.im \cdot \frac{1}{2}\right) \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
    7. Applied egg-rr86.0%

      \[\leadsto \color{blue}{\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, \left(y.im \cdot 0.5\right) \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}} \]

    if 1 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < +inf.0

    1. Initial program 73.9%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6473.9

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified73.9%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

    if +inf.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

    1. Initial program 0.0%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6439.7

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified39.7%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    6. Taylor expanded in y.re around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    7. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6441.9

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    8. Simplified41.9%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    9. Taylor expanded in x.re around inf

      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    10. Step-by-step derivation
      1. unpow2N/A

        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
      2. *-lowering-*.f6443.7

        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    11. Simplified43.7%

      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    12. Step-by-step derivation
      1. rem-sqrt-squareN/A

        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
      2. fabs-lowering-fabs.f6458.9

        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    13. Applied egg-rr58.9%

      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
  3. Recombined 5 regimes into one program.
  4. Final simplification68.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -2 \cdot 10^{-159}:\\ \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 1:\\ \;\;\;\;\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right) \cdot \left(y.im \cdot 0.5\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq \infty:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 62.3% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_2 := e^{t\_1 \cdot y.re - t\_0}\\ t_3 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_4 := \sin \left(t\_1 \cdot y.im + t\_3\right)\\ t_5 := t\_2 \cdot t\_4\\ t_6 := t\_4 \cdot \mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, 0 - y.im, 1\right)\\ \mathbf{if}\;t\_5 \leq -0.5:\\ \;\;\;\;\left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;t\_5 \leq -2 \cdot 10^{-159}:\\ \;\;\;\;t\_6\\ \mathbf{elif}\;t\_5 \leq 0:\\ \;\;\;\;t\_2 \cdot t\_3\\ \mathbf{elif}\;t\_5 \leq 1:\\ \;\;\;\;t\_6\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_3\\ \end{array} \end{array} \]
(FPCore (x.re x.im y.re y.im)
 :precision binary64
 (let* ((t_0 (* (atan2 x.im x.re) y.im))
        (t_1 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
        (t_2 (exp (- (* t_1 y.re) t_0)))
        (t_3 (* y.re (atan2 x.im x.re)))
        (t_4 (sin (+ (* t_1 y.im) t_3)))
        (t_5 (* t_2 t_4))
        (t_6 (* t_4 (fma (atan2 x.im x.re) (- 0.0 y.im) 1.0))))
   (if (<= t_5 -0.5)
     (*
      (*
       y.re
       (fma
        -0.16666666666666666
        (* (* y.re y.re) (pow (atan2 x.im x.re) 3.0))
        (atan2 x.im x.re)))
      (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re))
     (if (<= t_5 -2e-159)
       t_6
       (if (<= t_5 0.0)
         (* t_2 t_3)
         (if (<= t_5 1.0)
           t_6
           (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_3)))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
	double t_1 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
	double t_2 = exp(((t_1 * y_46_re) - t_0));
	double t_3 = y_46_re * atan2(x_46_im, x_46_re);
	double t_4 = sin(((t_1 * y_46_im) + t_3));
	double t_5 = t_2 * t_4;
	double t_6 = t_4 * fma(atan2(x_46_im, x_46_re), (0.0 - y_46_im), 1.0);
	double tmp;
	if (t_5 <= -0.5) {
		tmp = (y_46_re * fma(-0.16666666666666666, ((y_46_re * y_46_re) * pow(atan2(x_46_im, x_46_re), 3.0)), atan2(x_46_im, x_46_re))) * pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
	} else if (t_5 <= -2e-159) {
		tmp = t_6;
	} else if (t_5 <= 0.0) {
		tmp = t_2 * t_3;
	} else if (t_5 <= 1.0) {
		tmp = t_6;
	} else {
		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_3;
	}
	return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im)
	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
	t_1 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
	t_2 = exp(Float64(Float64(t_1 * y_46_re) - t_0))
	t_3 = Float64(y_46_re * atan(x_46_im, x_46_re))
	t_4 = sin(Float64(Float64(t_1 * y_46_im) + t_3))
	t_5 = Float64(t_2 * t_4)
	t_6 = Float64(t_4 * fma(atan(x_46_im, x_46_re), Float64(0.0 - y_46_im), 1.0))
	tmp = 0.0
	if (t_5 <= -0.5)
		tmp = Float64(Float64(y_46_re * fma(-0.16666666666666666, Float64(Float64(y_46_re * y_46_re) * (atan(x_46_im, x_46_re) ^ 3.0)), atan(x_46_im, x_46_re))) * (sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re));
	elseif (t_5 <= -2e-159)
		tmp = t_6;
	elseif (t_5 <= 0.0)
		tmp = Float64(t_2 * t_3);
	elseif (t_5 <= 1.0)
		tmp = t_6;
	else
		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_3);
	end
	return tmp
end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[Exp[N[(N[(t$95$1 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[Sin[N[(N[(t$95$1 * y$46$im), $MachinePrecision] + t$95$3), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$5 = N[(t$95$2 * t$95$4), $MachinePrecision]}, Block[{t$95$6 = N[(t$95$4 * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * N[(0.0 - y$46$im), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$5, -0.5], N[(N[(y$46$re * N[(-0.16666666666666666 * N[(N[(y$46$re * y$46$re), $MachinePrecision] * N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision] + N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$5, -2e-159], t$95$6, If[LessEqual[t$95$5, 0.0], N[(t$95$2 * t$95$3), $MachinePrecision], If[LessEqual[t$95$5, 1.0], t$95$6, N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$3), $MachinePrecision]]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
t_1 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
t_2 := e^{t\_1 \cdot y.re - t\_0}\\
t_3 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_4 := \sin \left(t\_1 \cdot y.im + t\_3\right)\\
t_5 := t\_2 \cdot t\_4\\
t_6 := t\_4 \cdot \mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, 0 - y.im, 1\right)\\
\mathbf{if}\;t\_5 \leq -0.5:\\
\;\;\;\;\left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\

\mathbf{elif}\;t\_5 \leq -2 \cdot 10^{-159}:\\
\;\;\;\;t\_6\\

\mathbf{elif}\;t\_5 \leq 0:\\
\;\;\;\;t\_2 \cdot t\_3\\

\mathbf{elif}\;t\_5 \leq 1:\\
\;\;\;\;t\_6\\

\mathbf{else}:\\
\;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_3\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.5

    1. Initial program 48.0%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6448.1

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified48.1%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    6. Taylor expanded in y.re around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \left(\frac{-1}{6} \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right) + \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]
    7. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \left(\frac{-1}{6} \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right) + \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]
      2. accelerator-lowering-fma.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\mathsf{fma}\left(\frac{-1}{6}, {y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)}\right) \]
      3. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \color{blue}{{y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      4. unpow2N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \color{blue}{\left(y.re \cdot y.re\right)} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      5. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \color{blue}{\left(y.re \cdot y.re\right)} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      6. pow-lowering-pow.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot \color{blue}{{\tan^{-1}_* \frac{x.im}{x.re}}^{3}}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      7. atan2-lowering-atan2.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      8. atan2-lowering-atan2.f6461.1

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right)\right) \]
    8. Simplified61.1%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]
    9. Taylor expanded in y.im around 0

      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
    10. Step-by-step derivation
      1. pow-lowering-pow.f64N/A

        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      2. sqrt-lowering-sqrt.f64N/A

        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      3. unpow2N/A

        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      4. accelerator-lowering-fma.f64N/A

        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      5. unpow2N/A

        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      6. *-lowering-*.f6448.5

        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
    11. Simplified48.5%

      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]

    if -0.5 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -1.99999999999999998e-159 or -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < 1

    1. Initial program 93.0%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.re around 0

      \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    4. Step-by-step derivation
      1. mul-1-negN/A

        \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      2. neg-sub0N/A

        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      3. --lowering--.f64N/A

        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      5. atan2-lowering-atan2.f6491.9

        \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    5. Simplified91.9%

      \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    6. Taylor expanded in y.im around 0

      \[\leadsto \color{blue}{\left(1 + -1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    7. Step-by-step derivation
      1. neg-mul-1N/A

        \[\leadsto \left(1 + \color{blue}{\left(\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right)}\right) \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      2. +-commutativeN/A

        \[\leadsto \color{blue}{\left(\left(\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right) + 1\right)} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      3. *-commutativeN/A

        \[\leadsto \left(\left(\mathsf{neg}\left(\color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}\right)\right) + 1\right) \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      4. distribute-rgt-neg-inN/A

        \[\leadsto \left(\color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot \left(\mathsf{neg}\left(y.im\right)\right)} + 1\right) \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      5. neg-mul-1N/A

        \[\leadsto \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot \color{blue}{\left(-1 \cdot y.im\right)} + 1\right) \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      6. accelerator-lowering-fma.f64N/A

        \[\leadsto \color{blue}{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, -1 \cdot y.im, 1\right)} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      7. atan2-lowering-atan2.f64N/A

        \[\leadsto \mathsf{fma}\left(\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}, -1 \cdot y.im, 1\right) \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      8. neg-mul-1N/A

        \[\leadsto \mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, \color{blue}{\mathsf{neg}\left(y.im\right)}, 1\right) \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      9. neg-sub0N/A

        \[\leadsto \mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, \color{blue}{0 - y.im}, 1\right) \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      10. --lowering--.f6489.8

        \[\leadsto \mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, \color{blue}{0 - y.im}, 1\right) \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    8. Simplified89.8%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, 0 - y.im, 1\right)} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]

    if -1.99999999999999998e-159 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0

    1. Initial program 100.0%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f64100.0

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified100.0%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    6. Taylor expanded in y.re around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    7. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f64100.0

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    8. Simplified100.0%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

    if 1 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

    1. Initial program 10.6%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6444.6

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified44.6%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    6. Taylor expanded in y.re around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    7. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6444.0

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    8. Simplified44.0%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    9. Taylor expanded in x.re around inf

      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    10. Step-by-step derivation
      1. unpow2N/A

        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
      2. *-lowering-*.f6443.2

        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    11. Simplified43.2%

      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    12. Step-by-step derivation
      1. rem-sqrt-squareN/A

        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
      2. fabs-lowering-fabs.f6458.0

        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
    13. Applied egg-rr58.0%

      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
  3. Recombined 4 regimes into one program.
  4. Final simplification67.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -0.5:\\ \;\;\;\;\left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -2 \cdot 10^{-159}:\\ \;\;\;\;\sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot \mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, 0 - y.im, 1\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 1:\\ \;\;\;\;\sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot \mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, 0 - y.im, 1\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 62.3% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_3 := e^{t\_2 \cdot y.re - t\_0}\\ t_4 := t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\ t_5 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\ \mathbf{if}\;t\_4 \leq -0.5:\\ \;\;\;\;\left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;t\_4 \leq -5 \cdot 10^{-179}:\\ \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, t\_5, y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\ \mathbf{elif}\;t\_4 \leq 0:\\ \;\;\;\;t\_3 \cdot t\_1\\ \mathbf{elif}\;t\_4 \leq 1:\\ \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(t\_5, -0.5, \frac{t\_1}{0 - y.im}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\ \end{array} \end{array} \]
(FPCore (x.re x.im y.re y.im)
 :precision binary64
 (let* ((t_0 (* (atan2 x.im x.re) y.im))
        (t_1 (* y.re (atan2 x.im x.re)))
        (t_2 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
        (t_3 (exp (- (* t_2 y.re) t_0)))
        (t_4 (* t_3 (sin (+ (* t_2 y.im) t_1))))
        (t_5 (log (fma x.re x.re (* x.im x.im)))))
   (if (<= t_4 -0.5)
     (*
      (*
       y.re
       (fma
        -0.16666666666666666
        (* (* y.re y.re) (pow (atan2 x.im x.re) 3.0))
        (atan2 x.im x.re)))
      (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re))
     (if (<= t_4 -5e-179)
       (sin (* y.im (fma 0.5 t_5 (* y.re (/ (atan2 x.im x.re) y.im)))))
       (if (<= t_4 0.0)
         (* t_3 t_1)
         (if (<= t_4 1.0)
           (sin (* (- 0.0 y.im) (fma t_5 -0.5 (/ t_1 (- 0.0 y.im)))))
           (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_1)))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
	double t_1 = y_46_re * atan2(x_46_im, x_46_re);
	double t_2 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
	double t_3 = exp(((t_2 * y_46_re) - t_0));
	double t_4 = t_3 * sin(((t_2 * y_46_im) + t_1));
	double t_5 = log(fma(x_46_re, x_46_re, (x_46_im * x_46_im)));
	double tmp;
	if (t_4 <= -0.5) {
		tmp = (y_46_re * fma(-0.16666666666666666, ((y_46_re * y_46_re) * pow(atan2(x_46_im, x_46_re), 3.0)), atan2(x_46_im, x_46_re))) * pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
	} else if (t_4 <= -5e-179) {
		tmp = sin((y_46_im * fma(0.5, t_5, (y_46_re * (atan2(x_46_im, x_46_re) / y_46_im)))));
	} else if (t_4 <= 0.0) {
		tmp = t_3 * t_1;
	} else if (t_4 <= 1.0) {
		tmp = sin(((0.0 - y_46_im) * fma(t_5, -0.5, (t_1 / (0.0 - y_46_im)))));
	} else {
		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_1;
	}
	return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im)
	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
	t_1 = Float64(y_46_re * atan(x_46_im, x_46_re))
	t_2 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
	t_3 = exp(Float64(Float64(t_2 * y_46_re) - t_0))
	t_4 = Float64(t_3 * sin(Float64(Float64(t_2 * y_46_im) + t_1)))
	t_5 = log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im)))
	tmp = 0.0
	if (t_4 <= -0.5)
		tmp = Float64(Float64(y_46_re * fma(-0.16666666666666666, Float64(Float64(y_46_re * y_46_re) * (atan(x_46_im, x_46_re) ^ 3.0)), atan(x_46_im, x_46_re))) * (sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re));
	elseif (t_4 <= -5e-179)
		tmp = sin(Float64(y_46_im * fma(0.5, t_5, Float64(y_46_re * Float64(atan(x_46_im, x_46_re) / y_46_im)))));
	elseif (t_4 <= 0.0)
		tmp = Float64(t_3 * t_1);
	elseif (t_4 <= 1.0)
		tmp = sin(Float64(Float64(0.0 - y_46_im) * fma(t_5, -0.5, Float64(t_1 / Float64(0.0 - y_46_im)))));
	else
		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_1);
	end
	return tmp
end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[Exp[N[(N[(t$95$2 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$4 = N[(t$95$3 * N[Sin[N[(N[(t$95$2 * y$46$im), $MachinePrecision] + t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$4, -0.5], N[(N[(y$46$re * N[(-0.16666666666666666 * N[(N[(y$46$re * y$46$re), $MachinePrecision] * N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision] + N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$4, -5e-179], N[Sin[N[(y$46$im * N[(0.5 * t$95$5 + N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] / y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$4, 0.0], N[(t$95$3 * t$95$1), $MachinePrecision], If[LessEqual[t$95$4, 1.0], N[Sin[N[(N[(0.0 - y$46$im), $MachinePrecision] * N[(t$95$5 * -0.5 + N[(t$95$1 / N[(0.0 - y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$1), $MachinePrecision]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
t_3 := e^{t\_2 \cdot y.re - t\_0}\\
t_4 := t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\
t_5 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\
\mathbf{if}\;t\_4 \leq -0.5:\\
\;\;\;\;\left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\

\mathbf{elif}\;t\_4 \leq -5 \cdot 10^{-179}:\\
\;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, t\_5, y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\

\mathbf{elif}\;t\_4 \leq 0:\\
\;\;\;\;t\_3 \cdot t\_1\\

\mathbf{elif}\;t\_4 \leq 1:\\
\;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(t\_5, -0.5, \frac{t\_1}{0 - y.im}\right)\right)\\

\mathbf{else}:\\
\;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.5

    1. Initial program 48.0%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Taylor expanded in y.im around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    4. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      2. atan2-lowering-atan2.f6448.1

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
    5. Simplified48.1%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
    6. Taylor expanded in y.re around 0

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \left(\frac{-1}{6} \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right) + \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]
    7. Step-by-step derivation
      1. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \left(\frac{-1}{6} \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right) + \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]
      2. accelerator-lowering-fma.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\mathsf{fma}\left(\frac{-1}{6}, {y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)}\right) \]
      3. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \color{blue}{{y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      4. unpow2N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \color{blue}{\left(y.re \cdot y.re\right)} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      5. *-lowering-*.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \color{blue}{\left(y.re \cdot y.re\right)} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      6. pow-lowering-pow.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot \color{blue}{{\tan^{-1}_* \frac{x.im}{x.re}}^{3}}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      7. atan2-lowering-atan2.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      8. atan2-lowering-atan2.f6461.1

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right)\right) \]
    8. Simplified61.1%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \]
    9. Taylor expanded in y.im around 0

      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
    10. Step-by-step derivation
      1. pow-lowering-pow.f64N/A

        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      2. sqrt-lowering-sqrt.f64N/A

        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      3. unpow2N/A

        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      4. accelerator-lowering-fma.f64N/A

        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      5. unpow2N/A

        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \left(y.re \cdot \mathsf{fma}\left(\frac{-1}{6}, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
      6. *-lowering-*.f6448.5

        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]
    11. Simplified48.5%

      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \]

    if -0.5 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -4.9999999999999998e-179

    1. Initial program 99.5%

      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. flip3-+N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
      2. clear-numN/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
      3. /-lowering-/.f64N/A

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
    4. Applied egg-rr99.4%

      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
    5. Taylor expanded in y.im around 0

      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
    6. Step-by-step derivation
      1. pow-lowering-pow.f64N/A

        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
      2. sqrt-lowering-sqrt.f64N/A

        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
      3. unpow2N/A

        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
      4. accelerator-lowering-fma.f64N/A

        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
      5. unpow2N/A

        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
      6. *-lowering-*.f6496.0

        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
    7. Simplified96.0%

      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
    8. Taylor expanded in y.re around 0

      \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
    9. Step-by-step derivation
      1. Simplified96.0%

        \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
      2. Taylor expanded in y.im around inf

        \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \left(\frac{1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right) + \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]
      3. Step-by-step derivation
        1. *-lowering-*.f64N/A

          \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \left(\frac{1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right) + \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]
        2. accelerator-lowering-fma.f64N/A

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \color{blue}{\mathsf{fma}\left(\frac{1}{2}, \log \left({x.im}^{2} + {x.re}^{2}\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)}\right) \]
        3. log-lowering-log.f64N/A

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \color{blue}{\log \left({x.im}^{2} + {x.re}^{2}\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
        4. +-commutativeN/A

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \color{blue}{\left({x.re}^{2} + {x.im}^{2}\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
        5. unpow2N/A

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\color{blue}{x.re \cdot x.re} + {x.im}^{2}\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
        6. accelerator-lowering-fma.f64N/A

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, {x.im}^{2}\right)\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
        7. unpow2N/A

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
        9. associate-/l*N/A

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
        10. *-lowering-*.f64N/A

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
        11. /-lowering-/.f64N/A

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \color{blue}{\frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
        12. atan2-lowering-atan2.f6496.3

          \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}{y.im}\right)\right) \]
      4. Simplified96.3%

        \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]

      if -4.9999999999999998e-179 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0

      1. Initial program 100.0%

        \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      2. Add Preprocessing
      3. Taylor expanded in y.im around 0

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      4. Step-by-step derivation
        1. *-lowering-*.f64N/A

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
        2. atan2-lowering-atan2.f64100.0

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
      5. Simplified100.0%

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      6. Taylor expanded in y.re around 0

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
      7. Step-by-step derivation
        1. *-lowering-*.f64N/A

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
        2. atan2-lowering-atan2.f64100.0

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
      8. Simplified100.0%

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

      if -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < 1

      1. Initial program 87.9%

        \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. flip3-+N/A

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
        2. clear-numN/A

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
        3. /-lowering-/.f64N/A

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
      4. Applied egg-rr87.9%

        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
      5. Taylor expanded in y.im around 0

        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
      6. Step-by-step derivation
        1. pow-lowering-pow.f64N/A

          \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
        2. sqrt-lowering-sqrt.f64N/A

          \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
        3. unpow2N/A

          \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
        4. accelerator-lowering-fma.f64N/A

          \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
        5. unpow2N/A

          \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
        6. *-lowering-*.f6485.2

          \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
      7. Simplified85.2%

        \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
      8. Taylor expanded in y.re around 0

        \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
      9. Step-by-step derivation
        1. Simplified83.1%

          \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
        2. Taylor expanded in y.im around -inf

          \[\leadsto 1 \cdot \sin \color{blue}{\left(-1 \cdot \left(y.im \cdot \left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)\right)} \]
        3. Step-by-step derivation
          1. mul-1-negN/A

            \[\leadsto 1 \cdot \sin \color{blue}{\left(\mathsf{neg}\left(y.im \cdot \left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)\right)} \]
          2. *-commutativeN/A

            \[\leadsto 1 \cdot \sin \left(\mathsf{neg}\left(\color{blue}{\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot y.im}\right)\right) \]
          3. distribute-rgt-neg-inN/A

            \[\leadsto 1 \cdot \sin \color{blue}{\left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \left(\mathsf{neg}\left(y.im\right)\right)\right)} \]
          4. neg-mul-1N/A

            \[\leadsto 1 \cdot \sin \left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \color{blue}{\left(-1 \cdot y.im\right)}\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto 1 \cdot \sin \color{blue}{\left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \left(-1 \cdot y.im\right)\right)} \]
        4. Simplified83.3%

          \[\leadsto 1 \cdot \sin \color{blue}{\left(\mathsf{fma}\left(\log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), -0.5, \frac{y.re \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}{y.im}\right) \cdot \left(0 - y.im\right)\right)} \]

        if 1 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

        1. Initial program 10.6%

          \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
        2. Add Preprocessing
        3. Taylor expanded in y.im around 0

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
        4. Step-by-step derivation
          1. *-lowering-*.f64N/A

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
          2. atan2-lowering-atan2.f6444.6

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
        5. Simplified44.6%

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
        6. Taylor expanded in y.re around 0

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
        7. Step-by-step derivation
          1. *-lowering-*.f64N/A

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
          2. atan2-lowering-atan2.f6444.0

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
        8. Simplified44.0%

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
        9. Taylor expanded in x.re around inf

          \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
        10. Step-by-step derivation
          1. unpow2N/A

            \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
          2. *-lowering-*.f6443.2

            \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
        11. Simplified43.2%

          \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
        12. Step-by-step derivation
          1. rem-sqrt-squareN/A

            \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
          2. fabs-lowering-fabs.f6458.0

            \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
        13. Applied egg-rr58.0%

          \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
      10. Recombined 5 regimes into one program.
      11. Final simplification67.4%

        \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -0.5:\\ \;\;\;\;\left(y.re \cdot \mathsf{fma}\left(-0.16666666666666666, \left(y.re \cdot y.re\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -5 \cdot 10^{-179}:\\ \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 1:\\ \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(\log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), -0.5, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{0 - y.im}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
      12. Add Preprocessing

      Alternative 5: 63.4% accurate, 0.2× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_3 := \mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\\ t_4 := e^{t\_2 \cdot y.re - t\_0}\\ t_5 := t\_4 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\ t_6 := \log t\_3\\ \mathbf{if}\;t\_5 \leq -0.5:\\ \;\;\;\;t\_1 \cdot \frac{{t\_3}^{\left(y.re \cdot 0.5\right)}}{e^{t\_0}}\\ \mathbf{elif}\;t\_5 \leq -5 \cdot 10^{-179}:\\ \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, t\_6, y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\ \mathbf{elif}\;t\_5 \leq 0:\\ \;\;\;\;t\_4 \cdot t\_1\\ \mathbf{elif}\;t\_5 \leq 1:\\ \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(t\_6, -0.5, \frac{t\_1}{0 - y.im}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\ \end{array} \end{array} \]
      (FPCore (x.re x.im y.re y.im)
       :precision binary64
       (let* ((t_0 (* (atan2 x.im x.re) y.im))
              (t_1 (* y.re (atan2 x.im x.re)))
              (t_2 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
              (t_3 (fma x.re x.re (* x.im x.im)))
              (t_4 (exp (- (* t_2 y.re) t_0)))
              (t_5 (* t_4 (sin (+ (* t_2 y.im) t_1))))
              (t_6 (log t_3)))
         (if (<= t_5 -0.5)
           (* t_1 (/ (pow t_3 (* y.re 0.5)) (exp t_0)))
           (if (<= t_5 -5e-179)
             (sin (* y.im (fma 0.5 t_6 (* y.re (/ (atan2 x.im x.re) y.im)))))
             (if (<= t_5 0.0)
               (* t_4 t_1)
               (if (<= t_5 1.0)
                 (sin (* (- 0.0 y.im) (fma t_6 -0.5 (/ t_1 (- 0.0 y.im)))))
                 (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_1)))))))
      double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
      	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
      	double t_1 = y_46_re * atan2(x_46_im, x_46_re);
      	double t_2 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
      	double t_3 = fma(x_46_re, x_46_re, (x_46_im * x_46_im));
      	double t_4 = exp(((t_2 * y_46_re) - t_0));
      	double t_5 = t_4 * sin(((t_2 * y_46_im) + t_1));
      	double t_6 = log(t_3);
      	double tmp;
      	if (t_5 <= -0.5) {
      		tmp = t_1 * (pow(t_3, (y_46_re * 0.5)) / exp(t_0));
      	} else if (t_5 <= -5e-179) {
      		tmp = sin((y_46_im * fma(0.5, t_6, (y_46_re * (atan2(x_46_im, x_46_re) / y_46_im)))));
      	} else if (t_5 <= 0.0) {
      		tmp = t_4 * t_1;
      	} else if (t_5 <= 1.0) {
      		tmp = sin(((0.0 - y_46_im) * fma(t_6, -0.5, (t_1 / (0.0 - y_46_im)))));
      	} else {
      		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_1;
      	}
      	return tmp;
      }
      
      function code(x_46_re, x_46_im, y_46_re, y_46_im)
      	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
      	t_1 = Float64(y_46_re * atan(x_46_im, x_46_re))
      	t_2 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
      	t_3 = fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im))
      	t_4 = exp(Float64(Float64(t_2 * y_46_re) - t_0))
      	t_5 = Float64(t_4 * sin(Float64(Float64(t_2 * y_46_im) + t_1)))
      	t_6 = log(t_3)
      	tmp = 0.0
      	if (t_5 <= -0.5)
      		tmp = Float64(t_1 * Float64((t_3 ^ Float64(y_46_re * 0.5)) / exp(t_0)));
      	elseif (t_5 <= -5e-179)
      		tmp = sin(Float64(y_46_im * fma(0.5, t_6, Float64(y_46_re * Float64(atan(x_46_im, x_46_re) / y_46_im)))));
      	elseif (t_5 <= 0.0)
      		tmp = Float64(t_4 * t_1);
      	elseif (t_5 <= 1.0)
      		tmp = sin(Float64(Float64(0.0 - y_46_im) * fma(t_6, -0.5, Float64(t_1 / Float64(0.0 - y_46_im)))));
      	else
      		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_1);
      	end
      	return tmp
      end
      
      code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[Exp[N[(N[(t$95$2 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$5 = N[(t$95$4 * N[Sin[N[(N[(t$95$2 * y$46$im), $MachinePrecision] + t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[Log[t$95$3], $MachinePrecision]}, If[LessEqual[t$95$5, -0.5], N[(t$95$1 * N[(N[Power[t$95$3, N[(y$46$re * 0.5), $MachinePrecision]], $MachinePrecision] / N[Exp[t$95$0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$5, -5e-179], N[Sin[N[(y$46$im * N[(0.5 * t$95$6 + N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] / y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$5, 0.0], N[(t$95$4 * t$95$1), $MachinePrecision], If[LessEqual[t$95$5, 1.0], N[Sin[N[(N[(0.0 - y$46$im), $MachinePrecision] * N[(t$95$6 * -0.5 + N[(t$95$1 / N[(0.0 - y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$1), $MachinePrecision]]]]]]]]]]]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
      t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
      t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
      t_3 := \mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\\
      t_4 := e^{t\_2 \cdot y.re - t\_0}\\
      t_5 := t\_4 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\
      t_6 := \log t\_3\\
      \mathbf{if}\;t\_5 \leq -0.5:\\
      \;\;\;\;t\_1 \cdot \frac{{t\_3}^{\left(y.re \cdot 0.5\right)}}{e^{t\_0}}\\
      
      \mathbf{elif}\;t\_5 \leq -5 \cdot 10^{-179}:\\
      \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, t\_6, y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\
      
      \mathbf{elif}\;t\_5 \leq 0:\\
      \;\;\;\;t\_4 \cdot t\_1\\
      
      \mathbf{elif}\;t\_5 \leq 1:\\
      \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(t\_6, -0.5, \frac{t\_1}{0 - y.im}\right)\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 5 regimes
      2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.5

        1. Initial program 48.0%

          \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
        2. Add Preprocessing
        3. Taylor expanded in y.im around 0

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
        4. Step-by-step derivation
          1. *-lowering-*.f64N/A

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
          2. atan2-lowering-atan2.f6448.1

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
        5. Simplified48.1%

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
        6. Taylor expanded in y.re around 0

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
        7. Step-by-step derivation
          1. *-lowering-*.f64N/A

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
          2. atan2-lowering-atan2.f6435.1

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
        8. Simplified35.1%

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
        9. Step-by-step derivation
          1. exp-diffN/A

            \[\leadsto \color{blue}{\frac{e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re}}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
          2. +-commutativeN/A

            \[\leadsto \frac{e^{\log \left(\sqrt{\color{blue}{x.im \cdot x.im + x.re \cdot x.re}}\right) \cdot y.re}}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
          3. pow-to-expN/A

            \[\leadsto \frac{\color{blue}{{\left(\sqrt{x.im \cdot x.im + x.re \cdot x.re}\right)}^{y.re}}}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
          4. frac-2negN/A

            \[\leadsto \color{blue}{\frac{\mathsf{neg}\left({\left(\sqrt{x.im \cdot x.im + x.re \cdot x.re}\right)}^{y.re}\right)}{\mathsf{neg}\left(e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}\right)}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
          5. /-lowering-/.f64N/A

            \[\leadsto \color{blue}{\frac{\mathsf{neg}\left({\left(\sqrt{x.im \cdot x.im + x.re \cdot x.re}\right)}^{y.re}\right)}{\mathsf{neg}\left(e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}\right)}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
        10. Applied egg-rr39.4%

          \[\leadsto \color{blue}{\frac{0 - {\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}^{\left(y.re \cdot 0.5\right)}}{0 - e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

        if -0.5 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -4.9999999999999998e-179

        1. Initial program 99.5%

          \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
        2. Add Preprocessing
        3. Step-by-step derivation
          1. flip3-+N/A

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
          2. clear-numN/A

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
          3. /-lowering-/.f64N/A

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
        4. Applied egg-rr99.4%

          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
        5. Taylor expanded in y.im around 0

          \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
        6. Step-by-step derivation
          1. pow-lowering-pow.f64N/A

            \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
          2. sqrt-lowering-sqrt.f64N/A

            \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
          3. unpow2N/A

            \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
          4. accelerator-lowering-fma.f64N/A

            \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
          5. unpow2N/A

            \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
          6. *-lowering-*.f6496.0

            \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
        7. Simplified96.0%

          \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
        8. Taylor expanded in y.re around 0

          \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
        9. Step-by-step derivation
          1. Simplified96.0%

            \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
          2. Taylor expanded in y.im around inf

            \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \left(\frac{1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right) + \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]
          3. Step-by-step derivation
            1. *-lowering-*.f64N/A

              \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \left(\frac{1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right) + \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]
            2. accelerator-lowering-fma.f64N/A

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \color{blue}{\mathsf{fma}\left(\frac{1}{2}, \log \left({x.im}^{2} + {x.re}^{2}\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)}\right) \]
            3. log-lowering-log.f64N/A

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \color{blue}{\log \left({x.im}^{2} + {x.re}^{2}\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
            4. +-commutativeN/A

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \color{blue}{\left({x.re}^{2} + {x.im}^{2}\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
            5. unpow2N/A

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\color{blue}{x.re \cdot x.re} + {x.im}^{2}\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
            6. accelerator-lowering-fma.f64N/A

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, {x.im}^{2}\right)\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
            7. unpow2N/A

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
            8. *-lowering-*.f64N/A

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
            9. associate-/l*N/A

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
            10. *-lowering-*.f64N/A

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
            11. /-lowering-/.f64N/A

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \color{blue}{\frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
            12. atan2-lowering-atan2.f6496.3

              \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}{y.im}\right)\right) \]
          4. Simplified96.3%

            \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]

          if -4.9999999999999998e-179 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0

          1. Initial program 100.0%

            \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
          2. Add Preprocessing
          3. Taylor expanded in y.im around 0

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
          4. Step-by-step derivation
            1. *-lowering-*.f64N/A

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
            2. atan2-lowering-atan2.f64100.0

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
          5. Simplified100.0%

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
          6. Taylor expanded in y.re around 0

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
          7. Step-by-step derivation
            1. *-lowering-*.f64N/A

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
            2. atan2-lowering-atan2.f64100.0

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
          8. Simplified100.0%

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

          if -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < 1

          1. Initial program 87.9%

            \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
          2. Add Preprocessing
          3. Step-by-step derivation
            1. flip3-+N/A

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
            2. clear-numN/A

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
            3. /-lowering-/.f64N/A

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
          4. Applied egg-rr87.9%

            \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
          5. Taylor expanded in y.im around 0

            \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
          6. Step-by-step derivation
            1. pow-lowering-pow.f64N/A

              \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
            2. sqrt-lowering-sqrt.f64N/A

              \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
            3. unpow2N/A

              \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
            4. accelerator-lowering-fma.f64N/A

              \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
            5. unpow2N/A

              \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
            6. *-lowering-*.f6485.2

              \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
          7. Simplified85.2%

            \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
          8. Taylor expanded in y.re around 0

            \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
          9. Step-by-step derivation
            1. Simplified83.1%

              \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
            2. Taylor expanded in y.im around -inf

              \[\leadsto 1 \cdot \sin \color{blue}{\left(-1 \cdot \left(y.im \cdot \left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)\right)} \]
            3. Step-by-step derivation
              1. mul-1-negN/A

                \[\leadsto 1 \cdot \sin \color{blue}{\left(\mathsf{neg}\left(y.im \cdot \left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)\right)} \]
              2. *-commutativeN/A

                \[\leadsto 1 \cdot \sin \left(\mathsf{neg}\left(\color{blue}{\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot y.im}\right)\right) \]
              3. distribute-rgt-neg-inN/A

                \[\leadsto 1 \cdot \sin \color{blue}{\left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \left(\mathsf{neg}\left(y.im\right)\right)\right)} \]
              4. neg-mul-1N/A

                \[\leadsto 1 \cdot \sin \left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \color{blue}{\left(-1 \cdot y.im\right)}\right) \]
              5. *-lowering-*.f64N/A

                \[\leadsto 1 \cdot \sin \color{blue}{\left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \left(-1 \cdot y.im\right)\right)} \]
            4. Simplified83.3%

              \[\leadsto 1 \cdot \sin \color{blue}{\left(\mathsf{fma}\left(\log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), -0.5, \frac{y.re \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}{y.im}\right) \cdot \left(0 - y.im\right)\right)} \]

            if 1 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

            1. Initial program 10.6%

              \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
            2. Add Preprocessing
            3. Taylor expanded in y.im around 0

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
            4. Step-by-step derivation
              1. *-lowering-*.f64N/A

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
              2. atan2-lowering-atan2.f6444.6

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
            5. Simplified44.6%

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
            6. Taylor expanded in y.re around 0

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
            7. Step-by-step derivation
              1. *-lowering-*.f64N/A

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
              2. atan2-lowering-atan2.f6444.0

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
            8. Simplified44.0%

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
            9. Taylor expanded in x.re around inf

              \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
            10. Step-by-step derivation
              1. unpow2N/A

                \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
              2. *-lowering-*.f6443.2

                \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
            11. Simplified43.2%

              \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
            12. Step-by-step derivation
              1. rem-sqrt-squareN/A

                \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
              2. fabs-lowering-fabs.f6458.0

                \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
            13. Applied egg-rr58.0%

              \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
          10. Recombined 5 regimes into one program.
          11. Final simplification66.2%

            \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -0.5:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot \frac{{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}^{\left(y.re \cdot 0.5\right)}}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -5 \cdot 10^{-179}:\\ \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 1:\\ \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(\log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), -0.5, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{0 - y.im}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
          12. Add Preprocessing

          Alternative 6: 61.4% accurate, 0.2× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_2 := e^{t\_1 \cdot y.re - t\_0}\\ t_3 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_4 := t\_2 \cdot \sin \left(t\_1 \cdot y.im + t\_3\right)\\ t_5 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\ \mathbf{if}\;t\_4 \leq -0.5:\\ \;\;\;\;y.re \cdot \mathsf{fma}\left(-0.16666666666666666 \cdot \left(y.re \cdot y.re\right), {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;t\_4 \leq -5 \cdot 10^{-179}:\\ \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, t\_5, y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\ \mathbf{elif}\;t\_4 \leq 0:\\ \;\;\;\;t\_2 \cdot t\_3\\ \mathbf{elif}\;t\_4 \leq 1:\\ \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(t\_5, -0.5, \frac{t\_3}{0 - y.im}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_3\\ \end{array} \end{array} \]
          (FPCore (x.re x.im y.re y.im)
           :precision binary64
           (let* ((t_0 (* (atan2 x.im x.re) y.im))
                  (t_1 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
                  (t_2 (exp (- (* t_1 y.re) t_0)))
                  (t_3 (* y.re (atan2 x.im x.re)))
                  (t_4 (* t_2 (sin (+ (* t_1 y.im) t_3))))
                  (t_5 (log (fma x.re x.re (* x.im x.im)))))
             (if (<= t_4 -0.5)
               (*
                y.re
                (fma
                 (* -0.16666666666666666 (* y.re y.re))
                 (pow (atan2 x.im x.re) 3.0)
                 (atan2 x.im x.re)))
               (if (<= t_4 -5e-179)
                 (sin (* y.im (fma 0.5 t_5 (* y.re (/ (atan2 x.im x.re) y.im)))))
                 (if (<= t_4 0.0)
                   (* t_2 t_3)
                   (if (<= t_4 1.0)
                     (sin (* (- 0.0 y.im) (fma t_5 -0.5 (/ t_3 (- 0.0 y.im)))))
                     (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_3)))))))
          double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
          	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
          	double t_1 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
          	double t_2 = exp(((t_1 * y_46_re) - t_0));
          	double t_3 = y_46_re * atan2(x_46_im, x_46_re);
          	double t_4 = t_2 * sin(((t_1 * y_46_im) + t_3));
          	double t_5 = log(fma(x_46_re, x_46_re, (x_46_im * x_46_im)));
          	double tmp;
          	if (t_4 <= -0.5) {
          		tmp = y_46_re * fma((-0.16666666666666666 * (y_46_re * y_46_re)), pow(atan2(x_46_im, x_46_re), 3.0), atan2(x_46_im, x_46_re));
          	} else if (t_4 <= -5e-179) {
          		tmp = sin((y_46_im * fma(0.5, t_5, (y_46_re * (atan2(x_46_im, x_46_re) / y_46_im)))));
          	} else if (t_4 <= 0.0) {
          		tmp = t_2 * t_3;
          	} else if (t_4 <= 1.0) {
          		tmp = sin(((0.0 - y_46_im) * fma(t_5, -0.5, (t_3 / (0.0 - y_46_im)))));
          	} else {
          		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_3;
          	}
          	return tmp;
          }
          
          function code(x_46_re, x_46_im, y_46_re, y_46_im)
          	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
          	t_1 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
          	t_2 = exp(Float64(Float64(t_1 * y_46_re) - t_0))
          	t_3 = Float64(y_46_re * atan(x_46_im, x_46_re))
          	t_4 = Float64(t_2 * sin(Float64(Float64(t_1 * y_46_im) + t_3)))
          	t_5 = log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im)))
          	tmp = 0.0
          	if (t_4 <= -0.5)
          		tmp = Float64(y_46_re * fma(Float64(-0.16666666666666666 * Float64(y_46_re * y_46_re)), (atan(x_46_im, x_46_re) ^ 3.0), atan(x_46_im, x_46_re)));
          	elseif (t_4 <= -5e-179)
          		tmp = sin(Float64(y_46_im * fma(0.5, t_5, Float64(y_46_re * Float64(atan(x_46_im, x_46_re) / y_46_im)))));
          	elseif (t_4 <= 0.0)
          		tmp = Float64(t_2 * t_3);
          	elseif (t_4 <= 1.0)
          		tmp = sin(Float64(Float64(0.0 - y_46_im) * fma(t_5, -0.5, Float64(t_3 / Float64(0.0 - y_46_im)))));
          	else
          		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_3);
          	end
          	return tmp
          end
          
          code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[Exp[N[(N[(t$95$1 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(t$95$2 * N[Sin[N[(N[(t$95$1 * y$46$im), $MachinePrecision] + t$95$3), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$4, -0.5], N[(y$46$re * N[(N[(-0.16666666666666666 * N[(y$46$re * y$46$re), $MachinePrecision]), $MachinePrecision] * N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 3.0], $MachinePrecision] + N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$4, -5e-179], N[Sin[N[(y$46$im * N[(0.5 * t$95$5 + N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] / y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$4, 0.0], N[(t$95$2 * t$95$3), $MachinePrecision], If[LessEqual[t$95$4, 1.0], N[Sin[N[(N[(0.0 - y$46$im), $MachinePrecision] * N[(t$95$5 * -0.5 + N[(t$95$3 / N[(0.0 - y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$3), $MachinePrecision]]]]]]]]]]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
          t_1 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
          t_2 := e^{t\_1 \cdot y.re - t\_0}\\
          t_3 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
          t_4 := t\_2 \cdot \sin \left(t\_1 \cdot y.im + t\_3\right)\\
          t_5 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\
          \mathbf{if}\;t\_4 \leq -0.5:\\
          \;\;\;\;y.re \cdot \mathsf{fma}\left(-0.16666666666666666 \cdot \left(y.re \cdot y.re\right), {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\\
          
          \mathbf{elif}\;t\_4 \leq -5 \cdot 10^{-179}:\\
          \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, t\_5, y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\
          
          \mathbf{elif}\;t\_4 \leq 0:\\
          \;\;\;\;t\_2 \cdot t\_3\\
          
          \mathbf{elif}\;t\_4 \leq 1:\\
          \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(t\_5, -0.5, \frac{t\_3}{0 - y.im}\right)\right)\\
          
          \mathbf{else}:\\
          \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_3\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 5 regimes
          2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.5

            1. Initial program 48.0%

              \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
            2. Add Preprocessing
            3. Taylor expanded in y.re around 0

              \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
            4. Step-by-step derivation
              1. mul-1-negN/A

                \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
              2. neg-sub0N/A

                \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
              3. --lowering--.f64N/A

                \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
              4. *-lowering-*.f64N/A

                \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
              5. atan2-lowering-atan2.f6414.5

                \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
            5. Simplified14.5%

              \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
            6. Taylor expanded in y.im around 0

              \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
            7. Step-by-step derivation
              1. sin-lowering-sin.f64N/A

                \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
              2. *-lowering-*.f64N/A

                \[\leadsto \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
              3. atan2-lowering-atan2.f642.0

                \[\leadsto \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
            8. Simplified2.0%

              \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
            9. Taylor expanded in y.re around 0

              \[\leadsto \color{blue}{y.re \cdot \left(\frac{-1}{6} \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right) + \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
            10. Step-by-step derivation
              1. *-lowering-*.f64N/A

                \[\leadsto \color{blue}{y.re \cdot \left(\frac{-1}{6} \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right) + \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
              2. associate-*r*N/A

                \[\leadsto y.re \cdot \left(\color{blue}{\left(\frac{-1}{6} \cdot {y.re}^{2}\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}} + \tan^{-1}_* \frac{x.im}{x.re}\right) \]
              3. accelerator-lowering-fma.f64N/A

                \[\leadsto y.re \cdot \color{blue}{\mathsf{fma}\left(\frac{-1}{6} \cdot {y.re}^{2}, {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
              4. *-lowering-*.f64N/A

                \[\leadsto y.re \cdot \mathsf{fma}\left(\color{blue}{\frac{-1}{6} \cdot {y.re}^{2}}, {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right) \]
              5. unpow2N/A

                \[\leadsto y.re \cdot \mathsf{fma}\left(\frac{-1}{6} \cdot \color{blue}{\left(y.re \cdot y.re\right)}, {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right) \]
              6. *-lowering-*.f64N/A

                \[\leadsto y.re \cdot \mathsf{fma}\left(\frac{-1}{6} \cdot \color{blue}{\left(y.re \cdot y.re\right)}, {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right) \]
              7. pow-lowering-pow.f64N/A

                \[\leadsto y.re \cdot \mathsf{fma}\left(\frac{-1}{6} \cdot \left(y.re \cdot y.re\right), \color{blue}{{\tan^{-1}_* \frac{x.im}{x.re}}^{3}}, \tan^{-1}_* \frac{x.im}{x.re}\right) \]
              8. atan2-lowering-atan2.f64N/A

                \[\leadsto y.re \cdot \mathsf{fma}\left(\frac{-1}{6} \cdot \left(y.re \cdot y.re\right), {\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right) \]
              9. atan2-lowering-atan2.f6436.1

                \[\leadsto y.re \cdot \mathsf{fma}\left(-0.16666666666666666 \cdot \left(y.re \cdot y.re\right), {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
            11. Simplified36.1%

              \[\leadsto \color{blue}{y.re \cdot \mathsf{fma}\left(-0.16666666666666666 \cdot \left(y.re \cdot y.re\right), {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

            if -0.5 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -4.9999999999999998e-179

            1. Initial program 99.5%

              \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
            2. Add Preprocessing
            3. Step-by-step derivation
              1. flip3-+N/A

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
              2. clear-numN/A

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
              3. /-lowering-/.f64N/A

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
            4. Applied egg-rr99.4%

              \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
            5. Taylor expanded in y.im around 0

              \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
            6. Step-by-step derivation
              1. pow-lowering-pow.f64N/A

                \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
              2. sqrt-lowering-sqrt.f64N/A

                \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
              3. unpow2N/A

                \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
              4. accelerator-lowering-fma.f64N/A

                \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
              5. unpow2N/A

                \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
              6. *-lowering-*.f6496.0

                \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
            7. Simplified96.0%

              \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
            8. Taylor expanded in y.re around 0

              \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
            9. Step-by-step derivation
              1. Simplified96.0%

                \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
              2. Taylor expanded in y.im around inf

                \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \left(\frac{1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right) + \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]
              3. Step-by-step derivation
                1. *-lowering-*.f64N/A

                  \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \left(\frac{1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right) + \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]
                2. accelerator-lowering-fma.f64N/A

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \color{blue}{\mathsf{fma}\left(\frac{1}{2}, \log \left({x.im}^{2} + {x.re}^{2}\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)}\right) \]
                3. log-lowering-log.f64N/A

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \color{blue}{\log \left({x.im}^{2} + {x.re}^{2}\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                4. +-commutativeN/A

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \color{blue}{\left({x.re}^{2} + {x.im}^{2}\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                5. unpow2N/A

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\color{blue}{x.re \cdot x.re} + {x.im}^{2}\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                6. accelerator-lowering-fma.f64N/A

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, {x.im}^{2}\right)\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                7. unpow2N/A

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                8. *-lowering-*.f64N/A

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                9. associate-/l*N/A

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
                10. *-lowering-*.f64N/A

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
                11. /-lowering-/.f64N/A

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \color{blue}{\frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
                12. atan2-lowering-atan2.f6496.3

                  \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}{y.im}\right)\right) \]
              4. Simplified96.3%

                \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]

              if -4.9999999999999998e-179 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0

              1. Initial program 100.0%

                \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
              2. Add Preprocessing
              3. Taylor expanded in y.im around 0

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
              4. Step-by-step derivation
                1. *-lowering-*.f64N/A

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                2. atan2-lowering-atan2.f64100.0

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
              5. Simplified100.0%

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
              6. Taylor expanded in y.re around 0

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
              7. Step-by-step derivation
                1. *-lowering-*.f64N/A

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                2. atan2-lowering-atan2.f64100.0

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
              8. Simplified100.0%

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

              if -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < 1

              1. Initial program 87.9%

                \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
              2. Add Preprocessing
              3. Step-by-step derivation
                1. flip3-+N/A

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
                2. clear-numN/A

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                3. /-lowering-/.f64N/A

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
              4. Applied egg-rr87.9%

                \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
              5. Taylor expanded in y.im around 0

                \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
              6. Step-by-step derivation
                1. pow-lowering-pow.f64N/A

                  \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                2. sqrt-lowering-sqrt.f64N/A

                  \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                3. unpow2N/A

                  \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                4. accelerator-lowering-fma.f64N/A

                  \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                5. unpow2N/A

                  \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                6. *-lowering-*.f6485.2

                  \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
              7. Simplified85.2%

                \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
              8. Taylor expanded in y.re around 0

                \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
              9. Step-by-step derivation
                1. Simplified83.1%

                  \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                2. Taylor expanded in y.im around -inf

                  \[\leadsto 1 \cdot \sin \color{blue}{\left(-1 \cdot \left(y.im \cdot \left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)\right)} \]
                3. Step-by-step derivation
                  1. mul-1-negN/A

                    \[\leadsto 1 \cdot \sin \color{blue}{\left(\mathsf{neg}\left(y.im \cdot \left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)\right)} \]
                  2. *-commutativeN/A

                    \[\leadsto 1 \cdot \sin \left(\mathsf{neg}\left(\color{blue}{\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot y.im}\right)\right) \]
                  3. distribute-rgt-neg-inN/A

                    \[\leadsto 1 \cdot \sin \color{blue}{\left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \left(\mathsf{neg}\left(y.im\right)\right)\right)} \]
                  4. neg-mul-1N/A

                    \[\leadsto 1 \cdot \sin \left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \color{blue}{\left(-1 \cdot y.im\right)}\right) \]
                  5. *-lowering-*.f64N/A

                    \[\leadsto 1 \cdot \sin \color{blue}{\left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \left(-1 \cdot y.im\right)\right)} \]
                4. Simplified83.3%

                  \[\leadsto 1 \cdot \sin \color{blue}{\left(\mathsf{fma}\left(\log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), -0.5, \frac{y.re \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}{y.im}\right) \cdot \left(0 - y.im\right)\right)} \]

                if 1 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

                1. Initial program 10.6%

                  \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                2. Add Preprocessing
                3. Taylor expanded in y.im around 0

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                4. Step-by-step derivation
                  1. *-lowering-*.f64N/A

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                  2. atan2-lowering-atan2.f6444.6

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                5. Simplified44.6%

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                6. Taylor expanded in y.re around 0

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                7. Step-by-step derivation
                  1. *-lowering-*.f64N/A

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                  2. atan2-lowering-atan2.f6444.0

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                8. Simplified44.0%

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                9. Taylor expanded in x.re around inf

                  \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                10. Step-by-step derivation
                  1. unpow2N/A

                    \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  2. *-lowering-*.f6443.2

                    \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                11. Simplified43.2%

                  \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                12. Step-by-step derivation
                  1. rem-sqrt-squareN/A

                    \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  2. fabs-lowering-fabs.f6458.0

                    \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                13. Applied egg-rr58.0%

                  \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
              10. Recombined 5 regimes into one program.
              11. Final simplification66.3%

                \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -0.5:\\ \;\;\;\;y.re \cdot \mathsf{fma}\left(-0.16666666666666666 \cdot \left(y.re \cdot y.re\right), {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -5 \cdot 10^{-179}:\\ \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 1:\\ \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(\log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), -0.5, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{0 - y.im}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
              12. Add Preprocessing

              Alternative 7: 59.3% accurate, 0.2× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_2 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_3 := e^{t\_1 \cdot y.re - t\_0} \cdot \sin \left(t\_1 \cdot y.im + t\_2\right)\\ t_4 := e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_2\\ t_5 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\ \mathbf{if}\;t\_3 \leq -0.5:\\ \;\;\;\;y.re \cdot \mathsf{fma}\left(-0.16666666666666666 \cdot \left(y.re \cdot y.re\right), {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;t\_3 \leq -5 \cdot 10^{-179}:\\ \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, t\_5, y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\ \mathbf{elif}\;t\_3 \leq 0:\\ \;\;\;\;t\_4\\ \mathbf{elif}\;t\_3 \leq 1:\\ \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(t\_5, -0.5, \frac{t\_2}{0 - y.im}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_4\\ \end{array} \end{array} \]
              (FPCore (x.re x.im y.re y.im)
               :precision binary64
               (let* ((t_0 (* (atan2 x.im x.re) y.im))
                      (t_1 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
                      (t_2 (* y.re (atan2 x.im x.re)))
                      (t_3 (* (exp (- (* t_1 y.re) t_0)) (sin (+ (* t_1 y.im) t_2))))
                      (t_4 (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_2))
                      (t_5 (log (fma x.re x.re (* x.im x.im)))))
                 (if (<= t_3 -0.5)
                   (*
                    y.re
                    (fma
                     (* -0.16666666666666666 (* y.re y.re))
                     (pow (atan2 x.im x.re) 3.0)
                     (atan2 x.im x.re)))
                   (if (<= t_3 -5e-179)
                     (sin (* y.im (fma 0.5 t_5 (* y.re (/ (atan2 x.im x.re) y.im)))))
                     (if (<= t_3 0.0)
                       t_4
                       (if (<= t_3 1.0)
                         (sin (* (- 0.0 y.im) (fma t_5 -0.5 (/ t_2 (- 0.0 y.im)))))
                         t_4))))))
              double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
              	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
              	double t_1 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
              	double t_2 = y_46_re * atan2(x_46_im, x_46_re);
              	double t_3 = exp(((t_1 * y_46_re) - t_0)) * sin(((t_1 * y_46_im) + t_2));
              	double t_4 = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_2;
              	double t_5 = log(fma(x_46_re, x_46_re, (x_46_im * x_46_im)));
              	double tmp;
              	if (t_3 <= -0.5) {
              		tmp = y_46_re * fma((-0.16666666666666666 * (y_46_re * y_46_re)), pow(atan2(x_46_im, x_46_re), 3.0), atan2(x_46_im, x_46_re));
              	} else if (t_3 <= -5e-179) {
              		tmp = sin((y_46_im * fma(0.5, t_5, (y_46_re * (atan2(x_46_im, x_46_re) / y_46_im)))));
              	} else if (t_3 <= 0.0) {
              		tmp = t_4;
              	} else if (t_3 <= 1.0) {
              		tmp = sin(((0.0 - y_46_im) * fma(t_5, -0.5, (t_2 / (0.0 - y_46_im)))));
              	} else {
              		tmp = t_4;
              	}
              	return tmp;
              }
              
              function code(x_46_re, x_46_im, y_46_re, y_46_im)
              	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
              	t_1 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
              	t_2 = Float64(y_46_re * atan(x_46_im, x_46_re))
              	t_3 = Float64(exp(Float64(Float64(t_1 * y_46_re) - t_0)) * sin(Float64(Float64(t_1 * y_46_im) + t_2)))
              	t_4 = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_2)
              	t_5 = log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im)))
              	tmp = 0.0
              	if (t_3 <= -0.5)
              		tmp = Float64(y_46_re * fma(Float64(-0.16666666666666666 * Float64(y_46_re * y_46_re)), (atan(x_46_im, x_46_re) ^ 3.0), atan(x_46_im, x_46_re)));
              	elseif (t_3 <= -5e-179)
              		tmp = sin(Float64(y_46_im * fma(0.5, t_5, Float64(y_46_re * Float64(atan(x_46_im, x_46_re) / y_46_im)))));
              	elseif (t_3 <= 0.0)
              		tmp = t_4;
              	elseif (t_3 <= 1.0)
              		tmp = sin(Float64(Float64(0.0 - y_46_im) * fma(t_5, -0.5, Float64(t_2 / Float64(0.0 - y_46_im)))));
              	else
              		tmp = t_4;
              	end
              	return tmp
              end
              
              code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[Exp[N[(N[(t$95$1 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(N[(t$95$1 * y$46$im), $MachinePrecision] + t$95$2), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$2), $MachinePrecision]}, Block[{t$95$5 = N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$3, -0.5], N[(y$46$re * N[(N[(-0.16666666666666666 * N[(y$46$re * y$46$re), $MachinePrecision]), $MachinePrecision] * N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 3.0], $MachinePrecision] + N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, -5e-179], N[Sin[N[(y$46$im * N[(0.5 * t$95$5 + N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] / y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$3, 0.0], t$95$4, If[LessEqual[t$95$3, 1.0], N[Sin[N[(N[(0.0 - y$46$im), $MachinePrecision] * N[(t$95$5 * -0.5 + N[(t$95$2 / N[(0.0 - y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], t$95$4]]]]]]]]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
              t_1 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
              t_2 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
              t_3 := e^{t\_1 \cdot y.re - t\_0} \cdot \sin \left(t\_1 \cdot y.im + t\_2\right)\\
              t_4 := e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_2\\
              t_5 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\
              \mathbf{if}\;t\_3 \leq -0.5:\\
              \;\;\;\;y.re \cdot \mathsf{fma}\left(-0.16666666666666666 \cdot \left(y.re \cdot y.re\right), {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\\
              
              \mathbf{elif}\;t\_3 \leq -5 \cdot 10^{-179}:\\
              \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, t\_5, y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\
              
              \mathbf{elif}\;t\_3 \leq 0:\\
              \;\;\;\;t\_4\\
              
              \mathbf{elif}\;t\_3 \leq 1:\\
              \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(t\_5, -0.5, \frac{t\_2}{0 - y.im}\right)\right)\\
              
              \mathbf{else}:\\
              \;\;\;\;t\_4\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 4 regimes
              2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.5

                1. Initial program 48.0%

                  \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                2. Add Preprocessing
                3. Taylor expanded in y.re around 0

                  \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                4. Step-by-step derivation
                  1. mul-1-negN/A

                    \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                  2. neg-sub0N/A

                    \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                  3. --lowering--.f64N/A

                    \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                  4. *-lowering-*.f64N/A

                    \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                  5. atan2-lowering-atan2.f6414.5

                    \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                5. Simplified14.5%

                  \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                6. Taylor expanded in y.im around 0

                  \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                7. Step-by-step derivation
                  1. sin-lowering-sin.f64N/A

                    \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                  2. *-lowering-*.f64N/A

                    \[\leadsto \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                  3. atan2-lowering-atan2.f642.0

                    \[\leadsto \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                8. Simplified2.0%

                  \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                9. Taylor expanded in y.re around 0

                  \[\leadsto \color{blue}{y.re \cdot \left(\frac{-1}{6} \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right) + \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                10. Step-by-step derivation
                  1. *-lowering-*.f64N/A

                    \[\leadsto \color{blue}{y.re \cdot \left(\frac{-1}{6} \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right) + \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                  2. associate-*r*N/A

                    \[\leadsto y.re \cdot \left(\color{blue}{\left(\frac{-1}{6} \cdot {y.re}^{2}\right) \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}} + \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  3. accelerator-lowering-fma.f64N/A

                    \[\leadsto y.re \cdot \color{blue}{\mathsf{fma}\left(\frac{-1}{6} \cdot {y.re}^{2}, {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                  4. *-lowering-*.f64N/A

                    \[\leadsto y.re \cdot \mathsf{fma}\left(\color{blue}{\frac{-1}{6} \cdot {y.re}^{2}}, {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  5. unpow2N/A

                    \[\leadsto y.re \cdot \mathsf{fma}\left(\frac{-1}{6} \cdot \color{blue}{\left(y.re \cdot y.re\right)}, {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  6. *-lowering-*.f64N/A

                    \[\leadsto y.re \cdot \mathsf{fma}\left(\frac{-1}{6} \cdot \color{blue}{\left(y.re \cdot y.re\right)}, {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  7. pow-lowering-pow.f64N/A

                    \[\leadsto y.re \cdot \mathsf{fma}\left(\frac{-1}{6} \cdot \left(y.re \cdot y.re\right), \color{blue}{{\tan^{-1}_* \frac{x.im}{x.re}}^{3}}, \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  8. atan2-lowering-atan2.f64N/A

                    \[\leadsto y.re \cdot \mathsf{fma}\left(\frac{-1}{6} \cdot \left(y.re \cdot y.re\right), {\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  9. atan2-lowering-atan2.f6436.1

                    \[\leadsto y.re \cdot \mathsf{fma}\left(-0.16666666666666666 \cdot \left(y.re \cdot y.re\right), {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                11. Simplified36.1%

                  \[\leadsto \color{blue}{y.re \cdot \mathsf{fma}\left(-0.16666666666666666 \cdot \left(y.re \cdot y.re\right), {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

                if -0.5 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -4.9999999999999998e-179

                1. Initial program 99.5%

                  \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                2. Add Preprocessing
                3. Step-by-step derivation
                  1. flip3-+N/A

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
                  2. clear-numN/A

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                  3. /-lowering-/.f64N/A

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                4. Applied egg-rr99.4%

                  \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
                5. Taylor expanded in y.im around 0

                  \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                6. Step-by-step derivation
                  1. pow-lowering-pow.f64N/A

                    \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                  2. sqrt-lowering-sqrt.f64N/A

                    \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                  3. unpow2N/A

                    \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                  4. accelerator-lowering-fma.f64N/A

                    \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                  5. unpow2N/A

                    \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                  6. *-lowering-*.f6496.0

                    \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                7. Simplified96.0%

                  \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                8. Taylor expanded in y.re around 0

                  \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                9. Step-by-step derivation
                  1. Simplified96.0%

                    \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                  2. Taylor expanded in y.im around inf

                    \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \left(\frac{1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right) + \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]
                  3. Step-by-step derivation
                    1. *-lowering-*.f64N/A

                      \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \left(\frac{1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right) + \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]
                    2. accelerator-lowering-fma.f64N/A

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \color{blue}{\mathsf{fma}\left(\frac{1}{2}, \log \left({x.im}^{2} + {x.re}^{2}\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)}\right) \]
                    3. log-lowering-log.f64N/A

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \color{blue}{\log \left({x.im}^{2} + {x.re}^{2}\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                    4. +-commutativeN/A

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \color{blue}{\left({x.re}^{2} + {x.im}^{2}\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                    5. unpow2N/A

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\color{blue}{x.re \cdot x.re} + {x.im}^{2}\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                    6. accelerator-lowering-fma.f64N/A

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, {x.im}^{2}\right)\right)}, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                    7. unpow2N/A

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                    8. *-lowering-*.f64N/A

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right) \]
                    9. associate-/l*N/A

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
                    10. *-lowering-*.f64N/A

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
                    11. /-lowering-/.f64N/A

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(\frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \color{blue}{\frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}}\right)\right) \]
                    12. atan2-lowering-atan2.f6496.3

                      \[\leadsto 1 \cdot \sin \left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}{y.im}\right)\right) \]
                  4. Simplified96.3%

                    \[\leadsto 1 \cdot \sin \color{blue}{\left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)} \]

                  if -4.9999999999999998e-179 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0 or 1 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

                  1. Initial program 25.9%

                    \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                  2. Add Preprocessing
                  3. Taylor expanded in y.im around 0

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                  4. Step-by-step derivation
                    1. *-lowering-*.f64N/A

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    2. atan2-lowering-atan2.f6454.1

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                  5. Simplified54.1%

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                  6. Taylor expanded in y.re around 0

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                  7. Step-by-step derivation
                    1. *-lowering-*.f64N/A

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    2. atan2-lowering-atan2.f6453.6

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                  8. Simplified53.6%

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                  9. Taylor expanded in x.re around inf

                    \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  10. Step-by-step derivation
                    1. unpow2N/A

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    2. *-lowering-*.f6450.8

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  11. Simplified50.8%

                    \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  12. Step-by-step derivation
                    1. rem-sqrt-squareN/A

                      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    2. fabs-lowering-fabs.f6464.1

                      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  13. Applied egg-rr64.1%

                    \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

                  if -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < 1

                  1. Initial program 87.9%

                    \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                  2. Add Preprocessing
                  3. Step-by-step derivation
                    1. flip3-+N/A

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
                    2. clear-numN/A

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                    3. /-lowering-/.f64N/A

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                  4. Applied egg-rr87.9%

                    \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
                  5. Taylor expanded in y.im around 0

                    \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                  6. Step-by-step derivation
                    1. pow-lowering-pow.f64N/A

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    2. sqrt-lowering-sqrt.f64N/A

                      \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    3. unpow2N/A

                      \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    4. accelerator-lowering-fma.f64N/A

                      \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    5. unpow2N/A

                      \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    6. *-lowering-*.f6485.2

                      \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                  7. Simplified85.2%

                    \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                  8. Taylor expanded in y.re around 0

                    \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                  9. Step-by-step derivation
                    1. Simplified83.1%

                      \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    2. Taylor expanded in y.im around -inf

                      \[\leadsto 1 \cdot \sin \color{blue}{\left(-1 \cdot \left(y.im \cdot \left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)\right)} \]
                    3. Step-by-step derivation
                      1. mul-1-negN/A

                        \[\leadsto 1 \cdot \sin \color{blue}{\left(\mathsf{neg}\left(y.im \cdot \left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)\right)} \]
                      2. *-commutativeN/A

                        \[\leadsto 1 \cdot \sin \left(\mathsf{neg}\left(\color{blue}{\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot y.im}\right)\right) \]
                      3. distribute-rgt-neg-inN/A

                        \[\leadsto 1 \cdot \sin \color{blue}{\left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \left(\mathsf{neg}\left(y.im\right)\right)\right)} \]
                      4. neg-mul-1N/A

                        \[\leadsto 1 \cdot \sin \left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \color{blue}{\left(-1 \cdot y.im\right)}\right) \]
                      5. *-lowering-*.f64N/A

                        \[\leadsto 1 \cdot \sin \color{blue}{\left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \left(-1 \cdot y.im\right)\right)} \]
                    4. Simplified83.3%

                      \[\leadsto 1 \cdot \sin \color{blue}{\left(\mathsf{fma}\left(\log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), -0.5, \frac{y.re \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}{y.im}\right) \cdot \left(0 - y.im\right)\right)} \]
                  10. Recombined 4 regimes into one program.
                  11. Final simplification65.5%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -0.5:\\ \;\;\;\;y.re \cdot \mathsf{fma}\left(-0.16666666666666666 \cdot \left(y.re \cdot y.re\right), {\tan^{-1}_* \frac{x.im}{x.re}}^{3}, \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -5 \cdot 10^{-179}:\\ \;\;\;\;\sin \left(y.im \cdot \mathsf{fma}\left(0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 1:\\ \;\;\;\;\sin \left(\left(0 - y.im\right) \cdot \mathsf{fma}\left(\log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), -0.5, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{0 - y.im}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
                  12. Add Preprocessing

                  Alternative 8: 63.1% accurate, 0.3× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_3 := e^{t\_2 \cdot y.re - t\_0}\\ t_4 := t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\ t_5 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\ \mathbf{if}\;t\_4 \leq -2 \cdot 10^{-159}:\\ \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, t\_5, t\_1\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;t\_4 \leq 0:\\ \;\;\;\;t\_3 \cdot t\_1\\ \mathbf{elif}\;t\_4 \leq 1:\\ \;\;\;\;\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, t\_5 \cdot \left(y.im \cdot 0.5\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0 (* (atan2 x.im x.re) y.im))
                          (t_1 (* y.re (atan2 x.im x.re)))
                          (t_2 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
                          (t_3 (exp (- (* t_2 y.re) t_0)))
                          (t_4 (* t_3 (sin (+ (* t_2 y.im) t_1))))
                          (t_5 (log (fma x.re x.re (* x.im x.im)))))
                     (if (<= t_4 -2e-159)
                       (*
                        (sin (fma (* y.im 0.5) t_5 t_1))
                        (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re))
                       (if (<= t_4 0.0)
                         (* t_3 t_1)
                         (if (<= t_4 1.0)
                           (/
                            (sin (fma y.re (atan2 x.im x.re) (* t_5 (* y.im 0.5))))
                            (exp (fma (atan2 x.im x.re) y.im 0.0)))
                           (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_1))))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
                  	double t_1 = y_46_re * atan2(x_46_im, x_46_re);
                  	double t_2 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
                  	double t_3 = exp(((t_2 * y_46_re) - t_0));
                  	double t_4 = t_3 * sin(((t_2 * y_46_im) + t_1));
                  	double t_5 = log(fma(x_46_re, x_46_re, (x_46_im * x_46_im)));
                  	double tmp;
                  	if (t_4 <= -2e-159) {
                  		tmp = sin(fma((y_46_im * 0.5), t_5, t_1)) * pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
                  	} else if (t_4 <= 0.0) {
                  		tmp = t_3 * t_1;
                  	} else if (t_4 <= 1.0) {
                  		tmp = sin(fma(y_46_re, atan2(x_46_im, x_46_re), (t_5 * (y_46_im * 0.5)))) / exp(fma(atan2(x_46_im, x_46_re), y_46_im, 0.0));
                  	} else {
                  		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_1;
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
                  	t_1 = Float64(y_46_re * atan(x_46_im, x_46_re))
                  	t_2 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
                  	t_3 = exp(Float64(Float64(t_2 * y_46_re) - t_0))
                  	t_4 = Float64(t_3 * sin(Float64(Float64(t_2 * y_46_im) + t_1)))
                  	t_5 = log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im)))
                  	tmp = 0.0
                  	if (t_4 <= -2e-159)
                  		tmp = Float64(sin(fma(Float64(y_46_im * 0.5), t_5, t_1)) * (sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re));
                  	elseif (t_4 <= 0.0)
                  		tmp = Float64(t_3 * t_1);
                  	elseif (t_4 <= 1.0)
                  		tmp = Float64(sin(fma(y_46_re, atan(x_46_im, x_46_re), Float64(t_5 * Float64(y_46_im * 0.5)))) / exp(fma(atan(x_46_im, x_46_re), y_46_im, 0.0)));
                  	else
                  		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_1);
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[Exp[N[(N[(t$95$2 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$4 = N[(t$95$3 * N[Sin[N[(N[(t$95$2 * y$46$im), $MachinePrecision] + t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$4, -2e-159], N[(N[Sin[N[(N[(y$46$im * 0.5), $MachinePrecision] * t$95$5 + t$95$1), $MachinePrecision]], $MachinePrecision] * N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$4, 0.0], N[(t$95$3 * t$95$1), $MachinePrecision], If[LessEqual[t$95$4, 1.0], N[(N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(t$95$5 * N[(y$46$im * 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Exp[N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im + 0.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$1), $MachinePrecision]]]]]]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
                  t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                  t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
                  t_3 := e^{t\_2 \cdot y.re - t\_0}\\
                  t_4 := t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\
                  t_5 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\
                  \mathbf{if}\;t\_4 \leq -2 \cdot 10^{-159}:\\
                  \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, t\_5, t\_1\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\
                  
                  \mathbf{elif}\;t\_4 \leq 0:\\
                  \;\;\;\;t\_3 \cdot t\_1\\
                  
                  \mathbf{elif}\;t\_4 \leq 1:\\
                  \;\;\;\;\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, t\_5 \cdot \left(y.im \cdot 0.5\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 4 regimes
                  2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -1.99999999999999998e-159

                    1. Initial program 69.9%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. *-commutativeN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{y.im \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. pow1/2N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \log \color{blue}{\left({\left(x.re \cdot x.re + x.im \cdot x.im\right)}^{\frac{1}{2}}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      3. log-powN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \color{blue}{\left(\frac{1}{2} \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. associate-*r*N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{\left(y.im \cdot \frac{1}{2}\right) \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                      6. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(\color{blue}{y.im \cdot \frac{1}{2}}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      7. log-lowering-log.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \color{blue}{\log \left(x.re \cdot x.re + x.im \cdot x.im\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      8. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      9. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      10. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re}\right)\right) \]
                      11. atan2-lowering-atan2.f6469.9

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}} \cdot y.re\right)\right) \]
                    4. Applied egg-rr69.9%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                    5. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                    6. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      6. *-lowering-*.f6463.6

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                    7. Simplified63.6%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]

                    if -1.99999999999999998e-159 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0

                    1. Initial program 100.0%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f64100.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified100.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f64100.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified100.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

                    if -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < 1

                    1. Initial program 87.9%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.re around 0

                      \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    4. Step-by-step derivation
                      1. mul-1-negN/A

                        \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. neg-sub0N/A

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      3. --lowering--.f64N/A

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. *-lowering-*.f64N/A

                        \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. atan2-lowering-atan2.f6485.9

                        \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    5. Simplified85.9%

                      \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    6. Step-by-step derivation
                      1. *-commutativeN/A

                        \[\leadsto \color{blue}{\sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \]
                      2. exp-diffN/A

                        \[\leadsto \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \color{blue}{\frac{e^{0}}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}} \]
                      3. 1-expN/A

                        \[\leadsto \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \frac{\color{blue}{1}}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \]
                      4. *-commutativeN/A

                        \[\leadsto \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \frac{1}{e^{\color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}} \]
                      5. un-div-invN/A

                        \[\leadsto \color{blue}{\frac{\sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}} \]
                      6. *-commutativeN/A

                        \[\leadsto \frac{\sin \left(\color{blue}{y.im \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
                      7. pow1/2N/A

                        \[\leadsto \frac{\sin \left(y.im \cdot \log \color{blue}{\left({\left(x.re \cdot x.re + x.im \cdot x.im\right)}^{\frac{1}{2}}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
                      8. log-powN/A

                        \[\leadsto \frac{\sin \left(y.im \cdot \color{blue}{\left(\frac{1}{2} \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
                      9. associate-*l*N/A

                        \[\leadsto \frac{\sin \left(\color{blue}{\left(y.im \cdot \frac{1}{2}\right) \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \]
                    7. Applied egg-rr86.0%

                      \[\leadsto \color{blue}{\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, \left(y.im \cdot 0.5\right) \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}} \]

                    if 1 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

                    1. Initial program 10.6%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6444.6

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified44.6%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6444.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified44.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in x.re around inf

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. unpow2N/A

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. *-lowering-*.f6443.2

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified43.2%

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    12. Step-by-step derivation
                      1. rem-sqrt-squareN/A

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. fabs-lowering-fabs.f6458.0

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    13. Applied egg-rr58.0%

                      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  3. Recombined 4 regimes into one program.
                  4. Final simplification66.8%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -2 \cdot 10^{-159}:\\ \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 1:\\ \;\;\;\;\frac{\sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right) \cdot \left(y.im \cdot 0.5\right)\right)\right)}{e^{\mathsf{fma}\left(\tan^{-1}_* \frac{x.im}{x.re}, y.im, 0\right)}}\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 9: 62.4% accurate, 0.3× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ t_1 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_2 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_3 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_4 := e^{t\_3 \cdot y.re - t\_1}\\ t_5 := t\_4 \cdot \sin \left(t\_3 \cdot y.im + t\_2\right)\\ t_6 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\ \mathbf{if}\;t\_5 \leq -2 \cdot 10^{-159}:\\ \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, t\_6, t\_2\right)\right) \cdot t\_0\\ \mathbf{elif}\;t\_5 \leq 0:\\ \;\;\;\;t\_4 \cdot t\_2\\ \mathbf{elif}\;t\_5 \leq \infty:\\ \;\;\;\;\sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot t\_6, y.im, t\_2\right)}}\right) \cdot t\_0\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_1} \cdot t\_2\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0 (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re))
                          (t_1 (* (atan2 x.im x.re) y.im))
                          (t_2 (* y.re (atan2 x.im x.re)))
                          (t_3 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
                          (t_4 (exp (- (* t_3 y.re) t_1)))
                          (t_5 (* t_4 (sin (+ (* t_3 y.im) t_2))))
                          (t_6 (log (fma x.re x.re (* x.im x.im)))))
                     (if (<= t_5 -2e-159)
                       (* (sin (fma (* y.im 0.5) t_6 t_2)) t_0)
                       (if (<= t_5 0.0)
                         (* t_4 t_2)
                         (if (<= t_5 INFINITY)
                           (* (sin (/ 1.0 (/ 1.0 (fma (* 0.5 t_6) y.im t_2)))) t_0)
                           (* (exp (- (* y.re (log (fabs x.re))) t_1)) t_2))))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
                  	double t_1 = atan2(x_46_im, x_46_re) * y_46_im;
                  	double t_2 = y_46_re * atan2(x_46_im, x_46_re);
                  	double t_3 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
                  	double t_4 = exp(((t_3 * y_46_re) - t_1));
                  	double t_5 = t_4 * sin(((t_3 * y_46_im) + t_2));
                  	double t_6 = log(fma(x_46_re, x_46_re, (x_46_im * x_46_im)));
                  	double tmp;
                  	if (t_5 <= -2e-159) {
                  		tmp = sin(fma((y_46_im * 0.5), t_6, t_2)) * t_0;
                  	} else if (t_5 <= 0.0) {
                  		tmp = t_4 * t_2;
                  	} else if (t_5 <= ((double) INFINITY)) {
                  		tmp = sin((1.0 / (1.0 / fma((0.5 * t_6), y_46_im, t_2)))) * t_0;
                  	} else {
                  		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_1)) * t_2;
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re
                  	t_1 = Float64(atan(x_46_im, x_46_re) * y_46_im)
                  	t_2 = Float64(y_46_re * atan(x_46_im, x_46_re))
                  	t_3 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
                  	t_4 = exp(Float64(Float64(t_3 * y_46_re) - t_1))
                  	t_5 = Float64(t_4 * sin(Float64(Float64(t_3 * y_46_im) + t_2)))
                  	t_6 = log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im)))
                  	tmp = 0.0
                  	if (t_5 <= -2e-159)
                  		tmp = Float64(sin(fma(Float64(y_46_im * 0.5), t_6, t_2)) * t_0);
                  	elseif (t_5 <= 0.0)
                  		tmp = Float64(t_4 * t_2);
                  	elseif (t_5 <= Inf)
                  		tmp = Float64(sin(Float64(1.0 / Float64(1.0 / fma(Float64(0.5 * t_6), y_46_im, t_2)))) * t_0);
                  	else
                  		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_1)) * t_2);
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]}, Block[{t$95$1 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$2 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$4 = N[Exp[N[(N[(t$95$3 * y$46$re), $MachinePrecision] - t$95$1), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$5 = N[(t$95$4 * N[Sin[N[(N[(t$95$3 * y$46$im), $MachinePrecision] + t$95$2), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$5, -2e-159], N[(N[Sin[N[(N[(y$46$im * 0.5), $MachinePrecision] * t$95$6 + t$95$2), $MachinePrecision]], $MachinePrecision] * t$95$0), $MachinePrecision], If[LessEqual[t$95$5, 0.0], N[(t$95$4 * t$95$2), $MachinePrecision], If[LessEqual[t$95$5, Infinity], N[(N[Sin[N[(1.0 / N[(1.0 / N[(N[(0.5 * t$95$6), $MachinePrecision] * y$46$im + t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * t$95$0), $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]], $MachinePrecision] * t$95$2), $MachinePrecision]]]]]]]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\
                  t_1 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
                  t_2 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                  t_3 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
                  t_4 := e^{t\_3 \cdot y.re - t\_1}\\
                  t_5 := t\_4 \cdot \sin \left(t\_3 \cdot y.im + t\_2\right)\\
                  t_6 := \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)\\
                  \mathbf{if}\;t\_5 \leq -2 \cdot 10^{-159}:\\
                  \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, t\_6, t\_2\right)\right) \cdot t\_0\\
                  
                  \mathbf{elif}\;t\_5 \leq 0:\\
                  \;\;\;\;t\_4 \cdot t\_2\\
                  
                  \mathbf{elif}\;t\_5 \leq \infty:\\
                  \;\;\;\;\sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot t\_6, y.im, t\_2\right)}}\right) \cdot t\_0\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_1} \cdot t\_2\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 4 regimes
                  2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -1.99999999999999998e-159

                    1. Initial program 69.9%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. *-commutativeN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{y.im \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. pow1/2N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \log \color{blue}{\left({\left(x.re \cdot x.re + x.im \cdot x.im\right)}^{\frac{1}{2}}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      3. log-powN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \color{blue}{\left(\frac{1}{2} \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. associate-*r*N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{\left(y.im \cdot \frac{1}{2}\right) \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                      6. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(\color{blue}{y.im \cdot \frac{1}{2}}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      7. log-lowering-log.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \color{blue}{\log \left(x.re \cdot x.re + x.im \cdot x.im\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      8. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      9. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      10. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re}\right)\right) \]
                      11. atan2-lowering-atan2.f6469.9

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}} \cdot y.re\right)\right) \]
                    4. Applied egg-rr69.9%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                    5. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                    6. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      6. *-lowering-*.f6463.6

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                    7. Simplified63.6%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]

                    if -1.99999999999999998e-159 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0

                    1. Initial program 100.0%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f64100.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified100.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f64100.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified100.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

                    if -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < +inf.0

                    1. Initial program 80.8%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. flip3-+N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
                      2. clear-numN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                      3. /-lowering-/.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                    4. Applied egg-rr83.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
                    5. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    6. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      6. *-lowering-*.f6468.8

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    7. Simplified68.8%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]

                    if +inf.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

                    1. Initial program 0.0%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6439.7

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified39.7%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6441.9

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified41.9%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in x.re around inf

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. unpow2N/A

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. *-lowering-*.f6443.7

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified43.7%

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    12. Step-by-step derivation
                      1. rem-sqrt-squareN/A

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. fabs-lowering-fabs.f6458.9

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    13. Applied egg-rr58.9%

                      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  3. Recombined 4 regimes into one program.
                  4. Final simplification66.8%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -2 \cdot 10^{-159}:\\ \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq \infty:\\ \;\;\;\;\sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 10: 63.2% accurate, 0.3× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := \mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\\ t_2 := {\left(\sqrt{t\_1}\right)}^{y.re}\\ t_3 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_4 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_5 := e^{t\_4 \cdot y.re - t\_0}\\ t_6 := t\_5 \cdot \sin \left(t\_4 \cdot y.im + t\_3\right)\\ \mathbf{if}\;t\_6 \leq -2 \cdot 10^{-159}:\\ \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), t\_3\right)\right) \cdot t\_2\\ \mathbf{elif}\;t\_6 \leq 0:\\ \;\;\;\;t\_5 \cdot t\_3\\ \mathbf{elif}\;t\_6 \leq 1:\\ \;\;\;\;t\_2 \cdot \sin \left(\mathsf{fma}\left(\log t\_1, -0.5, \frac{t\_3}{0 - y.im}\right) \cdot \left(0 - y.im\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_3\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0 (* (atan2 x.im x.re) y.im))
                          (t_1 (fma x.im x.im (* x.re x.re)))
                          (t_2 (pow (sqrt t_1) y.re))
                          (t_3 (* y.re (atan2 x.im x.re)))
                          (t_4 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
                          (t_5 (exp (- (* t_4 y.re) t_0)))
                          (t_6 (* t_5 (sin (+ (* t_4 y.im) t_3)))))
                     (if (<= t_6 -2e-159)
                       (* (sin (fma (* y.im 0.5) (log (fma x.re x.re (* x.im x.im))) t_3)) t_2)
                       (if (<= t_6 0.0)
                         (* t_5 t_3)
                         (if (<= t_6 1.0)
                           (*
                            t_2
                            (sin (* (fma (log t_1) -0.5 (/ t_3 (- 0.0 y.im))) (- 0.0 y.im))))
                           (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_3))))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
                  	double t_1 = fma(x_46_im, x_46_im, (x_46_re * x_46_re));
                  	double t_2 = pow(sqrt(t_1), y_46_re);
                  	double t_3 = y_46_re * atan2(x_46_im, x_46_re);
                  	double t_4 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
                  	double t_5 = exp(((t_4 * y_46_re) - t_0));
                  	double t_6 = t_5 * sin(((t_4 * y_46_im) + t_3));
                  	double tmp;
                  	if (t_6 <= -2e-159) {
                  		tmp = sin(fma((y_46_im * 0.5), log(fma(x_46_re, x_46_re, (x_46_im * x_46_im))), t_3)) * t_2;
                  	} else if (t_6 <= 0.0) {
                  		tmp = t_5 * t_3;
                  	} else if (t_6 <= 1.0) {
                  		tmp = t_2 * sin((fma(log(t_1), -0.5, (t_3 / (0.0 - y_46_im))) * (0.0 - y_46_im)));
                  	} else {
                  		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_3;
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
                  	t_1 = fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))
                  	t_2 = sqrt(t_1) ^ y_46_re
                  	t_3 = Float64(y_46_re * atan(x_46_im, x_46_re))
                  	t_4 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
                  	t_5 = exp(Float64(Float64(t_4 * y_46_re) - t_0))
                  	t_6 = Float64(t_5 * sin(Float64(Float64(t_4 * y_46_im) + t_3)))
                  	tmp = 0.0
                  	if (t_6 <= -2e-159)
                  		tmp = Float64(sin(fma(Float64(y_46_im * 0.5), log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im))), t_3)) * t_2);
                  	elseif (t_6 <= 0.0)
                  		tmp = Float64(t_5 * t_3);
                  	elseif (t_6 <= 1.0)
                  		tmp = Float64(t_2 * sin(Float64(fma(log(t_1), -0.5, Float64(t_3 / Float64(0.0 - y_46_im))) * Float64(0.0 - y_46_im))));
                  	else
                  		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_3);
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Power[N[Sqrt[t$95$1], $MachinePrecision], y$46$re], $MachinePrecision]}, Block[{t$95$3 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$5 = N[Exp[N[(N[(t$95$4 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$6 = N[(t$95$5 * N[Sin[N[(N[(t$95$4 * y$46$im), $MachinePrecision] + t$95$3), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$6, -2e-159], N[(N[Sin[N[(N[(y$46$im * 0.5), $MachinePrecision] * N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] + t$95$3), $MachinePrecision]], $MachinePrecision] * t$95$2), $MachinePrecision], If[LessEqual[t$95$6, 0.0], N[(t$95$5 * t$95$3), $MachinePrecision], If[LessEqual[t$95$6, 1.0], N[(t$95$2 * N[Sin[N[(N[(N[Log[t$95$1], $MachinePrecision] * -0.5 + N[(t$95$3 / N[(0.0 - y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(0.0 - y$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$3), $MachinePrecision]]]]]]]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
                  t_1 := \mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\\
                  t_2 := {\left(\sqrt{t\_1}\right)}^{y.re}\\
                  t_3 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                  t_4 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
                  t_5 := e^{t\_4 \cdot y.re - t\_0}\\
                  t_6 := t\_5 \cdot \sin \left(t\_4 \cdot y.im + t\_3\right)\\
                  \mathbf{if}\;t\_6 \leq -2 \cdot 10^{-159}:\\
                  \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), t\_3\right)\right) \cdot t\_2\\
                  
                  \mathbf{elif}\;t\_6 \leq 0:\\
                  \;\;\;\;t\_5 \cdot t\_3\\
                  
                  \mathbf{elif}\;t\_6 \leq 1:\\
                  \;\;\;\;t\_2 \cdot \sin \left(\mathsf{fma}\left(\log t\_1, -0.5, \frac{t\_3}{0 - y.im}\right) \cdot \left(0 - y.im\right)\right)\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_3\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 4 regimes
                  2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -1.99999999999999998e-159

                    1. Initial program 69.9%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. *-commutativeN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{y.im \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. pow1/2N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \log \color{blue}{\left({\left(x.re \cdot x.re + x.im \cdot x.im\right)}^{\frac{1}{2}}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      3. log-powN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \color{blue}{\left(\frac{1}{2} \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. associate-*r*N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{\left(y.im \cdot \frac{1}{2}\right) \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                      6. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(\color{blue}{y.im \cdot \frac{1}{2}}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      7. log-lowering-log.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \color{blue}{\log \left(x.re \cdot x.re + x.im \cdot x.im\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      8. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      9. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      10. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re}\right)\right) \]
                      11. atan2-lowering-atan2.f6469.9

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}} \cdot y.re\right)\right) \]
                    4. Applied egg-rr69.9%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                    5. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                    6. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      6. *-lowering-*.f6463.6

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                    7. Simplified63.6%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]

                    if -1.99999999999999998e-159 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0

                    1. Initial program 100.0%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f64100.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified100.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f64100.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified100.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

                    if -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < 1

                    1. Initial program 87.9%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. flip3-+N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
                      2. clear-numN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                      3. /-lowering-/.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                    4. Applied egg-rr87.9%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
                    5. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    6. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      6. *-lowering-*.f6485.2

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    7. Simplified85.2%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    8. Taylor expanded in y.im around -inf

                      \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re} \cdot \sin \color{blue}{\left(-1 \cdot \left(y.im \cdot \left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)\right)} \]
                    9. Step-by-step derivation
                      1. mul-1-negN/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re} \cdot \sin \color{blue}{\left(\mathsf{neg}\left(y.im \cdot \left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)\right)} \]
                      2. *-commutativeN/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{neg}\left(\color{blue}{\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot y.im}\right)\right) \]
                      3. distribute-rgt-neg-inN/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re} \cdot \sin \color{blue}{\left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \left(\mathsf{neg}\left(y.im\right)\right)\right)} \]
                      4. neg-mul-1N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re} \cdot \sin \left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \color{blue}{\left(-1 \cdot y.im\right)}\right) \]
                      5. *-lowering-*.f64N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re} \cdot \sin \color{blue}{\left(\left(-1 \cdot \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{y.im} + \frac{-1}{2} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \cdot \left(-1 \cdot y.im\right)\right)} \]
                    10. Simplified85.3%

                      \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(\log \left(\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\right), -0.5, \frac{y.re \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}{y.im}\right) \cdot \left(0 - y.im\right)\right)} \]

                    if 1 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

                    1. Initial program 10.6%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6444.6

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified44.6%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6444.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified44.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in x.re around inf

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. unpow2N/A

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. *-lowering-*.f6443.2

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified43.2%

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    12. Step-by-step derivation
                      1. rem-sqrt-squareN/A

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. fabs-lowering-fabs.f6458.0

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    13. Applied egg-rr58.0%

                      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  3. Recombined 4 regimes into one program.
                  4. Final simplification66.8%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -2 \cdot 10^{-159}:\\ \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 1:\\ \;\;\;\;{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(\log \left(\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\right), -0.5, \frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{0 - y.im}\right) \cdot \left(0 - y.im\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 11: 63.2% accurate, 0.3× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_3 := e^{t\_2 \cdot y.re - t\_0}\\ t_4 := t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\ t_5 := \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), t\_1\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{if}\;t\_4 \leq -2 \cdot 10^{-159}:\\ \;\;\;\;t\_5\\ \mathbf{elif}\;t\_4 \leq 0:\\ \;\;\;\;t\_3 \cdot t\_1\\ \mathbf{elif}\;t\_4 \leq 1:\\ \;\;\;\;t\_5\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0 (* (atan2 x.im x.re) y.im))
                          (t_1 (* y.re (atan2 x.im x.re)))
                          (t_2 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
                          (t_3 (exp (- (* t_2 y.re) t_0)))
                          (t_4 (* t_3 (sin (+ (* t_2 y.im) t_1))))
                          (t_5
                           (*
                            (sin (fma (* y.im 0.5) (log (fma x.re x.re (* x.im x.im))) t_1))
                            (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re))))
                     (if (<= t_4 -2e-159)
                       t_5
                       (if (<= t_4 0.0)
                         (* t_3 t_1)
                         (if (<= t_4 1.0)
                           t_5
                           (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_1))))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
                  	double t_1 = y_46_re * atan2(x_46_im, x_46_re);
                  	double t_2 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
                  	double t_3 = exp(((t_2 * y_46_re) - t_0));
                  	double t_4 = t_3 * sin(((t_2 * y_46_im) + t_1));
                  	double t_5 = sin(fma((y_46_im * 0.5), log(fma(x_46_re, x_46_re, (x_46_im * x_46_im))), t_1)) * pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
                  	double tmp;
                  	if (t_4 <= -2e-159) {
                  		tmp = t_5;
                  	} else if (t_4 <= 0.0) {
                  		tmp = t_3 * t_1;
                  	} else if (t_4 <= 1.0) {
                  		tmp = t_5;
                  	} else {
                  		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_1;
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
                  	t_1 = Float64(y_46_re * atan(x_46_im, x_46_re))
                  	t_2 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
                  	t_3 = exp(Float64(Float64(t_2 * y_46_re) - t_0))
                  	t_4 = Float64(t_3 * sin(Float64(Float64(t_2 * y_46_im) + t_1)))
                  	t_5 = Float64(sin(fma(Float64(y_46_im * 0.5), log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im))), t_1)) * (sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re))
                  	tmp = 0.0
                  	if (t_4 <= -2e-159)
                  		tmp = t_5;
                  	elseif (t_4 <= 0.0)
                  		tmp = Float64(t_3 * t_1);
                  	elseif (t_4 <= 1.0)
                  		tmp = t_5;
                  	else
                  		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_1);
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[Exp[N[(N[(t$95$2 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$4 = N[(t$95$3 * N[Sin[N[(N[(t$95$2 * y$46$im), $MachinePrecision] + t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[Sin[N[(N[(y$46$im * 0.5), $MachinePrecision] * N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] + t$95$1), $MachinePrecision]], $MachinePrecision] * N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$4, -2e-159], t$95$5, If[LessEqual[t$95$4, 0.0], N[(t$95$3 * t$95$1), $MachinePrecision], If[LessEqual[t$95$4, 1.0], t$95$5, N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$1), $MachinePrecision]]]]]]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
                  t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                  t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
                  t_3 := e^{t\_2 \cdot y.re - t\_0}\\
                  t_4 := t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right)\\
                  t_5 := \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), t\_1\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\
                  \mathbf{if}\;t\_4 \leq -2 \cdot 10^{-159}:\\
                  \;\;\;\;t\_5\\
                  
                  \mathbf{elif}\;t\_4 \leq 0:\\
                  \;\;\;\;t\_3 \cdot t\_1\\
                  
                  \mathbf{elif}\;t\_4 \leq 1:\\
                  \;\;\;\;t\_5\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 3 regimes
                  2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -1.99999999999999998e-159 or -0.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < 1

                    1. Initial program 76.3%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. *-commutativeN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{y.im \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. pow1/2N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \log \color{blue}{\left({\left(x.re \cdot x.re + x.im \cdot x.im\right)}^{\frac{1}{2}}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      3. log-powN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \color{blue}{\left(\frac{1}{2} \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. associate-*r*N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{\left(y.im \cdot \frac{1}{2}\right) \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                      6. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(\color{blue}{y.im \cdot \frac{1}{2}}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      7. log-lowering-log.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \color{blue}{\log \left(x.re \cdot x.re + x.im \cdot x.im\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      8. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      9. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      10. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re}\right)\right) \]
                      11. atan2-lowering-atan2.f6476.3

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}} \cdot y.re\right)\right) \]
                    4. Applied egg-rr76.3%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                    5. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                    6. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      6. *-lowering-*.f6471.3

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                    7. Simplified71.3%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]

                    if -1.99999999999999998e-159 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < -0.0

                    1. Initial program 100.0%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f64100.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified100.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f64100.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified100.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

                    if 1 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

                    1. Initial program 10.6%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6444.6

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified44.6%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6444.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified44.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in x.re around inf

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. unpow2N/A

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. *-lowering-*.f6443.2

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified43.2%

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    12. Step-by-step derivation
                      1. rem-sqrt-squareN/A

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. fabs-lowering-fabs.f6458.0

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    13. Applied egg-rr58.0%

                      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  3. Recombined 3 regimes into one program.
                  4. Final simplification66.8%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq -2 \cdot 10^{-159}:\\ \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 0:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq 1:\\ \;\;\;\;\sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 12: 67.2% accurate, 0.5× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_3 := e^{t\_2 \cdot y.re - t\_0}\\ \mathbf{if}\;t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right) \leq \infty:\\ \;\;\;\;t\_3 \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, t\_1\right)}}\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0 (* (atan2 x.im x.re) y.im))
                          (t_1 (* y.re (atan2 x.im x.re)))
                          (t_2 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
                          (t_3 (exp (- (* t_2 y.re) t_0))))
                     (if (<= (* t_3 (sin (+ (* t_2 y.im) t_1))) INFINITY)
                       (*
                        t_3
                        (sin
                         (/
                          1.0
                          (/ 1.0 (fma (* 0.5 (log (fma x.re x.re (* x.im x.im)))) y.im t_1)))))
                       (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_1))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
                  	double t_1 = y_46_re * atan2(x_46_im, x_46_re);
                  	double t_2 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
                  	double t_3 = exp(((t_2 * y_46_re) - t_0));
                  	double tmp;
                  	if ((t_3 * sin(((t_2 * y_46_im) + t_1))) <= ((double) INFINITY)) {
                  		tmp = t_3 * sin((1.0 / (1.0 / fma((0.5 * log(fma(x_46_re, x_46_re, (x_46_im * x_46_im)))), y_46_im, t_1))));
                  	} else {
                  		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_1;
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
                  	t_1 = Float64(y_46_re * atan(x_46_im, x_46_re))
                  	t_2 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
                  	t_3 = exp(Float64(Float64(t_2 * y_46_re) - t_0))
                  	tmp = 0.0
                  	if (Float64(t_3 * sin(Float64(Float64(t_2 * y_46_im) + t_1))) <= Inf)
                  		tmp = Float64(t_3 * sin(Float64(1.0 / Float64(1.0 / fma(Float64(0.5 * log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im)))), y_46_im, t_1)))));
                  	else
                  		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_1);
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[Exp[N[(N[(t$95$2 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[N[(t$95$3 * N[Sin[N[(N[(t$95$2 * y$46$im), $MachinePrecision] + t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], Infinity], N[(t$95$3 * N[Sin[N[(1.0 / N[(1.0 / N[(N[(0.5 * N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * y$46$im + t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$1), $MachinePrecision]]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
                  t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                  t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
                  t_3 := e^{t\_2 \cdot y.re - t\_0}\\
                  \mathbf{if}\;t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right) \leq \infty:\\
                  \;\;\;\;t\_3 \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, t\_1\right)}}\right)\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < +inf.0

                    1. Initial program 82.6%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. flip3-+N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
                      2. clear-numN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                      3. /-lowering-/.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                    4. Applied egg-rr83.4%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]

                    if +inf.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

                    1. Initial program 0.0%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6439.7

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified39.7%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6441.9

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified41.9%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in x.re around inf

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. unpow2N/A

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. *-lowering-*.f6443.7

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified43.7%

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    12. Step-by-step derivation
                      1. rem-sqrt-squareN/A

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. fabs-lowering-fabs.f6458.9

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    13. Applied egg-rr58.9%

                      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  3. Recombined 2 regimes into one program.
                  4. Final simplification70.3%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq \infty:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}}\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 13: 67.2% accurate, 0.5× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\ t_3 := e^{t\_2 \cdot y.re - t\_0}\\ \mathbf{if}\;t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right) \leq \infty:\\ \;\;\;\;t\_3 \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), t\_1\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0 (* (atan2 x.im x.re) y.im))
                          (t_1 (* y.re (atan2 x.im x.re)))
                          (t_2 (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
                          (t_3 (exp (- (* t_2 y.re) t_0))))
                     (if (<= (* t_3 (sin (+ (* t_2 y.im) t_1))) INFINITY)
                       (* t_3 (sin (fma (* y.im 0.5) (log (fma x.re x.re (* x.im x.im))) t_1)))
                       (* (exp (- (* y.re (log (fabs x.re))) t_0)) t_1))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = atan2(x_46_im, x_46_re) * y_46_im;
                  	double t_1 = y_46_re * atan2(x_46_im, x_46_re);
                  	double t_2 = log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))));
                  	double t_3 = exp(((t_2 * y_46_re) - t_0));
                  	double tmp;
                  	if ((t_3 * sin(((t_2 * y_46_im) + t_1))) <= ((double) INFINITY)) {
                  		tmp = t_3 * sin(fma((y_46_im * 0.5), log(fma(x_46_re, x_46_re, (x_46_im * x_46_im))), t_1));
                  	} else {
                  		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_0)) * t_1;
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = Float64(atan(x_46_im, x_46_re) * y_46_im)
                  	t_1 = Float64(y_46_re * atan(x_46_im, x_46_re))
                  	t_2 = log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))
                  	t_3 = exp(Float64(Float64(t_2 * y_46_re) - t_0))
                  	tmp = 0.0
                  	if (Float64(t_3 * sin(Float64(Float64(t_2 * y_46_im) + t_1))) <= Inf)
                  		tmp = Float64(t_3 * sin(fma(Float64(y_46_im * 0.5), log(fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im))), t_1)));
                  	else
                  		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_0)) * t_1);
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[Exp[N[(N[(t$95$2 * y$46$re), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[N[(t$95$3 * N[Sin[N[(N[(t$95$2 * y$46$im), $MachinePrecision] + t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], Infinity], N[(t$95$3 * N[Sin[N[(N[(y$46$im * 0.5), $MachinePrecision] * N[Log[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] + t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$1), $MachinePrecision]]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
                  t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                  t_2 := \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)\\
                  t_3 := e^{t\_2 \cdot y.re - t\_0}\\
                  \mathbf{if}\;t\_3 \cdot \sin \left(t\_2 \cdot y.im + t\_1\right) \leq \infty:\\
                  \;\;\;\;t\_3 \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), t\_1\right)\right)\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_0} \cdot t\_1\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re)))) < +inf.0

                    1. Initial program 82.6%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. *-commutativeN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{y.im \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. pow1/2N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \log \color{blue}{\left({\left(x.re \cdot x.re + x.im \cdot x.im\right)}^{\frac{1}{2}}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      3. log-powN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \color{blue}{\left(\frac{1}{2} \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. associate-*r*N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{\left(y.im \cdot \frac{1}{2}\right) \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                      6. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(\color{blue}{y.im \cdot \frac{1}{2}}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      7. log-lowering-log.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \color{blue}{\log \left(x.re \cdot x.re + x.im \cdot x.im\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      8. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      9. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      10. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re}\right)\right) \]
                      11. atan2-lowering-atan2.f6482.6

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}} \cdot y.re\right)\right) \]
                    4. Applied egg-rr82.6%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]

                    if +inf.0 < (*.f64 (exp.f64 (-.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.re) (*.f64 (atan2.f64 x.im x.re) y.im))) (sin.f64 (+.f64 (*.f64 (log.f64 (sqrt.f64 (+.f64 (*.f64 x.re x.re) (*.f64 x.im x.im)))) y.im) (*.f64 (atan2.f64 x.im x.re) y.re))))

                    1. Initial program 0.0%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6439.7

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified39.7%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6441.9

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified41.9%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in x.re around inf

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. unpow2N/A

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. *-lowering-*.f6443.7

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified43.7%

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    12. Step-by-step derivation
                      1. rem-sqrt-squareN/A

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. fabs-lowering-fabs.f6458.9

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    13. Applied egg-rr58.9%

                      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  3. Recombined 2 regimes into one program.
                  4. Final simplification69.9%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \leq \infty:\\ \;\;\;\;e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 14: 62.0% accurate, 1.1× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_1 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\ \mathbf{if}\;x.re \leq -0.01:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_1} \cdot t\_0\\ \mathbf{elif}\;x.re \leq 3.2 \cdot 10^{-308}:\\ \;\;\;\;t\_0 \cdot \frac{{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}^{\left(y.re \cdot 0.5\right)}}{e^{t\_1}}\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log x.re - t\_1} \cdot \sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, y.im \cdot \log x.re\right)\right)\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0 (* y.re (atan2 x.im x.re))) (t_1 (* (atan2 x.im x.re) y.im)))
                     (if (<= x.re -0.01)
                       (* (exp (- (* y.re (log (fabs x.re))) t_1)) t_0)
                       (if (<= x.re 3.2e-308)
                         (* t_0 (/ (pow (fma x.re x.re (* x.im x.im)) (* y.re 0.5)) (exp t_1)))
                         (*
                          (exp (- (* y.re (log x.re)) t_1))
                          (sin (fma y.re (atan2 x.im x.re) (* y.im (log x.re)))))))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = y_46_re * atan2(x_46_im, x_46_re);
                  	double t_1 = atan2(x_46_im, x_46_re) * y_46_im;
                  	double tmp;
                  	if (x_46_re <= -0.01) {
                  		tmp = exp(((y_46_re * log(fabs(x_46_re))) - t_1)) * t_0;
                  	} else if (x_46_re <= 3.2e-308) {
                  		tmp = t_0 * (pow(fma(x_46_re, x_46_re, (x_46_im * x_46_im)), (y_46_re * 0.5)) / exp(t_1));
                  	} else {
                  		tmp = exp(((y_46_re * log(x_46_re)) - t_1)) * sin(fma(y_46_re, atan2(x_46_im, x_46_re), (y_46_im * log(x_46_re))));
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = Float64(y_46_re * atan(x_46_im, x_46_re))
                  	t_1 = Float64(atan(x_46_im, x_46_re) * y_46_im)
                  	tmp = 0.0
                  	if (x_46_re <= -0.01)
                  		tmp = Float64(exp(Float64(Float64(y_46_re * log(abs(x_46_re))) - t_1)) * t_0);
                  	elseif (x_46_re <= 3.2e-308)
                  		tmp = Float64(t_0 * Float64((fma(x_46_re, x_46_re, Float64(x_46_im * x_46_im)) ^ Float64(y_46_re * 0.5)) / exp(t_1)));
                  	else
                  		tmp = Float64(exp(Float64(Float64(y_46_re * log(x_46_re)) - t_1)) * sin(fma(y_46_re, atan(x_46_im, x_46_re), Float64(y_46_im * log(x_46_re)))));
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * y$46$im), $MachinePrecision]}, If[LessEqual[x$46$re, -0.01], N[(N[Exp[N[(N[(y$46$re * N[Log[N[Abs[x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]], $MachinePrecision] * t$95$0), $MachinePrecision], If[LessEqual[x$46$re, 3.2e-308], N[(t$95$0 * N[(N[Power[N[(x$46$re * x$46$re + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision], N[(y$46$re * 0.5), $MachinePrecision]], $MachinePrecision] / N[Exp[t$95$1], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Exp[N[(N[(y$46$re * N[Log[x$46$re], $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(y$46$im * N[Log[x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                  t_1 := \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im\\
                  \mathbf{if}\;x.re \leq -0.01:\\
                  \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - t\_1} \cdot t\_0\\
                  
                  \mathbf{elif}\;x.re \leq 3.2 \cdot 10^{-308}:\\
                  \;\;\;\;t\_0 \cdot \frac{{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}^{\left(y.re \cdot 0.5\right)}}{e^{t\_1}}\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;e^{y.re \cdot \log x.re - t\_1} \cdot \sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, y.im \cdot \log x.re\right)\right)\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 3 regimes
                  2. if x.re < -0.0100000000000000002

                    1. Initial program 21.8%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6447.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified47.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6447.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified47.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in x.re around inf

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. unpow2N/A

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. *-lowering-*.f6454.0

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified54.0%

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    12. Step-by-step derivation
                      1. rem-sqrt-squareN/A

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. fabs-lowering-fabs.f6470.9

                        \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    13. Applied egg-rr70.9%

                      \[\leadsto e^{\log \color{blue}{\left(\left|x.re\right|\right)} \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

                    if -0.0100000000000000002 < x.re < 3.2000000000000001e-308

                    1. Initial program 54.0%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6456.2

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified56.2%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6458.9

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified58.9%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Step-by-step derivation
                      1. exp-diffN/A

                        \[\leadsto \color{blue}{\frac{e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re}}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. +-commutativeN/A

                        \[\leadsto \frac{e^{\log \left(\sqrt{\color{blue}{x.im \cdot x.im + x.re \cdot x.re}}\right) \cdot y.re}}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      3. pow-to-expN/A

                        \[\leadsto \frac{\color{blue}{{\left(\sqrt{x.im \cdot x.im + x.re \cdot x.re}\right)}^{y.re}}}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      4. frac-2negN/A

                        \[\leadsto \color{blue}{\frac{\mathsf{neg}\left({\left(\sqrt{x.im \cdot x.im + x.re \cdot x.re}\right)}^{y.re}\right)}{\mathsf{neg}\left(e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}\right)}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      5. /-lowering-/.f64N/A

                        \[\leadsto \color{blue}{\frac{\mathsf{neg}\left({\left(\sqrt{x.im \cdot x.im + x.re \cdot x.re}\right)}^{y.re}\right)}{\mathsf{neg}\left(e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}\right)}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Applied egg-rr60.2%

                      \[\leadsto \color{blue}{\frac{0 - {\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}^{\left(y.re \cdot 0.5\right)}}{0 - e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

                    if 3.2000000000000001e-308 < x.re

                    1. Initial program 37.6%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. *-commutativeN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{y.im \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. pow1/2N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \log \color{blue}{\left({\left(x.re \cdot x.re + x.im \cdot x.im\right)}^{\frac{1}{2}}\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      3. log-powN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.im \cdot \color{blue}{\left(\frac{1}{2} \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. associate-*r*N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\color{blue}{\left(y.im \cdot \frac{1}{2}\right) \cdot \log \left(x.re \cdot x.re + x.im \cdot x.im\right)} + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                      6. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(\color{blue}{y.im \cdot \frac{1}{2}}, \log \left(x.re \cdot x.re + x.im \cdot x.im\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      7. log-lowering-log.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \color{blue}{\log \left(x.re \cdot x.re + x.im \cdot x.im\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      8. accelerator-lowering-fma.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \color{blue}{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      9. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, \color{blue}{x.im \cdot x.im}\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right) \]
                      10. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot \frac{1}{2}, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re}\right)\right) \]
                      11. atan2-lowering-atan2.f6437.6

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}} \cdot y.re\right)\right) \]
                    4. Applied egg-rr37.6%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\mathsf{fma}\left(y.im \cdot 0.5, \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)} \]
                    5. Taylor expanded in x.re around inf

                      \[\leadsto \color{blue}{e^{-1 \cdot \left(y.re \cdot \log \left(\frac{1}{x.re}\right)\right) - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(-1 \cdot \left(y.im \cdot \log \left(\frac{1}{x.re}\right)\right) + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto \color{blue}{e^{-1 \cdot \left(y.re \cdot \log \left(\frac{1}{x.re}\right)\right) - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(-1 \cdot \left(y.im \cdot \log \left(\frac{1}{x.re}\right)\right) + y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Simplified67.3%

                      \[\leadsto \color{blue}{e^{y.re \cdot \log x.re - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}} \cdot \sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, y.im \cdot \log x.re\right)\right)} \]
                  3. Recombined 3 regimes into one program.
                  4. Final simplification64.6%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;x.re \leq -0.01:\\ \;\;\;\;e^{y.re \cdot \log \left(\left|x.re\right|\right) - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;x.re \leq 3.2 \cdot 10^{-308}:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot \frac{{\left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right)}^{\left(y.re \cdot 0.5\right)}}{e^{\tan^{-1}_* \frac{x.im}{x.re} \cdot y.im}}\\ \mathbf{else}:\\ \;\;\;\;e^{y.re \cdot \log x.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\mathsf{fma}\left(y.re, \tan^{-1}_* \frac{x.im}{x.re}, y.im \cdot \log x.re\right)\right)\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 15: 58.0% accurate, 1.6× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ t_1 := t\_0 \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{if}\;y.re \leq -210000:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y.re \leq 46000000000000:\\ \;\;\;\;e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)} \cdot t\_0\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0 (sin (* y.re (atan2 x.im x.re))))
                          (t_1 (* t_0 (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re))))
                     (if (<= y.re -210000.0)
                       t_1
                       (if (<= y.re 46000000000000.0)
                         (* (exp (* y.im (- 0.0 (atan2 x.im x.re)))) t_0)
                         t_1))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = sin((y_46_re * atan2(x_46_im, x_46_re)));
                  	double t_1 = t_0 * pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
                  	double tmp;
                  	if (y_46_re <= -210000.0) {
                  		tmp = t_1;
                  	} else if (y_46_re <= 46000000000000.0) {
                  		tmp = exp((y_46_im * (0.0 - atan2(x_46_im, x_46_re)))) * t_0;
                  	} else {
                  		tmp = t_1;
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = sin(Float64(y_46_re * atan(x_46_im, x_46_re)))
                  	t_1 = Float64(t_0 * (sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re))
                  	tmp = 0.0
                  	if (y_46_re <= -210000.0)
                  		tmp = t_1;
                  	elseif (y_46_re <= 46000000000000.0)
                  		tmp = Float64(exp(Float64(y_46_im * Float64(0.0 - atan(x_46_im, x_46_re)))) * t_0);
                  	else
                  		tmp = t_1;
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$1 = N[(t$95$0 * N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -210000.0], t$95$1, If[LessEqual[y$46$re, 46000000000000.0], N[(N[Exp[N[(y$46$im * N[(0.0 - N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * t$95$0), $MachinePrecision], t$95$1]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\
                  t_1 := t\_0 \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\
                  \mathbf{if}\;y.re \leq -210000:\\
                  \;\;\;\;t\_1\\
                  
                  \mathbf{elif}\;y.re \leq 46000000000000:\\
                  \;\;\;\;e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)} \cdot t\_0\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;t\_1\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if y.re < -2.1e5 or 4.6e13 < y.re

                    1. Initial program 33.9%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6471.5

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified71.5%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    7. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      6. *-lowering-*.f6470.6

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    8. Simplified70.6%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

                    if -2.1e5 < y.re < 4.6e13

                    1. Initial program 41.9%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6435.2

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified35.2%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto \color{blue}{e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    7. Step-by-step derivation
                      1. exp-lowering-exp.f64N/A

                        \[\leadsto \color{blue}{e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. neg-sub0N/A

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      3. --lowering--.f64N/A

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      4. *-lowering-*.f64N/A

                        \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      5. atan2-lowering-atan2.f6454.0

                        \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    8. Simplified54.0%

                      \[\leadsto \color{blue}{e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  3. Recombined 2 regimes into one program.
                  4. Final simplification61.3%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;y.re \leq -210000:\\ \;\;\;\;\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;y.re \leq 46000000000000:\\ \;\;\;\;e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 16: 58.3% accurate, 2.0× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{if}\;y.re \leq -6.1 \cdot 10^{-15}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;y.re \leq 46000000000000:\\ \;\;\;\;y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}\right)\\ \mathbf{else}:\\ \;\;\;\;t\_0\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0
                           (*
                            (sin (* y.re (atan2 x.im x.re)))
                            (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re))))
                     (if (<= y.re -6.1e-15)
                       t_0
                       (if (<= y.re 46000000000000.0)
                         (* y.re (* (atan2 x.im x.re) (exp (* y.im (- 0.0 (atan2 x.im x.re))))))
                         t_0))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = sin((y_46_re * atan2(x_46_im, x_46_re))) * pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
                  	double tmp;
                  	if (y_46_re <= -6.1e-15) {
                  		tmp = t_0;
                  	} else if (y_46_re <= 46000000000000.0) {
                  		tmp = y_46_re * (atan2(x_46_im, x_46_re) * exp((y_46_im * (0.0 - atan2(x_46_im, x_46_re)))));
                  	} else {
                  		tmp = t_0;
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = Float64(sin(Float64(y_46_re * atan(x_46_im, x_46_re))) * (sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re))
                  	tmp = 0.0
                  	if (y_46_re <= -6.1e-15)
                  		tmp = t_0;
                  	elseif (y_46_re <= 46000000000000.0)
                  		tmp = Float64(y_46_re * Float64(atan(x_46_im, x_46_re) * exp(Float64(y_46_im * Float64(0.0 - atan(x_46_im, x_46_re))))));
                  	else
                  		tmp = t_0;
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -6.1e-15], t$95$0, If[LessEqual[y$46$re, 46000000000000.0], N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * N[Exp[N[(y$46$im * N[(0.0 - N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\
                  \mathbf{if}\;y.re \leq -6.1 \cdot 10^{-15}:\\
                  \;\;\;\;t\_0\\
                  
                  \mathbf{elif}\;y.re \leq 46000000000000:\\
                  \;\;\;\;y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}\right)\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;t\_0\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if y.re < -6.09999999999999972e-15 or 4.6e13 < y.re

                    1. Initial program 34.2%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6471.9

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified71.9%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    7. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      6. *-lowering-*.f6470.2

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    8. Simplified70.2%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

                    if -6.09999999999999972e-15 < y.re < 4.6e13

                    1. Initial program 41.9%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6433.6

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified33.6%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto \color{blue}{y.re \cdot \left(e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto \color{blue}{y.re \cdot \left(e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. *-commutativeN/A

                        \[\leadsto y.re \cdot \color{blue}{\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}\right)} \]
                      3. *-lowering-*.f64N/A

                        \[\leadsto y.re \cdot \color{blue}{\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}\right)} \]
                      4. atan2-lowering-atan2.f64N/A

                        \[\leadsto y.re \cdot \left(\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}} \cdot e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}\right) \]
                      5. exp-lowering-exp.f64N/A

                        \[\leadsto y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot \color{blue}{e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}}\right) \]
                      6. neg-sub0N/A

                        \[\leadsto y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\right) \]
                      7. --lowering--.f64N/A

                        \[\leadsto y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\right) \]
                      8. *-lowering-*.f64N/A

                        \[\leadsto y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\right) \]
                      9. atan2-lowering-atan2.f6453.2

                        \[\leadsto y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}\right) \]
                    8. Simplified53.2%

                      \[\leadsto \color{blue}{y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}\right)} \]
                  3. Recombined 2 regimes into one program.
                  4. Final simplification61.0%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;y.re \leq -6.1 \cdot 10^{-15}:\\ \;\;\;\;\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;y.re \leq 46000000000000:\\ \;\;\;\;y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 17: 57.4% accurate, 2.0× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{if}\;y.re \leq -6.1 \cdot 10^{-15}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;y.re \leq 4.8 \cdot 10^{+23}:\\ \;\;\;\;y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}\right)\\ \mathbf{else}:\\ \;\;\;\;t\_0\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0
                           (*
                            (* y.re (atan2 x.im x.re))
                            (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re))))
                     (if (<= y.re -6.1e-15)
                       t_0
                       (if (<= y.re 4.8e+23)
                         (* y.re (* (atan2 x.im x.re) (exp (* y.im (- 0.0 (atan2 x.im x.re))))))
                         t_0))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = (y_46_re * atan2(x_46_im, x_46_re)) * pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
                  	double tmp;
                  	if (y_46_re <= -6.1e-15) {
                  		tmp = t_0;
                  	} else if (y_46_re <= 4.8e+23) {
                  		tmp = y_46_re * (atan2(x_46_im, x_46_re) * exp((y_46_im * (0.0 - atan2(x_46_im, x_46_re)))));
                  	} else {
                  		tmp = t_0;
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = Float64(Float64(y_46_re * atan(x_46_im, x_46_re)) * (sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re))
                  	tmp = 0.0
                  	if (y_46_re <= -6.1e-15)
                  		tmp = t_0;
                  	elseif (y_46_re <= 4.8e+23)
                  		tmp = Float64(y_46_re * Float64(atan(x_46_im, x_46_re) * exp(Float64(y_46_im * Float64(0.0 - atan(x_46_im, x_46_re))))));
                  	else
                  		tmp = t_0;
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision] * N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -6.1e-15], t$95$0, If[LessEqual[y$46$re, 4.8e+23], N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * N[Exp[N[(y$46$im * N[(0.0 - N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\
                  \mathbf{if}\;y.re \leq -6.1 \cdot 10^{-15}:\\
                  \;\;\;\;t\_0\\
                  
                  \mathbf{elif}\;y.re \leq 4.8 \cdot 10^{+23}:\\
                  \;\;\;\;y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}\right)\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;t\_0\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if y.re < -6.09999999999999972e-15 or 4.8e23 < y.re

                    1. Initial program 33.6%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6471.6

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified71.6%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6468.2

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified68.2%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      6. *-lowering-*.f6467.4

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified67.4%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

                    if -6.09999999999999972e-15 < y.re < 4.8e23

                    1. Initial program 42.3%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6434.1

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified34.1%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto \color{blue}{y.re \cdot \left(e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto \color{blue}{y.re \cdot \left(e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. *-commutativeN/A

                        \[\leadsto y.re \cdot \color{blue}{\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}\right)} \]
                      3. *-lowering-*.f64N/A

                        \[\leadsto y.re \cdot \color{blue}{\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}\right)} \]
                      4. atan2-lowering-atan2.f64N/A

                        \[\leadsto y.re \cdot \left(\color{blue}{\tan^{-1}_* \frac{x.im}{x.re}} \cdot e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}\right) \]
                      5. exp-lowering-exp.f64N/A

                        \[\leadsto y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot \color{blue}{e^{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}}\right) \]
                      6. neg-sub0N/A

                        \[\leadsto y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\right) \]
                      7. --lowering--.f64N/A

                        \[\leadsto y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\right) \]
                      8. *-lowering-*.f64N/A

                        \[\leadsto y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\right) \]
                      9. atan2-lowering-atan2.f6452.8

                        \[\leadsto y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}\right) \]
                    8. Simplified52.8%

                      \[\leadsto \color{blue}{y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}\right)} \]
                  3. Recombined 2 regimes into one program.
                  4. Final simplification59.4%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;y.re \leq -6.1 \cdot 10^{-15}:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{elif}\;y.re \leq 4.8 \cdot 10^{+23}:\\ \;\;\;\;y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot e^{y.im \cdot \left(0 - \tan^{-1}_* \frac{x.im}{x.re}\right)}\right)\\ \mathbf{else}:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 18: 42.1% accurate, 2.1× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ \mathbf{if}\;x.re \leq 3.2 \cdot 10^{-92}:\\ \;\;\;\;t\_0 \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{else}:\\ \;\;\;\;\sin t\_0 \cdot {x.re}^{y.re}\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0 (* y.re (atan2 x.im x.re))))
                     (if (<= x.re 3.2e-92)
                       (* t_0 (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re))
                       (* (sin t_0) (pow x.re y.re)))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = y_46_re * atan2(x_46_im, x_46_re);
                  	double tmp;
                  	if (x_46_re <= 3.2e-92) {
                  		tmp = t_0 * pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
                  	} else {
                  		tmp = sin(t_0) * pow(x_46_re, y_46_re);
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = Float64(y_46_re * atan(x_46_im, x_46_re))
                  	tmp = 0.0
                  	if (x_46_re <= 3.2e-92)
                  		tmp = Float64(t_0 * (sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re));
                  	else
                  		tmp = Float64(sin(t_0) * (x_46_re ^ y_46_re));
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x$46$re, 3.2e-92], N[(t$95$0 * N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision], N[(N[Sin[t$95$0], $MachinePrecision] * N[Power[x$46$re, y$46$re], $MachinePrecision]), $MachinePrecision]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                  \mathbf{if}\;x.re \leq 3.2 \cdot 10^{-92}:\\
                  \;\;\;\;t\_0 \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;\sin t\_0 \cdot {x.re}^{y.re}\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if x.re < 3.1999999999999997e-92

                    1. Initial program 40.7%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6452.5

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified52.5%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6453.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified53.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      6. *-lowering-*.f6442.8

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified42.8%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

                    if 3.1999999999999997e-92 < x.re

                    1. Initial program 33.0%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6447.9

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified47.9%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in x.re around inf

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    7. Step-by-step derivation
                      1. unpow2N/A

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. *-lowering-*.f6449.1

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    8. Simplified49.1%

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    9. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. pow-lowering-pow.f6441.9

                        \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified41.9%

                      \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                  3. Recombined 2 regimes into one program.
                  4. Final simplification42.6%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;x.re \leq 3.2 \cdot 10^{-92}:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}\\ \mathbf{else}:\\ \;\;\;\;\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {x.re}^{y.re}\\ \end{array} \]
                  5. Add Preprocessing

                  Alternative 19: 37.3% accurate, 2.8× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_1 := t\_0 \cdot {x.re}^{y.re}\\ \mathbf{if}\;y.re \leq -210000:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y.re \leq -1.2 \cdot 10^{-165}:\\ \;\;\;\;\sin \left(\frac{-1}{\frac{-1}{t\_0}}\right)\\ \mathbf{elif}\;y.re \leq 9.2 \cdot 10^{-115}:\\ \;\;\;\;\sin \left(\left(y.im \cdot 0.5\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\right)\right)\\ \mathbf{elif}\;y.re \leq 2.15 \cdot 10^{+30}:\\ \;\;\;\;\sin t\_0\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                  (FPCore (x.re x.im y.re y.im)
                   :precision binary64
                   (let* ((t_0 (* y.re (atan2 x.im x.re))) (t_1 (* t_0 (pow x.re y.re))))
                     (if (<= y.re -210000.0)
                       t_1
                       (if (<= y.re -1.2e-165)
                         (sin (/ -1.0 (/ -1.0 t_0)))
                         (if (<= y.re 9.2e-115)
                           (sin (* (* y.im 0.5) (log (fma x.im x.im (* x.re x.re)))))
                           (if (<= y.re 2.15e+30) (sin t_0) t_1))))))
                  double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                  	double t_0 = y_46_re * atan2(x_46_im, x_46_re);
                  	double t_1 = t_0 * pow(x_46_re, y_46_re);
                  	double tmp;
                  	if (y_46_re <= -210000.0) {
                  		tmp = t_1;
                  	} else if (y_46_re <= -1.2e-165) {
                  		tmp = sin((-1.0 / (-1.0 / t_0)));
                  	} else if (y_46_re <= 9.2e-115) {
                  		tmp = sin(((y_46_im * 0.5) * log(fma(x_46_im, x_46_im, (x_46_re * x_46_re)))));
                  	} else if (y_46_re <= 2.15e+30) {
                  		tmp = sin(t_0);
                  	} else {
                  		tmp = t_1;
                  	}
                  	return tmp;
                  }
                  
                  function code(x_46_re, x_46_im, y_46_re, y_46_im)
                  	t_0 = Float64(y_46_re * atan(x_46_im, x_46_re))
                  	t_1 = Float64(t_0 * (x_46_re ^ y_46_re))
                  	tmp = 0.0
                  	if (y_46_re <= -210000.0)
                  		tmp = t_1;
                  	elseif (y_46_re <= -1.2e-165)
                  		tmp = sin(Float64(-1.0 / Float64(-1.0 / t_0)));
                  	elseif (y_46_re <= 9.2e-115)
                  		tmp = sin(Float64(Float64(y_46_im * 0.5) * log(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re)))));
                  	elseif (y_46_re <= 2.15e+30)
                  		tmp = sin(t_0);
                  	else
                  		tmp = t_1;
                  	end
                  	return tmp
                  end
                  
                  code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(t$95$0 * N[Power[x$46$re, y$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -210000.0], t$95$1, If[LessEqual[y$46$re, -1.2e-165], N[Sin[N[(-1.0 / N[(-1.0 / t$95$0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[y$46$re, 9.2e-115], N[Sin[N[(N[(y$46$im * 0.5), $MachinePrecision] * N[Log[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[y$46$re, 2.15e+30], N[Sin[t$95$0], $MachinePrecision], t$95$1]]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                  t_1 := t\_0 \cdot {x.re}^{y.re}\\
                  \mathbf{if}\;y.re \leq -210000:\\
                  \;\;\;\;t\_1\\
                  
                  \mathbf{elif}\;y.re \leq -1.2 \cdot 10^{-165}:\\
                  \;\;\;\;\sin \left(\frac{-1}{\frac{-1}{t\_0}}\right)\\
                  
                  \mathbf{elif}\;y.re \leq 9.2 \cdot 10^{-115}:\\
                  \;\;\;\;\sin \left(\left(y.im \cdot 0.5\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\right)\right)\\
                  
                  \mathbf{elif}\;y.re \leq 2.15 \cdot 10^{+30}:\\
                  \;\;\;\;\sin t\_0\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;t\_1\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 4 regimes
                  2. if y.re < -2.1e5 or 2.15e30 < y.re

                    1. Initial program 32.7%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6471.0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified71.0%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6468.3

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified68.3%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in x.re around inf

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. unpow2N/A

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. *-lowering-*.f6458.5

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified58.5%

                      \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    12. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    13. Step-by-step derivation
                      1. pow-lowering-pow.f6455.8

                        \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    14. Simplified55.8%

                      \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

                    if -2.1e5 < y.re < -1.2000000000000001e-165

                    1. Initial program 40.7%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. flip3-+N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
                      2. clear-numN/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                      3. /-lowering-/.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                    4. Applied egg-rr40.7%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
                    5. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    6. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      6. *-lowering-*.f6427.6

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    7. Simplified27.6%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    8. Taylor expanded in y.re around 0

                      \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                    9. Step-by-step derivation
                      1. Simplified24.9%

                        \[\leadsto \color{blue}{1} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      2. Taylor expanded in y.im around 0

                        \[\leadsto 1 \cdot \sin \left(\frac{1}{\color{blue}{\frac{1}{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}}}\right) \]
                      3. Step-by-step derivation
                        1. /-lowering-/.f64N/A

                          \[\leadsto 1 \cdot \sin \left(\frac{1}{\color{blue}{\frac{1}{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}}}\right) \]
                        2. *-lowering-*.f64N/A

                          \[\leadsto 1 \cdot \sin \left(\frac{1}{\frac{1}{\color{blue}{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}}}\right) \]
                        3. atan2-lowering-atan2.f6437.8

                          \[\leadsto 1 \cdot \sin \left(\frac{1}{\frac{1}{y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}}}\right) \]
                      4. Simplified37.8%

                        \[\leadsto 1 \cdot \sin \left(\frac{1}{\color{blue}{\frac{1}{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}}}\right) \]

                      if -1.2000000000000001e-165 < y.re < 9.19999999999999938e-115

                      1. Initial program 46.3%

                        \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. Add Preprocessing
                      3. Step-by-step derivation
                        1. flip3-+N/A

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
                        2. clear-numN/A

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                        3. /-lowering-/.f64N/A

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                      4. Applied egg-rr44.8%

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
                      5. Taylor expanded in y.im around 0

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      6. Step-by-step derivation
                        1. pow-lowering-pow.f64N/A

                          \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                        2. sqrt-lowering-sqrt.f64N/A

                          \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                        3. unpow2N/A

                          \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                        4. accelerator-lowering-fma.f64N/A

                          \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                        5. unpow2N/A

                          \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                        6. *-lowering-*.f6432.5

                          \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      7. Simplified32.5%

                        \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      8. Taylor expanded in y.re around 0

                        \[\leadsto \color{blue}{\sin \left(\frac{1}{2} \cdot \left(y.im \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)} \]
                      9. Step-by-step derivation
                        1. sin-lowering-sin.f64N/A

                          \[\leadsto \color{blue}{\sin \left(\frac{1}{2} \cdot \left(y.im \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)} \]
                        2. associate-*r*N/A

                          \[\leadsto \sin \color{blue}{\left(\left(\frac{1}{2} \cdot y.im\right) \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)} \]
                        3. *-lowering-*.f64N/A

                          \[\leadsto \sin \color{blue}{\left(\left(\frac{1}{2} \cdot y.im\right) \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)} \]
                        4. *-lowering-*.f64N/A

                          \[\leadsto \sin \left(\color{blue}{\left(\frac{1}{2} \cdot y.im\right)} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \]
                        5. log-lowering-log.f64N/A

                          \[\leadsto \sin \left(\left(\frac{1}{2} \cdot y.im\right) \cdot \color{blue}{\log \left({x.im}^{2} + {x.re}^{2}\right)}\right) \]
                        6. unpow2N/A

                          \[\leadsto \sin \left(\left(\frac{1}{2} \cdot y.im\right) \cdot \log \left(\color{blue}{x.im \cdot x.im} + {x.re}^{2}\right)\right) \]
                        7. accelerator-lowering-fma.f64N/A

                          \[\leadsto \sin \left(\left(\frac{1}{2} \cdot y.im\right) \cdot \log \color{blue}{\left(\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)\right)}\right) \]
                        8. unpow2N/A

                          \[\leadsto \sin \left(\left(\frac{1}{2} \cdot y.im\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)\right)\right) \]
                        9. *-lowering-*.f6425.7

                          \[\leadsto \sin \left(\left(0.5 \cdot y.im\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)\right)\right) \]
                      10. Simplified25.7%

                        \[\leadsto \color{blue}{\sin \left(\left(0.5 \cdot y.im\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\right)\right)} \]

                      if 9.19999999999999938e-115 < y.re < 2.15e30

                      1. Initial program 38.5%

                        \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. Add Preprocessing
                      3. Taylor expanded in y.re around 0

                        \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. Step-by-step derivation
                        1. mul-1-negN/A

                          \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        2. neg-sub0N/A

                          \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        3. --lowering--.f64N/A

                          \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        4. *-lowering-*.f64N/A

                          \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        5. atan2-lowering-atan2.f6432.6

                          \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. Simplified32.6%

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      6. Taylor expanded in y.im around 0

                        \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      7. Step-by-step derivation
                        1. sin-lowering-sin.f64N/A

                          \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                        2. *-lowering-*.f64N/A

                          \[\leadsto \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                        3. atan2-lowering-atan2.f6422.8

                          \[\leadsto \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                      8. Simplified22.8%

                        \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    10. Recombined 4 regimes into one program.
                    11. Final simplification40.3%

                      \[\leadsto \begin{array}{l} \mathbf{if}\;y.re \leq -210000:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {x.re}^{y.re}\\ \mathbf{elif}\;y.re \leq -1.2 \cdot 10^{-165}:\\ \;\;\;\;\sin \left(\frac{-1}{\frac{-1}{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\right)\\ \mathbf{elif}\;y.re \leq 9.2 \cdot 10^{-115}:\\ \;\;\;\;\sin \left(\left(y.im \cdot 0.5\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\right)\right)\\ \mathbf{elif}\;y.re \leq 2.15 \cdot 10^{+30}:\\ \;\;\;\;\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{else}:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {x.re}^{y.re}\\ \end{array} \]
                    12. Add Preprocessing

                    Alternative 20: 37.3% accurate, 2.8× speedup?

                    \[\begin{array}{l} \\ \begin{array}{l} t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_1 := \sin t\_0\\ t_2 := t\_0 \cdot {x.re}^{y.re}\\ \mathbf{if}\;y.re \leq -210000:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y.re \leq -1.75 \cdot 10^{-158}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y.re \leq 9.2 \cdot 10^{-115}:\\ \;\;\;\;\sin \left(\left(y.im \cdot 0.5\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\right)\right)\\ \mathbf{elif}\;y.re \leq 2.15 \cdot 10^{+30}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
                    (FPCore (x.re x.im y.re y.im)
                     :precision binary64
                     (let* ((t_0 (* y.re (atan2 x.im x.re)))
                            (t_1 (sin t_0))
                            (t_2 (* t_0 (pow x.re y.re))))
                       (if (<= y.re -210000.0)
                         t_2
                         (if (<= y.re -1.75e-158)
                           t_1
                           (if (<= y.re 9.2e-115)
                             (sin (* (* y.im 0.5) (log (fma x.im x.im (* x.re x.re)))))
                             (if (<= y.re 2.15e+30) t_1 t_2))))))
                    double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                    	double t_0 = y_46_re * atan2(x_46_im, x_46_re);
                    	double t_1 = sin(t_0);
                    	double t_2 = t_0 * pow(x_46_re, y_46_re);
                    	double tmp;
                    	if (y_46_re <= -210000.0) {
                    		tmp = t_2;
                    	} else if (y_46_re <= -1.75e-158) {
                    		tmp = t_1;
                    	} else if (y_46_re <= 9.2e-115) {
                    		tmp = sin(((y_46_im * 0.5) * log(fma(x_46_im, x_46_im, (x_46_re * x_46_re)))));
                    	} else if (y_46_re <= 2.15e+30) {
                    		tmp = t_1;
                    	} else {
                    		tmp = t_2;
                    	}
                    	return tmp;
                    }
                    
                    function code(x_46_re, x_46_im, y_46_re, y_46_im)
                    	t_0 = Float64(y_46_re * atan(x_46_im, x_46_re))
                    	t_1 = sin(t_0)
                    	t_2 = Float64(t_0 * (x_46_re ^ y_46_re))
                    	tmp = 0.0
                    	if (y_46_re <= -210000.0)
                    		tmp = t_2;
                    	elseif (y_46_re <= -1.75e-158)
                    		tmp = t_1;
                    	elseif (y_46_re <= 9.2e-115)
                    		tmp = sin(Float64(Float64(y_46_im * 0.5) * log(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re)))));
                    	elseif (y_46_re <= 2.15e+30)
                    		tmp = t_1;
                    	else
                    		tmp = t_2;
                    	end
                    	return tmp
                    end
                    
                    code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[Sin[t$95$0], $MachinePrecision]}, Block[{t$95$2 = N[(t$95$0 * N[Power[x$46$re, y$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -210000.0], t$95$2, If[LessEqual[y$46$re, -1.75e-158], t$95$1, If[LessEqual[y$46$re, 9.2e-115], N[Sin[N[(N[(y$46$im * 0.5), $MachinePrecision] * N[Log[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[y$46$re, 2.15e+30], t$95$1, t$95$2]]]]]]]
                    
                    \begin{array}{l}
                    
                    \\
                    \begin{array}{l}
                    t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                    t_1 := \sin t\_0\\
                    t_2 := t\_0 \cdot {x.re}^{y.re}\\
                    \mathbf{if}\;y.re \leq -210000:\\
                    \;\;\;\;t\_2\\
                    
                    \mathbf{elif}\;y.re \leq -1.75 \cdot 10^{-158}:\\
                    \;\;\;\;t\_1\\
                    
                    \mathbf{elif}\;y.re \leq 9.2 \cdot 10^{-115}:\\
                    \;\;\;\;\sin \left(\left(y.im \cdot 0.5\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\right)\right)\\
                    
                    \mathbf{elif}\;y.re \leq 2.15 \cdot 10^{+30}:\\
                    \;\;\;\;t\_1\\
                    
                    \mathbf{else}:\\
                    \;\;\;\;t\_2\\
                    
                    
                    \end{array}
                    \end{array}
                    
                    Derivation
                    1. Split input into 3 regimes
                    2. if y.re < -2.1e5 or 2.15e30 < y.re

                      1. Initial program 32.7%

                        \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. Add Preprocessing
                      3. Taylor expanded in y.im around 0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      4. Step-by-step derivation
                        1. *-lowering-*.f64N/A

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                        2. atan2-lowering-atan2.f6471.0

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                      5. Simplified71.0%

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      6. Taylor expanded in y.re around 0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      7. Step-by-step derivation
                        1. *-lowering-*.f64N/A

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                        2. atan2-lowering-atan2.f6468.3

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                      8. Simplified68.3%

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      9. Taylor expanded in x.re around inf

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      10. Step-by-step derivation
                        1. unpow2N/A

                          \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                        2. *-lowering-*.f6458.5

                          \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      11. Simplified58.5%

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      12. Taylor expanded in y.im around 0

                        \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      13. Step-by-step derivation
                        1. pow-lowering-pow.f6455.8

                          \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      14. Simplified55.8%

                        \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

                      if -2.1e5 < y.re < -1.75000000000000006e-158 or 9.19999999999999938e-115 < y.re < 2.15e30

                      1. Initial program 39.7%

                        \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. Add Preprocessing
                      3. Taylor expanded in y.re around 0

                        \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. Step-by-step derivation
                        1. mul-1-negN/A

                          \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        2. neg-sub0N/A

                          \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        3. --lowering--.f64N/A

                          \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        4. *-lowering-*.f64N/A

                          \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        5. atan2-lowering-atan2.f6436.8

                          \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. Simplified36.8%

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      6. Taylor expanded in y.im around 0

                        \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      7. Step-by-step derivation
                        1. sin-lowering-sin.f64N/A

                          \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                        2. *-lowering-*.f64N/A

                          \[\leadsto \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                        3. atan2-lowering-atan2.f6430.9

                          \[\leadsto \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                      8. Simplified30.9%

                        \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]

                      if -1.75000000000000006e-158 < y.re < 9.19999999999999938e-115

                      1. Initial program 46.3%

                        \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. Add Preprocessing
                      3. Step-by-step derivation
                        1. flip3-+N/A

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}\right)} \]
                        2. clear-numN/A

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                        3. /-lowering-/.f64N/A

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) + \left(\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) - \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right) \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)\right)}{{\left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im\right)}^{3} + {\left(\tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}^{3}}}\right)} \]
                      4. Applied egg-rr44.8%

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right)} \]
                      5. Taylor expanded in y.im around 0

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      6. Step-by-step derivation
                        1. pow-lowering-pow.f64N/A

                          \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                        2. sqrt-lowering-sqrt.f64N/A

                          \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                        3. unpow2N/A

                          \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                        4. accelerator-lowering-fma.f64N/A

                          \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                        5. unpow2N/A

                          \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(\frac{1}{2} \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                        6. *-lowering-*.f6432.5

                          \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      7. Simplified32.5%

                        \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \sin \left(\frac{1}{\frac{1}{\mathsf{fma}\left(0.5 \cdot \log \left(\mathsf{fma}\left(x.re, x.re, x.im \cdot x.im\right)\right), y.im, \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right)}}\right) \]
                      8. Taylor expanded in y.re around 0

                        \[\leadsto \color{blue}{\sin \left(\frac{1}{2} \cdot \left(y.im \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)} \]
                      9. Step-by-step derivation
                        1. sin-lowering-sin.f64N/A

                          \[\leadsto \color{blue}{\sin \left(\frac{1}{2} \cdot \left(y.im \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)\right)} \]
                        2. associate-*r*N/A

                          \[\leadsto \sin \color{blue}{\left(\left(\frac{1}{2} \cdot y.im\right) \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)} \]
                        3. *-lowering-*.f64N/A

                          \[\leadsto \sin \color{blue}{\left(\left(\frac{1}{2} \cdot y.im\right) \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right)} \]
                        4. *-lowering-*.f64N/A

                          \[\leadsto \sin \left(\color{blue}{\left(\frac{1}{2} \cdot y.im\right)} \cdot \log \left({x.im}^{2} + {x.re}^{2}\right)\right) \]
                        5. log-lowering-log.f64N/A

                          \[\leadsto \sin \left(\left(\frac{1}{2} \cdot y.im\right) \cdot \color{blue}{\log \left({x.im}^{2} + {x.re}^{2}\right)}\right) \]
                        6. unpow2N/A

                          \[\leadsto \sin \left(\left(\frac{1}{2} \cdot y.im\right) \cdot \log \left(\color{blue}{x.im \cdot x.im} + {x.re}^{2}\right)\right) \]
                        7. accelerator-lowering-fma.f64N/A

                          \[\leadsto \sin \left(\left(\frac{1}{2} \cdot y.im\right) \cdot \log \color{blue}{\left(\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)\right)}\right) \]
                        8. unpow2N/A

                          \[\leadsto \sin \left(\left(\frac{1}{2} \cdot y.im\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)\right)\right) \]
                        9. *-lowering-*.f6425.7

                          \[\leadsto \sin \left(\left(0.5 \cdot y.im\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)\right)\right) \]
                      10. Simplified25.7%

                        \[\leadsto \color{blue}{\sin \left(\left(0.5 \cdot y.im\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\right)\right)} \]
                    3. Recombined 3 regimes into one program.
                    4. Final simplification40.3%

                      \[\leadsto \begin{array}{l} \mathbf{if}\;y.re \leq -210000:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {x.re}^{y.re}\\ \mathbf{elif}\;y.re \leq -1.75 \cdot 10^{-158}:\\ \;\;\;\;\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{elif}\;y.re \leq 9.2 \cdot 10^{-115}:\\ \;\;\;\;\sin \left(\left(y.im \cdot 0.5\right) \cdot \log \left(\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)\right)\right)\\ \mathbf{elif}\;y.re \leq 2.15 \cdot 10^{+30}:\\ \;\;\;\;\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{else}:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {x.re}^{y.re}\\ \end{array} \]
                    5. Add Preprocessing

                    Alternative 21: 42.7% accurate, 2.9× speedup?

                    \[\begin{array}{l} \\ \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re} \end{array} \]
                    (FPCore (x.re x.im y.re y.im)
                     :precision binary64
                     (*
                      (* y.re (atan2 x.im x.re))
                      (pow (sqrt (fma x.im x.im (* x.re x.re))) y.re)))
                    double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                    	return (y_46_re * atan2(x_46_im, x_46_re)) * pow(sqrt(fma(x_46_im, x_46_im, (x_46_re * x_46_re))), y_46_re);
                    }
                    
                    function code(x_46_re, x_46_im, y_46_re, y_46_im)
                    	return Float64(Float64(y_46_re * atan(x_46_im, x_46_re)) * (sqrt(fma(x_46_im, x_46_im, Float64(x_46_re * x_46_re))) ^ y_46_re))
                    end
                    
                    code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := N[(N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision] * N[Power[N[Sqrt[N[(x$46$im * x$46$im + N[(x$46$re * x$46$re), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision]
                    
                    \begin{array}{l}
                    
                    \\
                    \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}
                    \end{array}
                    
                    Derivation
                    1. Initial program 38.4%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.im around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    4. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6451.1

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    5. Simplified51.1%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    6. Taylor expanded in y.re around 0

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. atan2-lowering-atan2.f6449.5

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified49.5%

                      \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    10. Step-by-step derivation
                      1. pow-lowering-pow.f64N/A

                        \[\leadsto \color{blue}{{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      2. sqrt-lowering-sqrt.f64N/A

                        \[\leadsto {\color{blue}{\left(\sqrt{{x.im}^{2} + {x.re}^{2}}\right)}}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      3. unpow2N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{x.im \cdot x.im} + {x.re}^{2}}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      4. accelerator-lowering-fma.f64N/A

                        \[\leadsto {\left(\sqrt{\color{blue}{\mathsf{fma}\left(x.im, x.im, {x.re}^{2}\right)}}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      5. unpow2N/A

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      6. *-lowering-*.f6440.9

                        \[\leadsto {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, \color{blue}{x.re \cdot x.re}\right)}\right)}^{y.re} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    11. Simplified40.9%

                      \[\leadsto \color{blue}{{\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                    12. Final simplification40.9%

                      \[\leadsto \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\sqrt{\mathsf{fma}\left(x.im, x.im, x.re \cdot x.re\right)}\right)}^{y.re} \]
                    13. Add Preprocessing

                    Alternative 22: 35.4% accurate, 3.0× speedup?

                    \[\begin{array}{l} \\ \begin{array}{l} t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\ t_1 := t\_0 \cdot {x.re}^{y.re}\\ \mathbf{if}\;y.re \leq -210000:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y.re \leq 2.15 \cdot 10^{+30}:\\ \;\;\;\;\sin t\_0\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                    (FPCore (x.re x.im y.re y.im)
                     :precision binary64
                     (let* ((t_0 (* y.re (atan2 x.im x.re))) (t_1 (* t_0 (pow x.re y.re))))
                       (if (<= y.re -210000.0) t_1 (if (<= y.re 2.15e+30) (sin t_0) t_1))))
                    double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                    	double t_0 = y_46_re * atan2(x_46_im, x_46_re);
                    	double t_1 = t_0 * pow(x_46_re, y_46_re);
                    	double tmp;
                    	if (y_46_re <= -210000.0) {
                    		tmp = t_1;
                    	} else if (y_46_re <= 2.15e+30) {
                    		tmp = sin(t_0);
                    	} else {
                    		tmp = t_1;
                    	}
                    	return tmp;
                    }
                    
                    real(8) function code(x_46re, x_46im, y_46re, y_46im)
                        real(8), intent (in) :: x_46re
                        real(8), intent (in) :: x_46im
                        real(8), intent (in) :: y_46re
                        real(8), intent (in) :: y_46im
                        real(8) :: t_0
                        real(8) :: t_1
                        real(8) :: tmp
                        t_0 = y_46re * atan2(x_46im, x_46re)
                        t_1 = t_0 * (x_46re ** y_46re)
                        if (y_46re <= (-210000.0d0)) then
                            tmp = t_1
                        else if (y_46re <= 2.15d+30) then
                            tmp = sin(t_0)
                        else
                            tmp = t_1
                        end if
                        code = tmp
                    end function
                    
                    public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                    	double t_0 = y_46_re * Math.atan2(x_46_im, x_46_re);
                    	double t_1 = t_0 * Math.pow(x_46_re, y_46_re);
                    	double tmp;
                    	if (y_46_re <= -210000.0) {
                    		tmp = t_1;
                    	} else if (y_46_re <= 2.15e+30) {
                    		tmp = Math.sin(t_0);
                    	} else {
                    		tmp = t_1;
                    	}
                    	return tmp;
                    }
                    
                    def code(x_46_re, x_46_im, y_46_re, y_46_im):
                    	t_0 = y_46_re * math.atan2(x_46_im, x_46_re)
                    	t_1 = t_0 * math.pow(x_46_re, y_46_re)
                    	tmp = 0
                    	if y_46_re <= -210000.0:
                    		tmp = t_1
                    	elif y_46_re <= 2.15e+30:
                    		tmp = math.sin(t_0)
                    	else:
                    		tmp = t_1
                    	return tmp
                    
                    function code(x_46_re, x_46_im, y_46_re, y_46_im)
                    	t_0 = Float64(y_46_re * atan(x_46_im, x_46_re))
                    	t_1 = Float64(t_0 * (x_46_re ^ y_46_re))
                    	tmp = 0.0
                    	if (y_46_re <= -210000.0)
                    		tmp = t_1;
                    	elseif (y_46_re <= 2.15e+30)
                    		tmp = sin(t_0);
                    	else
                    		tmp = t_1;
                    	end
                    	return tmp
                    end
                    
                    function tmp_2 = code(x_46_re, x_46_im, y_46_re, y_46_im)
                    	t_0 = y_46_re * atan2(x_46_im, x_46_re);
                    	t_1 = t_0 * (x_46_re ^ y_46_re);
                    	tmp = 0.0;
                    	if (y_46_re <= -210000.0)
                    		tmp = t_1;
                    	elseif (y_46_re <= 2.15e+30)
                    		tmp = sin(t_0);
                    	else
                    		tmp = t_1;
                    	end
                    	tmp_2 = tmp;
                    end
                    
                    code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(t$95$0 * N[Power[x$46$re, y$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -210000.0], t$95$1, If[LessEqual[y$46$re, 2.15e+30], N[Sin[t$95$0], $MachinePrecision], t$95$1]]]]
                    
                    \begin{array}{l}
                    
                    \\
                    \begin{array}{l}
                    t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
                    t_1 := t\_0 \cdot {x.re}^{y.re}\\
                    \mathbf{if}\;y.re \leq -210000:\\
                    \;\;\;\;t\_1\\
                    
                    \mathbf{elif}\;y.re \leq 2.15 \cdot 10^{+30}:\\
                    \;\;\;\;\sin t\_0\\
                    
                    \mathbf{else}:\\
                    \;\;\;\;t\_1\\
                    
                    
                    \end{array}
                    \end{array}
                    
                    Derivation
                    1. Split input into 2 regimes
                    2. if y.re < -2.1e5 or 2.15e30 < y.re

                      1. Initial program 32.7%

                        \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. Add Preprocessing
                      3. Taylor expanded in y.im around 0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      4. Step-by-step derivation
                        1. *-lowering-*.f64N/A

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                        2. atan2-lowering-atan2.f6471.0

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                      5. Simplified71.0%

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      6. Taylor expanded in y.re around 0

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      7. Step-by-step derivation
                        1. *-lowering-*.f64N/A

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                        2. atan2-lowering-atan2.f6468.3

                          \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                      8. Simplified68.3%

                        \[\leadsto e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      9. Taylor expanded in x.re around inf

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{{x.re}^{2}}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      10. Step-by-step derivation
                        1. unpow2N/A

                          \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                        2. *-lowering-*.f6458.5

                          \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      11. Simplified58.5%

                        \[\leadsto e^{\log \left(\sqrt{\color{blue}{x.re \cdot x.re}}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      12. Taylor expanded in y.im around 0

                        \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      13. Step-by-step derivation
                        1. pow-lowering-pow.f6455.8

                          \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]
                      14. Simplified55.8%

                        \[\leadsto \color{blue}{{x.re}^{y.re}} \cdot \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \]

                      if -2.1e5 < y.re < 2.15e30

                      1. Initial program 42.7%

                        \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. Add Preprocessing
                      3. Taylor expanded in y.re around 0

                        \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. Step-by-step derivation
                        1. mul-1-negN/A

                          \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        2. neg-sub0N/A

                          \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        3. --lowering--.f64N/A

                          \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        4. *-lowering-*.f64N/A

                          \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                        5. atan2-lowering-atan2.f6441.0

                          \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. Simplified41.0%

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      6. Taylor expanded in y.im around 0

                        \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      7. Step-by-step derivation
                        1. sin-lowering-sin.f64N/A

                          \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                        2. *-lowering-*.f64N/A

                          \[\leadsto \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                        3. atan2-lowering-atan2.f6422.4

                          \[\leadsto \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                      8. Simplified22.4%

                        \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    3. Recombined 2 regimes into one program.
                    4. Final simplification36.8%

                      \[\leadsto \begin{array}{l} \mathbf{if}\;y.re \leq -210000:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {x.re}^{y.re}\\ \mathbf{elif}\;y.re \leq 2.15 \cdot 10^{+30}:\\ \;\;\;\;\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\ \mathbf{else}:\\ \;\;\;\;\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {x.re}^{y.re}\\ \end{array} \]
                    5. Add Preprocessing

                    Alternative 23: 13.4% accurate, 3.3× speedup?

                    \[\begin{array}{l} \\ \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \end{array} \]
                    (FPCore (x.re x.im y.re y.im)
                     :precision binary64
                     (sin (* y.re (atan2 x.im x.re))))
                    double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                    	return sin((y_46_re * atan2(x_46_im, x_46_re)));
                    }
                    
                    real(8) function code(x_46re, x_46im, y_46re, y_46im)
                        real(8), intent (in) :: x_46re
                        real(8), intent (in) :: x_46im
                        real(8), intent (in) :: y_46re
                        real(8), intent (in) :: y_46im
                        code = sin((y_46re * atan2(x_46im, x_46re)))
                    end function
                    
                    public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                    	return Math.sin((y_46_re * Math.atan2(x_46_im, x_46_re)));
                    }
                    
                    def code(x_46_re, x_46_im, y_46_re, y_46_im):
                    	return math.sin((y_46_re * math.atan2(x_46_im, x_46_re)))
                    
                    function code(x_46_re, x_46_im, y_46_re, y_46_im)
                    	return sin(Float64(y_46_re * atan(x_46_im, x_46_re)))
                    end
                    
                    function tmp = code(x_46_re, x_46_im, y_46_re, y_46_im)
                    	tmp = sin((y_46_re * atan2(x_46_im, x_46_re)));
                    end
                    
                    code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
                    
                    \begin{array}{l}
                    
                    \\
                    \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)
                    \end{array}
                    
                    Derivation
                    1. Initial program 38.4%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.re around 0

                      \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    4. Step-by-step derivation
                      1. mul-1-negN/A

                        \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. neg-sub0N/A

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      3. --lowering--.f64N/A

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. *-lowering-*.f64N/A

                        \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. atan2-lowering-atan2.f6427.2

                        \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    5. Simplified27.2%

                      \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    6. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. sin-lowering-sin.f64N/A

                        \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. *-lowering-*.f64N/A

                        \[\leadsto \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      3. atan2-lowering-atan2.f6415.7

                        \[\leadsto \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified15.7%

                      \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Add Preprocessing

                    Alternative 24: 13.4% accurate, 6.4× speedup?

                    \[\begin{array}{l} \\ y.re \cdot \tan^{-1}_* \frac{x.im}{x.re} \end{array} \]
                    (FPCore (x.re x.im y.re y.im) :precision binary64 (* y.re (atan2 x.im x.re)))
                    double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                    	return y_46_re * atan2(x_46_im, x_46_re);
                    }
                    
                    real(8) function code(x_46re, x_46im, y_46re, y_46im)
                        real(8), intent (in) :: x_46re
                        real(8), intent (in) :: x_46im
                        real(8), intent (in) :: y_46re
                        real(8), intent (in) :: y_46im
                        code = y_46re * atan2(x_46im, x_46re)
                    end function
                    
                    public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
                    	return y_46_re * Math.atan2(x_46_im, x_46_re);
                    }
                    
                    def code(x_46_re, x_46_im, y_46_re, y_46_im):
                    	return y_46_re * math.atan2(x_46_im, x_46_re)
                    
                    function code(x_46_re, x_46_im, y_46_re, y_46_im)
                    	return Float64(y_46_re * atan(x_46_im, x_46_re))
                    end
                    
                    function tmp = code(x_46_re, x_46_im, y_46_re, y_46_im)
                    	tmp = y_46_re * atan2(x_46_im, x_46_re);
                    end
                    
                    code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]
                    
                    \begin{array}{l}
                    
                    \\
                    y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}
                    \end{array}
                    
                    Derivation
                    1. Initial program 38.4%

                      \[e^{\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.re - \tan^{-1}_* \frac{x.im}{x.re} \cdot y.im} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    2. Add Preprocessing
                    3. Taylor expanded in y.re around 0

                      \[\leadsto e^{\color{blue}{-1 \cdot \left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    4. Step-by-step derivation
                      1. mul-1-negN/A

                        \[\leadsto e^{\color{blue}{\mathsf{neg}\left(y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      2. neg-sub0N/A

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      3. --lowering--.f64N/A

                        \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      4. *-lowering-*.f64N/A

                        \[\leadsto e^{0 - \color{blue}{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                      5. atan2-lowering-atan2.f6427.2

                        \[\leadsto e^{0 - y.im \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    5. Simplified27.2%

                      \[\leadsto e^{\color{blue}{0 - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) \cdot y.im + \tan^{-1}_* \frac{x.im}{x.re} \cdot y.re\right) \]
                    6. Taylor expanded in y.im around 0

                      \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    7. Step-by-step derivation
                      1. sin-lowering-sin.f64N/A

                        \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      2. *-lowering-*.f64N/A

                        \[\leadsto \sin \color{blue}{\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                      3. atan2-lowering-atan2.f6415.7

                        \[\leadsto \sin \left(y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}}\right) \]
                    8. Simplified15.7%

                      \[\leadsto \color{blue}{\sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)} \]
                    9. Taylor expanded in y.re around 0

                      \[\leadsto \color{blue}{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}} \]
                    10. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto \color{blue}{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}} \]
                      2. atan2-lowering-atan2.f6415.7

                        \[\leadsto y.re \cdot \color{blue}{\tan^{-1}_* \frac{x.im}{x.re}} \]
                    11. Simplified15.7%

                      \[\leadsto \color{blue}{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}} \]
                    12. Add Preprocessing

                    Reproduce

                    ?
                    herbie shell --seed 2024194 
                    (FPCore (x.re x.im y.re y.im)
                      :name "powComplex, imaginary part"
                      :precision binary64
                      (* (exp (- (* (log (sqrt (+ (* x.re x.re) (* x.im x.im)))) y.re) (* (atan2 x.im x.re) y.im))) (sin (+ (* (log (sqrt (+ (* x.re x.re) (* x.im x.im)))) y.im) (* (atan2 x.im x.re) y.re)))))