
(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:
Herbie found 18 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(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}
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0
(exp
(fma (log (hypot x.re x.im)) y.re (* (atan2 x.im x.re) (- y.im)))))
(t_1 (* y.im (log (hypot x.im x.re))))
(t_2 (sin t_1)))
(if (<= y.im -9e+183)
(/ (* y.re (atan2 x.im x.re)) (exp (* y.im (atan2 x.im x.re))))
(if (<= y.im 2.4e-63)
(* t_0 (+ (* y.re (* (atan2 x.im x.re) (cos t_1))) t_2))
(* t_0 t_2)))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = exp(fma(log(hypot(x_46_re, x_46_im)), y_46_re, (atan2(x_46_im, x_46_re) * -y_46_im)));
double t_1 = y_46_im * log(hypot(x_46_im, x_46_re));
double t_2 = sin(t_1);
double tmp;
if (y_46_im <= -9e+183) {
tmp = (y_46_re * atan2(x_46_im, x_46_re)) / exp((y_46_im * atan2(x_46_im, x_46_re)));
} else if (y_46_im <= 2.4e-63) {
tmp = t_0 * ((y_46_re * (atan2(x_46_im, x_46_re) * cos(t_1))) + t_2);
} else {
tmp = t_0 * t_2;
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = exp(fma(log(hypot(x_46_re, x_46_im)), y_46_re, Float64(atan(x_46_im, x_46_re) * Float64(-y_46_im)))) t_1 = Float64(y_46_im * log(hypot(x_46_im, x_46_re))) t_2 = sin(t_1) tmp = 0.0 if (y_46_im <= -9e+183) tmp = Float64(Float64(y_46_re * atan(x_46_im, x_46_re)) / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))); elseif (y_46_im <= 2.4e-63) tmp = Float64(t_0 * Float64(Float64(y_46_re * Float64(atan(x_46_im, x_46_re) * cos(t_1))) + t_2)); else tmp = Float64(t_0 * t_2); end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[Exp[N[(N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision] * y$46$re + N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * (-y$46$im)), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$1 = N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Sin[t$95$1], $MachinePrecision]}, If[LessEqual[y$46$im, -9e+183], N[(N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision] / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$im, 2.4e-63], N[(t$95$0 * N[(N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * N[Cos[t$95$1], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$2), $MachinePrecision]), $MachinePrecision], N[(t$95$0 * t$95$2), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := e^{\mathsf{fma}\left(\log \left(\mathsf{hypot}\left(x.re, x.im\right)\right), y.re, \tan^{-1}_* \frac{x.im}{x.re} \cdot \left(-y.im\right)\right)}\\
t_1 := y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\\
t_2 := \sin t\_1\\
\mathbf{if}\;y.im \leq -9 \cdot 10^{+183}:\\
\;\;\;\;\frac{y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.im \leq 2.4 \cdot 10^{-63}:\\
\;\;\;\;t\_0 \cdot \left(y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot \cos t\_1\right) + t\_2\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0 \cdot t\_2\\
\end{array}
\end{array}
if y.im < -9.00000000000000034e183Initial program 19.0%
exp-diff19.0%
exp-to-pow19.0%
hypot-define19.0%
*-commutative19.0%
exp-prod19.0%
fma-define19.0%
hypot-define28.8%
*-commutative28.8%
Simplified28.8%
Taylor expanded in y.im around 0 47.9%
add-sqr-sqrt14.6%
pow214.6%
*-commutative14.6%
Applied egg-rr14.6%
Taylor expanded in y.re around 0 67.0%
if -9.00000000000000034e183 < y.im < 2.4000000000000001e-63Initial program 52.6%
fma-neg52.6%
hypot-define52.6%
distribute-rgt-neg-out52.6%
fma-define52.6%
hypot-define87.4%
*-commutative87.4%
Simplified87.4%
Taylor expanded in y.re around 0 51.8%
+-commutative51.8%
*-commutative51.8%
unpow251.8%
unpow251.8%
hypot-undefine51.8%
unpow251.8%
unpow251.8%
hypot-undefine89.2%
Simplified89.2%
if 2.4000000000000001e-63 < y.im Initial program 40.1%
fma-neg40.1%
hypot-define40.1%
distribute-rgt-neg-out40.1%
fma-define40.1%
hypot-define77.9%
*-commutative77.9%
Simplified77.9%
Taylor expanded in y.re around 0 43.5%
unpow243.5%
unpow243.5%
hypot-undefine83.6%
Simplified83.6%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re)))
(t_1 (log (hypot x.im x.re)))
(t_2
(exp
(fma (log (hypot x.re x.im)) y.re (* (atan2 x.im x.re) (- y.im))))))
(if (<= y.im 2e-63)
(* t_2 (+ (sin t_0) (* y.im (* t_1 (cos t_0)))))
(* t_2 (sin (* y.im 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 = log(hypot(x_46_im, x_46_re));
double t_2 = exp(fma(log(hypot(x_46_re, x_46_im)), y_46_re, (atan2(x_46_im, x_46_re) * -y_46_im)));
double tmp;
if (y_46_im <= 2e-63) {
tmp = t_2 * (sin(t_0) + (y_46_im * (t_1 * cos(t_0))));
} else {
tmp = t_2 * sin((y_46_im * 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 = log(hypot(x_46_im, x_46_re)) t_2 = exp(fma(log(hypot(x_46_re, x_46_im)), y_46_re, Float64(atan(x_46_im, x_46_re) * Float64(-y_46_im)))) tmp = 0.0 if (y_46_im <= 2e-63) tmp = Float64(t_2 * Float64(sin(t_0) + Float64(y_46_im * Float64(t_1 * cos(t_0))))); else tmp = Float64(t_2 * sin(Float64(y_46_im * 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[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[Exp[N[(N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision] * y$46$re + N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * (-y$46$im)), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[y$46$im, 2e-63], N[(t$95$2 * N[(N[Sin[t$95$0], $MachinePrecision] + N[(y$46$im * N[(t$95$1 * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$2 * N[Sin[N[(y$46$im * t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\\
t_2 := e^{\mathsf{fma}\left(\log \left(\mathsf{hypot}\left(x.re, x.im\right)\right), y.re, \tan^{-1}_* \frac{x.im}{x.re} \cdot \left(-y.im\right)\right)}\\
\mathbf{if}\;y.im \leq 2 \cdot 10^{-63}:\\
\;\;\;\;t\_2 \cdot \left(\sin t\_0 + y.im \cdot \left(t\_1 \cdot \cos t\_0\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2 \cdot \sin \left(y.im \cdot t\_1\right)\\
\end{array}
\end{array}
if y.im < 2.00000000000000013e-63Initial program 48.4%
fma-neg48.4%
hypot-define48.4%
distribute-rgt-neg-out48.4%
fma-define48.4%
hypot-define80.0%
*-commutative80.0%
Simplified80.0%
Taylor expanded in y.im around 0 57.4%
unpow257.4%
unpow257.4%
hypot-undefine82.5%
Simplified82.5%
if 2.00000000000000013e-63 < y.im Initial program 40.1%
fma-neg40.1%
hypot-define40.1%
distribute-rgt-neg-out40.1%
fma-define40.1%
hypot-define77.9%
*-commutative77.9%
Simplified77.9%
Taylor expanded in y.re around 0 43.5%
unpow243.5%
unpow243.5%
hypot-undefine83.6%
Simplified83.6%
Final simplification82.9%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (log (hypot x.re x.im)))
(t_1 (exp (fma t_0 y.re (* (atan2 x.im x.re) (- y.im)))))
(t_2 (* y.re (atan2 x.im x.re))))
(if (<= y.im -2.75e+178)
(/ t_2 (exp (* y.im (atan2 x.im x.re))))
(if (<= y.im 3e-63)
(* t_1 (sin (fma t_0 y.im t_2)))
(* t_1 (sin (* y.im (log (hypot x.im x.re)))))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = log(hypot(x_46_re, x_46_im));
double t_1 = exp(fma(t_0, y_46_re, (atan2(x_46_im, x_46_re) * -y_46_im)));
double t_2 = y_46_re * atan2(x_46_im, x_46_re);
double tmp;
if (y_46_im <= -2.75e+178) {
tmp = t_2 / exp((y_46_im * atan2(x_46_im, x_46_re)));
} else if (y_46_im <= 3e-63) {
tmp = t_1 * sin(fma(t_0, y_46_im, t_2));
} else {
tmp = t_1 * sin((y_46_im * log(hypot(x_46_im, x_46_re))));
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = log(hypot(x_46_re, x_46_im)) t_1 = exp(fma(t_0, y_46_re, Float64(atan(x_46_im, x_46_re) * Float64(-y_46_im)))) t_2 = Float64(y_46_re * atan(x_46_im, x_46_re)) tmp = 0.0 if (y_46_im <= -2.75e+178) tmp = Float64(t_2 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))); elseif (y_46_im <= 3e-63) tmp = Float64(t_1 * sin(fma(t_0, y_46_im, t_2))); else tmp = Float64(t_1 * sin(Float64(y_46_im * log(hypot(x_46_im, 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[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$1 = N[Exp[N[(t$95$0 * y$46$re + N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * (-y$46$im)), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$im, -2.75e+178], N[(t$95$2 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$im, 3e-63], N[(t$95$1 * N[Sin[N[(t$95$0 * y$46$im + t$95$2), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(t$95$1 * N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)\\
t_1 := e^{\mathsf{fma}\left(t\_0, y.re, \tan^{-1}_* \frac{x.im}{x.re} \cdot \left(-y.im\right)\right)}\\
t_2 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
\mathbf{if}\;y.im \leq -2.75 \cdot 10^{+178}:\\
\;\;\;\;\frac{t\_2}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.im \leq 3 \cdot 10^{-63}:\\
\;\;\;\;t\_1 \cdot \sin \left(\mathsf{fma}\left(t\_0, y.im, t\_2\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1 \cdot \sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right)\\
\end{array}
\end{array}
if y.im < -2.7500000000000001e178Initial program 18.2%
exp-diff18.2%
exp-to-pow18.2%
hypot-define18.2%
*-commutative18.2%
exp-prod18.2%
fma-define18.2%
hypot-define27.5%
*-commutative27.5%
Simplified27.5%
Taylor expanded in y.im around 0 45.7%
add-sqr-sqrt13.9%
pow213.9%
*-commutative13.9%
Applied egg-rr13.9%
Taylor expanded in y.re around 0 64.0%
if -2.7500000000000001e178 < y.im < 2.99999999999999979e-63Initial program 53.0%
fma-neg53.0%
hypot-define53.0%
distribute-rgt-neg-out53.0%
fma-define53.0%
hypot-define88.0%
*-commutative88.0%
Simplified88.0%
if 2.99999999999999979e-63 < y.im Initial program 40.1%
fma-neg40.1%
hypot-define40.1%
distribute-rgt-neg-out40.1%
fma-define40.1%
hypot-define77.9%
*-commutative77.9%
Simplified77.9%
Taylor expanded in y.re around 0 43.5%
unpow243.5%
unpow243.5%
hypot-undefine83.6%
Simplified83.6%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (log (hypot x.re x.im))) (t_1 (* y.re (atan2 x.im x.re))))
(if (<= y.im -4e+170)
(/ t_1 (exp (* y.im (atan2 x.im x.re))))
(if (<= y.im 2.35e-63)
(*
(sin (fma t_0 y.im t_1))
(/ (pow (hypot x.re x.im) y.re) (pow (exp y.im) (atan2 x.im x.re))))
(*
(exp (fma t_0 y.re (* (atan2 x.im x.re) (- y.im))))
(sin (* y.im (log (hypot x.im x.re)))))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = log(hypot(x_46_re, x_46_im));
double t_1 = y_46_re * atan2(x_46_im, x_46_re);
double tmp;
if (y_46_im <= -4e+170) {
tmp = t_1 / exp((y_46_im * atan2(x_46_im, x_46_re)));
} else if (y_46_im <= 2.35e-63) {
tmp = sin(fma(t_0, y_46_im, t_1)) * (pow(hypot(x_46_re, x_46_im), y_46_re) / pow(exp(y_46_im), atan2(x_46_im, x_46_re)));
} else {
tmp = exp(fma(t_0, y_46_re, (atan2(x_46_im, x_46_re) * -y_46_im))) * sin((y_46_im * log(hypot(x_46_im, x_46_re))));
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = log(hypot(x_46_re, x_46_im)) t_1 = Float64(y_46_re * atan(x_46_im, x_46_re)) tmp = 0.0 if (y_46_im <= -4e+170) tmp = Float64(t_1 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))); elseif (y_46_im <= 2.35e-63) tmp = Float64(sin(fma(t_0, y_46_im, t_1)) * Float64((hypot(x_46_re, x_46_im) ^ y_46_re) / (exp(y_46_im) ^ atan(x_46_im, x_46_re)))); else tmp = Float64(exp(fma(t_0, y_46_re, Float64(atan(x_46_im, x_46_re) * Float64(-y_46_im)))) * sin(Float64(y_46_im * log(hypot(x_46_im, 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[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$im, -4e+170], N[(t$95$1 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$im, 2.35e-63], N[(N[Sin[N[(t$95$0 * y$46$im + t$95$1), $MachinePrecision]], $MachinePrecision] * N[(N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] / N[Power[N[Exp[y$46$im], $MachinePrecision], N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Exp[N[(t$95$0 * y$46$re + N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * (-y$46$im)), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)\\
t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
\mathbf{if}\;y.im \leq -4 \cdot 10^{+170}:\\
\;\;\;\;\frac{t\_1}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.im \leq 2.35 \cdot 10^{-63}:\\
\;\;\;\;\sin \left(\mathsf{fma}\left(t\_0, y.im, t\_1\right)\right) \cdot \frac{{\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}}{{\left(e^{y.im}\right)}^{\tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{else}:\\
\;\;\;\;e^{\mathsf{fma}\left(t\_0, y.re, \tan^{-1}_* \frac{x.im}{x.re} \cdot \left(-y.im\right)\right)} \cdot \sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right)\\
\end{array}
\end{array}
if y.im < -4.00000000000000014e170Initial program 18.2%
exp-diff18.2%
exp-to-pow18.2%
hypot-define18.2%
*-commutative18.2%
exp-prod18.2%
fma-define18.2%
hypot-define27.5%
*-commutative27.5%
Simplified27.5%
Taylor expanded in y.im around 0 45.7%
add-sqr-sqrt13.9%
pow213.9%
*-commutative13.9%
Applied egg-rr13.9%
Taylor expanded in y.re around 0 64.0%
if -4.00000000000000014e170 < y.im < 2.35e-63Initial program 53.0%
exp-diff51.6%
exp-to-pow51.6%
hypot-define51.6%
*-commutative51.6%
exp-prod51.5%
fma-define51.5%
hypot-define86.4%
*-commutative86.4%
Simplified86.4%
if 2.35e-63 < y.im Initial program 40.1%
fma-neg40.1%
hypot-define40.1%
distribute-rgt-neg-out40.1%
fma-define40.1%
hypot-define77.9%
*-commutative77.9%
Simplified77.9%
Taylor expanded in y.re around 0 43.5%
unpow243.5%
unpow243.5%
hypot-undefine83.6%
Simplified83.6%
Final simplification83.5%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (log (hypot x.im x.re))) (t_1 (* y.re (atan2 x.im x.re))))
(if (<= y.im -1.8e+173)
(/ t_1 (exp (* y.im (atan2 x.im x.re))))
(if (or (<= y.im -2.1e-11) (not (<= y.im 7.8e-64)))
(*
(exp (fma (log (hypot x.re x.im)) y.re (* (atan2 x.im x.re) (- y.im))))
(sin (* y.im t_0)))
(*
(+ (sin t_1) (* y.im (* t_0 (cos t_1))))
(pow (hypot 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(hypot(x_46_im, x_46_re));
double t_1 = y_46_re * atan2(x_46_im, x_46_re);
double tmp;
if (y_46_im <= -1.8e+173) {
tmp = t_1 / exp((y_46_im * atan2(x_46_im, x_46_re)));
} else if ((y_46_im <= -2.1e-11) || !(y_46_im <= 7.8e-64)) {
tmp = exp(fma(log(hypot(x_46_re, x_46_im)), y_46_re, (atan2(x_46_im, x_46_re) * -y_46_im))) * sin((y_46_im * t_0));
} else {
tmp = (sin(t_1) + (y_46_im * (t_0 * cos(t_1)))) * pow(hypot(x_46_im, x_46_re), y_46_re);
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = log(hypot(x_46_im, x_46_re)) t_1 = Float64(y_46_re * atan(x_46_im, x_46_re)) tmp = 0.0 if (y_46_im <= -1.8e+173) tmp = Float64(t_1 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))); elseif ((y_46_im <= -2.1e-11) || !(y_46_im <= 7.8e-64)) tmp = Float64(exp(fma(log(hypot(x_46_re, x_46_im)), y_46_re, Float64(atan(x_46_im, x_46_re) * Float64(-y_46_im)))) * sin(Float64(y_46_im * t_0))); else tmp = Float64(Float64(sin(t_1) + Float64(y_46_im * Float64(t_0 * cos(t_1)))) * (hypot(x_46_im, 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[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$im, -1.8e+173], N[(t$95$1 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[y$46$im, -2.1e-11], N[Not[LessEqual[y$46$im, 7.8e-64]], $MachinePrecision]], N[(N[Exp[N[(N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision] * y$46$re + N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * (-y$46$im)), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(y$46$im * t$95$0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[(N[Sin[t$95$1], $MachinePrecision] + N[(y$46$im * N[(t$95$0 * N[Cos[t$95$1], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\\
t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
\mathbf{if}\;y.im \leq -1.8 \cdot 10^{+173}:\\
\;\;\;\;\frac{t\_1}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.im \leq -2.1 \cdot 10^{-11} \lor \neg \left(y.im \leq 7.8 \cdot 10^{-64}\right):\\
\;\;\;\;e^{\mathsf{fma}\left(\log \left(\mathsf{hypot}\left(x.re, x.im\right)\right), y.re, \tan^{-1}_* \frac{x.im}{x.re} \cdot \left(-y.im\right)\right)} \cdot \sin \left(y.im \cdot t\_0\right)\\
\mathbf{else}:\\
\;\;\;\;\left(\sin t\_1 + y.im \cdot \left(t\_0 \cdot \cos t\_1\right)\right) \cdot {\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re}\\
\end{array}
\end{array}
if y.im < -1.8000000000000001e173Initial program 18.2%
exp-diff18.2%
exp-to-pow18.2%
hypot-define18.2%
*-commutative18.2%
exp-prod18.2%
fma-define18.2%
hypot-define27.5%
*-commutative27.5%
Simplified27.5%
Taylor expanded in y.im around 0 45.7%
add-sqr-sqrt13.9%
pow213.9%
*-commutative13.9%
Applied egg-rr13.9%
Taylor expanded in y.re around 0 64.0%
if -1.8000000000000001e173 < y.im < -2.0999999999999999e-11 or 7.7999999999999994e-64 < y.im Initial program 44.6%
fma-neg44.6%
hypot-define44.6%
distribute-rgt-neg-out44.6%
fma-define44.6%
hypot-define78.6%
*-commutative78.6%
Simplified78.6%
Taylor expanded in y.re around 0 47.0%
unpow247.0%
unpow247.0%
hypot-undefine82.6%
Simplified82.6%
if -2.0999999999999999e-11 < y.im < 7.7999999999999994e-64Initial program 52.2%
fma-neg52.2%
hypot-define52.2%
distribute-rgt-neg-out52.2%
fma-define52.2%
hypot-define90.6%
*-commutative90.6%
Simplified90.6%
Taylor expanded in y.im around 0 57.3%
unpow257.3%
unpow257.3%
hypot-undefine90.6%
Simplified90.6%
Taylor expanded in y.im around 0 65.9%
unpow265.9%
unpow265.9%
hypot-undefine90.6%
Simplified90.6%
Final simplification84.4%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re))))
(if (<= y.im -3.1e+172)
(/ t_0 (exp (* y.im (atan2 x.im x.re))))
(if (or (<= y.im -8e-187) (not (<= y.im 2.15e-175)))
(*
(exp (fma (log (hypot x.re x.im)) y.re (* (atan2 x.im x.re) (- y.im))))
(sin (* y.im (log (hypot x.im x.re)))))
(* (sin t_0) (pow (hypot x.re x.im) 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 (y_46_im <= -3.1e+172) {
tmp = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re)));
} else if ((y_46_im <= -8e-187) || !(y_46_im <= 2.15e-175)) {
tmp = exp(fma(log(hypot(x_46_re, x_46_im)), y_46_re, (atan2(x_46_im, x_46_re) * -y_46_im))) * sin((y_46_im * log(hypot(x_46_im, x_46_re))));
} else {
tmp = sin(t_0) * pow(hypot(x_46_re, x_46_im), 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 (y_46_im <= -3.1e+172) tmp = Float64(t_0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))); elseif ((y_46_im <= -8e-187) || !(y_46_im <= 2.15e-175)) tmp = Float64(exp(fma(log(hypot(x_46_re, x_46_im)), y_46_re, Float64(atan(x_46_im, x_46_re) * Float64(-y_46_im)))) * sin(Float64(y_46_im * log(hypot(x_46_im, x_46_re))))); else tmp = Float64(sin(t_0) * (hypot(x_46_re, x_46_im) ^ 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[y$46$im, -3.1e+172], N[(t$95$0 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[y$46$im, -8e-187], N[Not[LessEqual[y$46$im, 2.15e-175]], $MachinePrecision]], N[(N[Exp[N[(N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision] * y$46$re + N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * (-y$46$im)), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Sin[t$95$0], $MachinePrecision] * N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], 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}\;y.im \leq -3.1 \cdot 10^{+172}:\\
\;\;\;\;\frac{t\_0}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.im \leq -8 \cdot 10^{-187} \lor \neg \left(y.im \leq 2.15 \cdot 10^{-175}\right):\\
\;\;\;\;e^{\mathsf{fma}\left(\log \left(\mathsf{hypot}\left(x.re, x.im\right)\right), y.re, \tan^{-1}_* \frac{x.im}{x.re} \cdot \left(-y.im\right)\right)} \cdot \sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\sin t\_0 \cdot {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}\\
\end{array}
\end{array}
if y.im < -3.09999999999999988e172Initial program 18.2%
exp-diff18.2%
exp-to-pow18.2%
hypot-define18.2%
*-commutative18.2%
exp-prod18.2%
fma-define18.2%
hypot-define27.5%
*-commutative27.5%
Simplified27.5%
Taylor expanded in y.im around 0 45.7%
add-sqr-sqrt13.9%
pow213.9%
*-commutative13.9%
Applied egg-rr13.9%
Taylor expanded in y.re around 0 64.0%
if -3.09999999999999988e172 < y.im < -8.0000000000000001e-187 or 2.14999999999999999e-175 < y.im Initial program 46.0%
fma-neg46.0%
hypot-define46.0%
distribute-rgt-neg-out46.0%
fma-define46.0%
hypot-define81.9%
*-commutative81.9%
Simplified81.9%
Taylor expanded in y.re around 0 45.6%
unpow245.6%
unpow245.6%
hypot-undefine80.8%
Simplified80.8%
if -8.0000000000000001e-187 < y.im < 2.14999999999999999e-175Initial program 55.6%
exp-diff55.6%
exp-to-pow55.6%
hypot-define55.6%
*-commutative55.6%
exp-prod55.6%
fma-define55.6%
hypot-define92.1%
*-commutative92.1%
Simplified92.1%
fma-undefine92.1%
hypot-define55.6%
*-commutative55.6%
expm1-log1p-u55.6%
*-commutative55.6%
fma-define55.6%
hypot-define92.1%
*-commutative92.1%
Applied egg-rr92.1%
Taylor expanded in y.im around 0 55.4%
+-commutative55.4%
unpow255.4%
unpow255.4%
hypot-undefine77.9%
Simplified77.9%
Final simplification78.8%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (log (hypot x.re x.im)))
(t_1
(*
(exp (fma t_0 y.re (* (atan2 x.im x.re) (- y.im))))
(sin (* y.re (atan2 x.im x.re)))))
(t_2 (sin (* y.im t_0))))
(if (<= y.re -2.3e-241)
t_1
(if (<= y.re 6.7e-31)
(/ t_2 (pow (exp y.im) (atan2 x.im x.re)))
(if (<= y.re 2.5e+68)
t_1
(*
t_2
(exp
(-
(* y.re (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
(* y.im (atan2 x.im x.re))))))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = log(hypot(x_46_re, x_46_im));
double t_1 = exp(fma(t_0, y_46_re, (atan2(x_46_im, x_46_re) * -y_46_im))) * sin((y_46_re * atan2(x_46_im, x_46_re)));
double t_2 = sin((y_46_im * t_0));
double tmp;
if (y_46_re <= -2.3e-241) {
tmp = t_1;
} else if (y_46_re <= 6.7e-31) {
tmp = t_2 / pow(exp(y_46_im), atan2(x_46_im, x_46_re));
} else if (y_46_re <= 2.5e+68) {
tmp = t_1;
} else {
tmp = t_2 * exp(((y_46_re * log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - (y_46_im * atan2(x_46_im, x_46_re))));
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = log(hypot(x_46_re, x_46_im)) t_1 = Float64(exp(fma(t_0, y_46_re, Float64(atan(x_46_im, x_46_re) * Float64(-y_46_im)))) * sin(Float64(y_46_re * atan(x_46_im, x_46_re)))) t_2 = sin(Float64(y_46_im * t_0)) tmp = 0.0 if (y_46_re <= -2.3e-241) tmp = t_1; elseif (y_46_re <= 6.7e-31) tmp = Float64(t_2 / (exp(y_46_im) ^ atan(x_46_im, x_46_re))); elseif (y_46_re <= 2.5e+68) tmp = t_1; else tmp = Float64(t_2 * exp(Float64(Float64(y_46_re * log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))) - Float64(y_46_im * atan(x_46_im, 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[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$1 = N[(N[Exp[N[(t$95$0 * y$46$re + N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * (-y$46$im)), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Sin[N[(y$46$im * t$95$0), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[y$46$re, -2.3e-241], t$95$1, If[LessEqual[y$46$re, 6.7e-31], N[(t$95$2 / N[Power[N[Exp[y$46$im], $MachinePrecision], N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 2.5e+68], t$95$1, N[(t$95$2 * N[Exp[N[(N[(y$46$re * N[Log[N[Sqrt[N[(N[(x$46$re * x$46$re), $MachinePrecision] + N[(x$46$im * x$46$im), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)\\
t_1 := e^{\mathsf{fma}\left(t\_0, y.re, \tan^{-1}_* \frac{x.im}{x.re} \cdot \left(-y.im\right)\right)} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\
t_2 := \sin \left(y.im \cdot t\_0\right)\\
\mathbf{if}\;y.re \leq -2.3 \cdot 10^{-241}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y.re \leq 6.7 \cdot 10^{-31}:\\
\;\;\;\;\frac{t\_2}{{\left(e^{y.im}\right)}^{\tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.re \leq 2.5 \cdot 10^{+68}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2 \cdot e^{y.re \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) - y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}\\
\end{array}
\end{array}
if y.re < -2.2999999999999999e-241 or 6.70000000000000003e-31 < y.re < 2.5000000000000002e68Initial program 45.8%
fma-neg45.8%
hypot-define45.8%
distribute-rgt-neg-out45.8%
fma-define45.8%
hypot-define78.8%
*-commutative78.8%
Simplified78.8%
Taylor expanded in y.im around 0 77.1%
if -2.2999999999999999e-241 < y.re < 6.70000000000000003e-31Initial program 49.0%
exp-diff49.0%
exp-to-pow49.0%
hypot-define49.0%
*-commutative49.0%
exp-prod49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Simplified84.9%
fma-undefine84.9%
hypot-define49.0%
*-commutative49.0%
expm1-log1p-u49.0%
*-commutative49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Applied egg-rr84.9%
Taylor expanded in y.re around 0 43.0%
+-commutative43.0%
unpow243.0%
unpow243.0%
hypot-undefine72.9%
exp-prod72.7%
Simplified72.7%
if 2.5000000000000002e68 < y.re Initial program 38.6%
add-sqr-sqrt25.0%
pow225.0%
hypot-define47.8%
Applied egg-rr47.8%
Taylor expanded in y.re around 0 45.5%
+-commutative45.5%
unpow245.5%
unpow245.5%
hypot-undefine77.3%
Simplified77.3%
Final simplification75.8%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (log (hypot x.re x.im))))
(if (or (<= y.re -2.2e-241) (not (<= y.re 2.25e-28)))
(*
(exp (fma t_0 y.re (* (atan2 x.im x.re) (- y.im))))
(sin (* y.re (atan2 x.im x.re))))
(/ (sin (* y.im t_0)) (pow (exp y.im) (atan2 x.im x.re))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = log(hypot(x_46_re, x_46_im));
double tmp;
if ((y_46_re <= -2.2e-241) || !(y_46_re <= 2.25e-28)) {
tmp = exp(fma(t_0, y_46_re, (atan2(x_46_im, x_46_re) * -y_46_im))) * sin((y_46_re * atan2(x_46_im, x_46_re)));
} else {
tmp = sin((y_46_im * t_0)) / pow(exp(y_46_im), atan2(x_46_im, x_46_re));
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = log(hypot(x_46_re, x_46_im)) tmp = 0.0 if ((y_46_re <= -2.2e-241) || !(y_46_re <= 2.25e-28)) tmp = Float64(exp(fma(t_0, y_46_re, Float64(atan(x_46_im, x_46_re) * Float64(-y_46_im)))) * sin(Float64(y_46_re * atan(x_46_im, x_46_re)))); else tmp = Float64(sin(Float64(y_46_im * t_0)) / (exp(y_46_im) ^ atan(x_46_im, 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[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]}, If[Or[LessEqual[y$46$re, -2.2e-241], N[Not[LessEqual[y$46$re, 2.25e-28]], $MachinePrecision]], N[(N[Exp[N[(t$95$0 * y$46$re + N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * (-y$46$im)), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Sin[N[(y$46$im * t$95$0), $MachinePrecision]], $MachinePrecision] / N[Power[N[Exp[y$46$im], $MachinePrecision], N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)\\
\mathbf{if}\;y.re \leq -2.2 \cdot 10^{-241} \lor \neg \left(y.re \leq 2.25 \cdot 10^{-28}\right):\\
\;\;\;\;e^{\mathsf{fma}\left(t\_0, y.re, \tan^{-1}_* \frac{x.im}{x.re} \cdot \left(-y.im\right)\right)} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{\sin \left(y.im \cdot t\_0\right)}{{\left(e^{y.im}\right)}^{\tan^{-1}_* \frac{x.im}{x.re}}}\\
\end{array}
\end{array}
if y.re < -2.1999999999999999e-241 or 2.2499999999999999e-28 < y.re Initial program 44.0%
fma-neg44.0%
hypot-define44.0%
distribute-rgt-neg-out44.0%
fma-define44.0%
hypot-define76.8%
*-commutative76.8%
Simplified76.8%
Taylor expanded in y.im around 0 72.7%
if -2.1999999999999999e-241 < y.re < 2.2499999999999999e-28Initial program 49.0%
exp-diff49.0%
exp-to-pow49.0%
hypot-define49.0%
*-commutative49.0%
exp-prod49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Simplified84.9%
fma-undefine84.9%
hypot-define49.0%
*-commutative49.0%
expm1-log1p-u49.0%
*-commutative49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Applied egg-rr84.9%
Taylor expanded in y.re around 0 43.0%
+-commutative43.0%
unpow243.0%
unpow243.0%
hypot-undefine72.9%
exp-prod72.7%
Simplified72.7%
Final simplification72.7%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re)))
(t_1 (pow (exp y.im) (atan2 x.im x.re)))
(t_2 (pow (hypot x.re x.im) y.re))
(t_3 (sin t_0)))
(if (<= y.re -0.00185)
(* t_2 (sqrt (pow t_3 2.0)))
(if (<= y.re -2.3e-241)
(* t_3 (/ t_2 t_1))
(if (<= y.re 6.7e-31)
(/ (sin (* y.im (log (hypot x.re x.im)))) t_1)
(if (<= y.re 5e+19)
(/ t_0 (exp (* y.im (atan2 x.im x.re))))
(if (<= y.re 9.2e+88)
(*
t_2
(*
y.re
(+
(atan2 x.im x.re)
(*
-0.16666666666666666
(* (pow y.re 2.0) (pow (atan2 x.im x.re) 3.0))))))
(* t_2 (log (exp t_3))))))))))
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 = pow(exp(y_46_im), atan2(x_46_im, x_46_re));
double t_2 = pow(hypot(x_46_re, x_46_im), y_46_re);
double t_3 = sin(t_0);
double tmp;
if (y_46_re <= -0.00185) {
tmp = t_2 * sqrt(pow(t_3, 2.0));
} else if (y_46_re <= -2.3e-241) {
tmp = t_3 * (t_2 / t_1);
} else if (y_46_re <= 6.7e-31) {
tmp = sin((y_46_im * log(hypot(x_46_re, x_46_im)))) / t_1;
} else if (y_46_re <= 5e+19) {
tmp = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 9.2e+88) {
tmp = t_2 * (y_46_re * (atan2(x_46_im, x_46_re) + (-0.16666666666666666 * (pow(y_46_re, 2.0) * pow(atan2(x_46_im, x_46_re), 3.0)))));
} else {
tmp = t_2 * log(exp(t_3));
}
return tmp;
}
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 = Math.pow(Math.exp(y_46_im), Math.atan2(x_46_im, x_46_re));
double t_2 = Math.pow(Math.hypot(x_46_re, x_46_im), y_46_re);
double t_3 = Math.sin(t_0);
double tmp;
if (y_46_re <= -0.00185) {
tmp = t_2 * Math.sqrt(Math.pow(t_3, 2.0));
} else if (y_46_re <= -2.3e-241) {
tmp = t_3 * (t_2 / t_1);
} else if (y_46_re <= 6.7e-31) {
tmp = Math.sin((y_46_im * Math.log(Math.hypot(x_46_re, x_46_im)))) / t_1;
} else if (y_46_re <= 5e+19) {
tmp = t_0 / Math.exp((y_46_im * Math.atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 9.2e+88) {
tmp = t_2 * (y_46_re * (Math.atan2(x_46_im, x_46_re) + (-0.16666666666666666 * (Math.pow(y_46_re, 2.0) * Math.pow(Math.atan2(x_46_im, x_46_re), 3.0)))));
} else {
tmp = t_2 * Math.log(Math.exp(t_3));
}
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 = math.pow(math.exp(y_46_im), math.atan2(x_46_im, x_46_re)) t_2 = math.pow(math.hypot(x_46_re, x_46_im), y_46_re) t_3 = math.sin(t_0) tmp = 0 if y_46_re <= -0.00185: tmp = t_2 * math.sqrt(math.pow(t_3, 2.0)) elif y_46_re <= -2.3e-241: tmp = t_3 * (t_2 / t_1) elif y_46_re <= 6.7e-31: tmp = math.sin((y_46_im * math.log(math.hypot(x_46_re, x_46_im)))) / t_1 elif y_46_re <= 5e+19: tmp = t_0 / math.exp((y_46_im * math.atan2(x_46_im, x_46_re))) elif y_46_re <= 9.2e+88: tmp = t_2 * (y_46_re * (math.atan2(x_46_im, x_46_re) + (-0.16666666666666666 * (math.pow(y_46_re, 2.0) * math.pow(math.atan2(x_46_im, x_46_re), 3.0))))) else: tmp = t_2 * math.log(math.exp(t_3)) 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 = exp(y_46_im) ^ atan(x_46_im, x_46_re) t_2 = hypot(x_46_re, x_46_im) ^ y_46_re t_3 = sin(t_0) tmp = 0.0 if (y_46_re <= -0.00185) tmp = Float64(t_2 * sqrt((t_3 ^ 2.0))); elseif (y_46_re <= -2.3e-241) tmp = Float64(t_3 * Float64(t_2 / t_1)); elseif (y_46_re <= 6.7e-31) tmp = Float64(sin(Float64(y_46_im * log(hypot(x_46_re, x_46_im)))) / t_1); elseif (y_46_re <= 5e+19) tmp = Float64(t_0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))); elseif (y_46_re <= 9.2e+88) tmp = Float64(t_2 * Float64(y_46_re * Float64(atan(x_46_im, x_46_re) + Float64(-0.16666666666666666 * Float64((y_46_re ^ 2.0) * (atan(x_46_im, x_46_re) ^ 3.0)))))); else tmp = Float64(t_2 * log(exp(t_3))); 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 = exp(y_46_im) ^ atan2(x_46_im, x_46_re); t_2 = hypot(x_46_re, x_46_im) ^ y_46_re; t_3 = sin(t_0); tmp = 0.0; if (y_46_re <= -0.00185) tmp = t_2 * sqrt((t_3 ^ 2.0)); elseif (y_46_re <= -2.3e-241) tmp = t_3 * (t_2 / t_1); elseif (y_46_re <= 6.7e-31) tmp = sin((y_46_im * log(hypot(x_46_re, x_46_im)))) / t_1; elseif (y_46_re <= 5e+19) tmp = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re))); elseif (y_46_re <= 9.2e+88) tmp = t_2 * (y_46_re * (atan2(x_46_im, x_46_re) + (-0.16666666666666666 * ((y_46_re ^ 2.0) * (atan2(x_46_im, x_46_re) ^ 3.0))))); else tmp = t_2 * log(exp(t_3)); 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[Power[N[Exp[y$46$im], $MachinePrecision], N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]}, Block[{t$95$3 = N[Sin[t$95$0], $MachinePrecision]}, If[LessEqual[y$46$re, -0.00185], N[(t$95$2 * N[Sqrt[N[Power[t$95$3, 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, -2.3e-241], N[(t$95$3 * N[(t$95$2 / t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 6.7e-31], N[(N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / t$95$1), $MachinePrecision], If[LessEqual[y$46$re, 5e+19], N[(t$95$0 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 9.2e+88], N[(t$95$2 * N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(-0.16666666666666666 * N[(N[Power[y$46$re, 2.0], $MachinePrecision] * N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$2 * N[Log[N[Exp[t$95$3], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := {\left(e^{y.im}\right)}^{\tan^{-1}_* \frac{x.im}{x.re}}\\
t_2 := {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}\\
t_3 := \sin t\_0\\
\mathbf{if}\;y.re \leq -0.00185:\\
\;\;\;\;t\_2 \cdot \sqrt{{t\_3}^{2}}\\
\mathbf{elif}\;y.re \leq -2.3 \cdot 10^{-241}:\\
\;\;\;\;t\_3 \cdot \frac{t\_2}{t\_1}\\
\mathbf{elif}\;y.re \leq 6.7 \cdot 10^{-31}:\\
\;\;\;\;\frac{\sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)\right)}{t\_1}\\
\mathbf{elif}\;y.re \leq 5 \cdot 10^{+19}:\\
\;\;\;\;\frac{t\_0}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.re \leq 9.2 \cdot 10^{+88}:\\
\;\;\;\;t\_2 \cdot \left(y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} + -0.16666666666666666 \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2 \cdot \log \left(e^{t\_3}\right)\\
\end{array}
\end{array}
if y.re < -0.0018500000000000001Initial program 51.4%
exp-diff44.4%
exp-to-pow44.4%
hypot-define44.4%
*-commutative44.4%
exp-prod43.1%
fma-define43.1%
hypot-define68.1%
*-commutative68.1%
Simplified68.1%
fma-undefine68.1%
hypot-define43.1%
*-commutative43.1%
expm1-log1p-u43.1%
*-commutative43.1%
fma-define43.1%
hypot-define68.1%
*-commutative68.1%
Applied egg-rr68.1%
Taylor expanded in y.im around 0 75.2%
+-commutative75.2%
unpow275.2%
unpow275.2%
hypot-undefine75.2%
Simplified75.2%
add-sqr-sqrt41.8%
sqrt-unprod80.7%
pow280.7%
*-commutative80.7%
Applied egg-rr80.7%
if -0.0018500000000000001 < y.re < -2.2999999999999999e-241Initial program 38.2%
exp-diff38.2%
exp-to-pow38.2%
hypot-define38.2%
*-commutative38.2%
exp-prod37.4%
fma-define37.4%
hypot-define79.7%
*-commutative79.7%
Simplified79.7%
Taylor expanded in y.im around 0 72.9%
if -2.2999999999999999e-241 < y.re < 6.70000000000000003e-31Initial program 49.0%
exp-diff49.0%
exp-to-pow49.0%
hypot-define49.0%
*-commutative49.0%
exp-prod49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Simplified84.9%
fma-undefine84.9%
hypot-define49.0%
*-commutative49.0%
expm1-log1p-u49.0%
*-commutative49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Applied egg-rr84.9%
Taylor expanded in y.re around 0 43.0%
+-commutative43.0%
unpow243.0%
unpow243.0%
hypot-undefine72.9%
exp-prod72.7%
Simplified72.7%
if 6.70000000000000003e-31 < y.re < 5e19Initial program 45.3%
exp-diff45.3%
exp-to-pow45.3%
hypot-define45.3%
*-commutative45.3%
exp-prod45.3%
fma-define45.3%
hypot-define63.5%
*-commutative63.5%
Simplified63.5%
Taylor expanded in y.im around 0 63.5%
add-sqr-sqrt36.4%
pow236.4%
*-commutative36.4%
Applied egg-rr36.4%
Taylor expanded in y.re around 0 88.8%
if 5e19 < y.re < 9.2000000000000007e88Initial program 36.4%
exp-diff36.4%
exp-to-pow36.4%
hypot-define36.4%
*-commutative36.4%
exp-prod36.4%
fma-define36.4%
hypot-define45.5%
*-commutative45.5%
Simplified45.5%
fma-undefine45.5%
hypot-define36.4%
*-commutative36.4%
expm1-log1p-u36.4%
*-commutative36.4%
fma-define36.4%
hypot-define45.5%
*-commutative45.5%
Applied egg-rr45.5%
Taylor expanded in y.im around 0 45.6%
+-commutative45.6%
unpow245.6%
unpow245.6%
hypot-undefine45.6%
Simplified45.6%
Taylor expanded in y.re around 0 72.9%
if 9.2000000000000007e88 < y.re Initial program 39.0%
exp-diff34.1%
exp-to-pow34.1%
hypot-define34.1%
*-commutative34.1%
exp-prod34.1%
fma-define34.1%
hypot-define58.5%
*-commutative58.5%
Simplified58.5%
fma-undefine58.5%
hypot-define34.1%
*-commutative34.1%
expm1-log1p-u34.1%
*-commutative34.1%
fma-define34.1%
hypot-define58.5%
*-commutative58.5%
Applied egg-rr58.5%
Taylor expanded in y.im around 0 61.1%
+-commutative61.1%
unpow261.1%
unpow261.1%
hypot-undefine61.1%
Simplified61.1%
add-log-exp61.1%
*-commutative61.1%
Applied egg-rr61.1%
Final simplification73.8%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re)))
(t_1 (pow (exp y.im) (atan2 x.im x.re)))
(t_2 (pow (hypot x.re x.im) y.re))
(t_3 (sin t_0)))
(if (<= y.re -0.00185)
(* t_2 (sqrt (pow t_3 2.0)))
(if (<= y.re -2.3e-241)
(* t_0 (/ t_2 t_1))
(if (<= y.re 1.2e-29)
(/ (sin (* y.im (log (hypot x.re x.im)))) t_1)
(if (<= y.re 2.1e+18)
(/ t_0 (exp (* y.im (atan2 x.im x.re))))
(if (<= y.re 1e+87)
(*
t_2
(*
y.re
(+
(atan2 x.im x.re)
(*
-0.16666666666666666
(* (pow y.re 2.0) (pow (atan2 x.im x.re) 3.0))))))
(* t_2 (log (exp t_3))))))))))
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 = pow(exp(y_46_im), atan2(x_46_im, x_46_re));
double t_2 = pow(hypot(x_46_re, x_46_im), y_46_re);
double t_3 = sin(t_0);
double tmp;
if (y_46_re <= -0.00185) {
tmp = t_2 * sqrt(pow(t_3, 2.0));
} else if (y_46_re <= -2.3e-241) {
tmp = t_0 * (t_2 / t_1);
} else if (y_46_re <= 1.2e-29) {
tmp = sin((y_46_im * log(hypot(x_46_re, x_46_im)))) / t_1;
} else if (y_46_re <= 2.1e+18) {
tmp = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 1e+87) {
tmp = t_2 * (y_46_re * (atan2(x_46_im, x_46_re) + (-0.16666666666666666 * (pow(y_46_re, 2.0) * pow(atan2(x_46_im, x_46_re), 3.0)))));
} else {
tmp = t_2 * log(exp(t_3));
}
return tmp;
}
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 = Math.pow(Math.exp(y_46_im), Math.atan2(x_46_im, x_46_re));
double t_2 = Math.pow(Math.hypot(x_46_re, x_46_im), y_46_re);
double t_3 = Math.sin(t_0);
double tmp;
if (y_46_re <= -0.00185) {
tmp = t_2 * Math.sqrt(Math.pow(t_3, 2.0));
} else if (y_46_re <= -2.3e-241) {
tmp = t_0 * (t_2 / t_1);
} else if (y_46_re <= 1.2e-29) {
tmp = Math.sin((y_46_im * Math.log(Math.hypot(x_46_re, x_46_im)))) / t_1;
} else if (y_46_re <= 2.1e+18) {
tmp = t_0 / Math.exp((y_46_im * Math.atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 1e+87) {
tmp = t_2 * (y_46_re * (Math.atan2(x_46_im, x_46_re) + (-0.16666666666666666 * (Math.pow(y_46_re, 2.0) * Math.pow(Math.atan2(x_46_im, x_46_re), 3.0)))));
} else {
tmp = t_2 * Math.log(Math.exp(t_3));
}
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 = math.pow(math.exp(y_46_im), math.atan2(x_46_im, x_46_re)) t_2 = math.pow(math.hypot(x_46_re, x_46_im), y_46_re) t_3 = math.sin(t_0) tmp = 0 if y_46_re <= -0.00185: tmp = t_2 * math.sqrt(math.pow(t_3, 2.0)) elif y_46_re <= -2.3e-241: tmp = t_0 * (t_2 / t_1) elif y_46_re <= 1.2e-29: tmp = math.sin((y_46_im * math.log(math.hypot(x_46_re, x_46_im)))) / t_1 elif y_46_re <= 2.1e+18: tmp = t_0 / math.exp((y_46_im * math.atan2(x_46_im, x_46_re))) elif y_46_re <= 1e+87: tmp = t_2 * (y_46_re * (math.atan2(x_46_im, x_46_re) + (-0.16666666666666666 * (math.pow(y_46_re, 2.0) * math.pow(math.atan2(x_46_im, x_46_re), 3.0))))) else: tmp = t_2 * math.log(math.exp(t_3)) 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 = exp(y_46_im) ^ atan(x_46_im, x_46_re) t_2 = hypot(x_46_re, x_46_im) ^ y_46_re t_3 = sin(t_0) tmp = 0.0 if (y_46_re <= -0.00185) tmp = Float64(t_2 * sqrt((t_3 ^ 2.0))); elseif (y_46_re <= -2.3e-241) tmp = Float64(t_0 * Float64(t_2 / t_1)); elseif (y_46_re <= 1.2e-29) tmp = Float64(sin(Float64(y_46_im * log(hypot(x_46_re, x_46_im)))) / t_1); elseif (y_46_re <= 2.1e+18) tmp = Float64(t_0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))); elseif (y_46_re <= 1e+87) tmp = Float64(t_2 * Float64(y_46_re * Float64(atan(x_46_im, x_46_re) + Float64(-0.16666666666666666 * Float64((y_46_re ^ 2.0) * (atan(x_46_im, x_46_re) ^ 3.0)))))); else tmp = Float64(t_2 * log(exp(t_3))); 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 = exp(y_46_im) ^ atan2(x_46_im, x_46_re); t_2 = hypot(x_46_re, x_46_im) ^ y_46_re; t_3 = sin(t_0); tmp = 0.0; if (y_46_re <= -0.00185) tmp = t_2 * sqrt((t_3 ^ 2.0)); elseif (y_46_re <= -2.3e-241) tmp = t_0 * (t_2 / t_1); elseif (y_46_re <= 1.2e-29) tmp = sin((y_46_im * log(hypot(x_46_re, x_46_im)))) / t_1; elseif (y_46_re <= 2.1e+18) tmp = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re))); elseif (y_46_re <= 1e+87) tmp = t_2 * (y_46_re * (atan2(x_46_im, x_46_re) + (-0.16666666666666666 * ((y_46_re ^ 2.0) * (atan2(x_46_im, x_46_re) ^ 3.0))))); else tmp = t_2 * log(exp(t_3)); 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[Power[N[Exp[y$46$im], $MachinePrecision], N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]}, Block[{t$95$3 = N[Sin[t$95$0], $MachinePrecision]}, If[LessEqual[y$46$re, -0.00185], N[(t$95$2 * N[Sqrt[N[Power[t$95$3, 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, -2.3e-241], N[(t$95$0 * N[(t$95$2 / t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 1.2e-29], N[(N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / t$95$1), $MachinePrecision], If[LessEqual[y$46$re, 2.1e+18], N[(t$95$0 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 1e+87], N[(t$95$2 * N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(-0.16666666666666666 * N[(N[Power[y$46$re, 2.0], $MachinePrecision] * N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$2 * N[Log[N[Exp[t$95$3], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := {\left(e^{y.im}\right)}^{\tan^{-1}_* \frac{x.im}{x.re}}\\
t_2 := {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}\\
t_3 := \sin t\_0\\
\mathbf{if}\;y.re \leq -0.00185:\\
\;\;\;\;t\_2 \cdot \sqrt{{t\_3}^{2}}\\
\mathbf{elif}\;y.re \leq -2.3 \cdot 10^{-241}:\\
\;\;\;\;t\_0 \cdot \frac{t\_2}{t\_1}\\
\mathbf{elif}\;y.re \leq 1.2 \cdot 10^{-29}:\\
\;\;\;\;\frac{\sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)\right)}{t\_1}\\
\mathbf{elif}\;y.re \leq 2.1 \cdot 10^{+18}:\\
\;\;\;\;\frac{t\_0}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.re \leq 10^{+87}:\\
\;\;\;\;t\_2 \cdot \left(y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} + -0.16666666666666666 \cdot \left({y.re}^{2} \cdot {\tan^{-1}_* \frac{x.im}{x.re}}^{3}\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2 \cdot \log \left(e^{t\_3}\right)\\
\end{array}
\end{array}
if y.re < -0.0018500000000000001Initial program 51.4%
exp-diff44.4%
exp-to-pow44.4%
hypot-define44.4%
*-commutative44.4%
exp-prod43.1%
fma-define43.1%
hypot-define68.1%
*-commutative68.1%
Simplified68.1%
fma-undefine68.1%
hypot-define43.1%
*-commutative43.1%
expm1-log1p-u43.1%
*-commutative43.1%
fma-define43.1%
hypot-define68.1%
*-commutative68.1%
Applied egg-rr68.1%
Taylor expanded in y.im around 0 75.2%
+-commutative75.2%
unpow275.2%
unpow275.2%
hypot-undefine75.2%
Simplified75.2%
add-sqr-sqrt41.8%
sqrt-unprod80.7%
pow280.7%
*-commutative80.7%
Applied egg-rr80.7%
if -0.0018500000000000001 < y.re < -2.2999999999999999e-241Initial program 38.2%
exp-diff38.2%
exp-to-pow38.2%
hypot-define38.2%
*-commutative38.2%
exp-prod37.4%
fma-define37.4%
hypot-define79.7%
*-commutative79.7%
Simplified79.7%
Taylor expanded in y.im around 0 72.9%
Taylor expanded in y.re around 0 72.2%
if -2.2999999999999999e-241 < y.re < 1.19999999999999996e-29Initial program 49.0%
exp-diff49.0%
exp-to-pow49.0%
hypot-define49.0%
*-commutative49.0%
exp-prod49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Simplified84.9%
fma-undefine84.9%
hypot-define49.0%
*-commutative49.0%
expm1-log1p-u49.0%
*-commutative49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Applied egg-rr84.9%
Taylor expanded in y.re around 0 43.0%
+-commutative43.0%
unpow243.0%
unpow243.0%
hypot-undefine72.9%
exp-prod72.7%
Simplified72.7%
if 1.19999999999999996e-29 < y.re < 2.1e18Initial program 45.3%
exp-diff45.3%
exp-to-pow45.3%
hypot-define45.3%
*-commutative45.3%
exp-prod45.3%
fma-define45.3%
hypot-define63.5%
*-commutative63.5%
Simplified63.5%
Taylor expanded in y.im around 0 63.5%
add-sqr-sqrt36.4%
pow236.4%
*-commutative36.4%
Applied egg-rr36.4%
Taylor expanded in y.re around 0 88.8%
if 2.1e18 < y.re < 9.9999999999999996e86Initial program 36.4%
exp-diff36.4%
exp-to-pow36.4%
hypot-define36.4%
*-commutative36.4%
exp-prod36.4%
fma-define36.4%
hypot-define45.5%
*-commutative45.5%
Simplified45.5%
fma-undefine45.5%
hypot-define36.4%
*-commutative36.4%
expm1-log1p-u36.4%
*-commutative36.4%
fma-define36.4%
hypot-define45.5%
*-commutative45.5%
Applied egg-rr45.5%
Taylor expanded in y.im around 0 45.6%
+-commutative45.6%
unpow245.6%
unpow245.6%
hypot-undefine45.6%
Simplified45.6%
Taylor expanded in y.re around 0 72.9%
if 9.9999999999999996e86 < y.re Initial program 39.0%
exp-diff34.1%
exp-to-pow34.1%
hypot-define34.1%
*-commutative34.1%
exp-prod34.1%
fma-define34.1%
hypot-define58.5%
*-commutative58.5%
Simplified58.5%
fma-undefine58.5%
hypot-define34.1%
*-commutative34.1%
expm1-log1p-u34.1%
*-commutative34.1%
fma-define34.1%
hypot-define58.5%
*-commutative58.5%
Applied egg-rr58.5%
Taylor expanded in y.im around 0 61.1%
+-commutative61.1%
unpow261.1%
unpow261.1%
hypot-undefine61.1%
Simplified61.1%
add-log-exp61.1%
*-commutative61.1%
Applied egg-rr61.1%
Final simplification73.7%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re)))
(t_1 (pow (exp y.im) (atan2 x.im x.re)))
(t_2 (pow (hypot x.re x.im) y.re))
(t_3 (sin t_0)))
(if (<= y.re -0.00185)
(* t_2 (sqrt (pow t_3 2.0)))
(if (<= y.re -2.3e-241)
(* t_0 (/ t_2 t_1))
(if (<= y.re 6.7e-31)
(/ (sin (* y.im (log (hypot x.re x.im)))) t_1)
(if (<= y.re 3.9e+18)
(/ t_0 (exp (* y.im (atan2 x.im x.re))))
(* t_2 (pow (cbrt t_3) 3.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);
double t_1 = pow(exp(y_46_im), atan2(x_46_im, x_46_re));
double t_2 = pow(hypot(x_46_re, x_46_im), y_46_re);
double t_3 = sin(t_0);
double tmp;
if (y_46_re <= -0.00185) {
tmp = t_2 * sqrt(pow(t_3, 2.0));
} else if (y_46_re <= -2.3e-241) {
tmp = t_0 * (t_2 / t_1);
} else if (y_46_re <= 6.7e-31) {
tmp = sin((y_46_im * log(hypot(x_46_re, x_46_im)))) / t_1;
} else if (y_46_re <= 3.9e+18) {
tmp = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re)));
} else {
tmp = t_2 * pow(cbrt(t_3), 3.0);
}
return tmp;
}
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 = Math.pow(Math.exp(y_46_im), Math.atan2(x_46_im, x_46_re));
double t_2 = Math.pow(Math.hypot(x_46_re, x_46_im), y_46_re);
double t_3 = Math.sin(t_0);
double tmp;
if (y_46_re <= -0.00185) {
tmp = t_2 * Math.sqrt(Math.pow(t_3, 2.0));
} else if (y_46_re <= -2.3e-241) {
tmp = t_0 * (t_2 / t_1);
} else if (y_46_re <= 6.7e-31) {
tmp = Math.sin((y_46_im * Math.log(Math.hypot(x_46_re, x_46_im)))) / t_1;
} else if (y_46_re <= 3.9e+18) {
tmp = t_0 / Math.exp((y_46_im * Math.atan2(x_46_im, x_46_re)));
} else {
tmp = t_2 * Math.pow(Math.cbrt(t_3), 3.0);
}
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 = exp(y_46_im) ^ atan(x_46_im, x_46_re) t_2 = hypot(x_46_re, x_46_im) ^ y_46_re t_3 = sin(t_0) tmp = 0.0 if (y_46_re <= -0.00185) tmp = Float64(t_2 * sqrt((t_3 ^ 2.0))); elseif (y_46_re <= -2.3e-241) tmp = Float64(t_0 * Float64(t_2 / t_1)); elseif (y_46_re <= 6.7e-31) tmp = Float64(sin(Float64(y_46_im * log(hypot(x_46_re, x_46_im)))) / t_1); elseif (y_46_re <= 3.9e+18) tmp = Float64(t_0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))); else tmp = Float64(t_2 * (cbrt(t_3) ^ 3.0)); 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[Power[N[Exp[y$46$im], $MachinePrecision], N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]}, Block[{t$95$3 = N[Sin[t$95$0], $MachinePrecision]}, If[LessEqual[y$46$re, -0.00185], N[(t$95$2 * N[Sqrt[N[Power[t$95$3, 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, -2.3e-241], N[(t$95$0 * N[(t$95$2 / t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 6.7e-31], N[(N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / t$95$1), $MachinePrecision], If[LessEqual[y$46$re, 3.9e+18], N[(t$95$0 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(t$95$2 * N[Power[N[Power[t$95$3, 1/3], $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := {\left(e^{y.im}\right)}^{\tan^{-1}_* \frac{x.im}{x.re}}\\
t_2 := {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}\\
t_3 := \sin t\_0\\
\mathbf{if}\;y.re \leq -0.00185:\\
\;\;\;\;t\_2 \cdot \sqrt{{t\_3}^{2}}\\
\mathbf{elif}\;y.re \leq -2.3 \cdot 10^{-241}:\\
\;\;\;\;t\_0 \cdot \frac{t\_2}{t\_1}\\
\mathbf{elif}\;y.re \leq 6.7 \cdot 10^{-31}:\\
\;\;\;\;\frac{\sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)\right)}{t\_1}\\
\mathbf{elif}\;y.re \leq 3.9 \cdot 10^{+18}:\\
\;\;\;\;\frac{t\_0}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{else}:\\
\;\;\;\;t\_2 \cdot {\left(\sqrt[3]{t\_3}\right)}^{3}\\
\end{array}
\end{array}
if y.re < -0.0018500000000000001Initial program 51.4%
exp-diff44.4%
exp-to-pow44.4%
hypot-define44.4%
*-commutative44.4%
exp-prod43.1%
fma-define43.1%
hypot-define68.1%
*-commutative68.1%
Simplified68.1%
fma-undefine68.1%
hypot-define43.1%
*-commutative43.1%
expm1-log1p-u43.1%
*-commutative43.1%
fma-define43.1%
hypot-define68.1%
*-commutative68.1%
Applied egg-rr68.1%
Taylor expanded in y.im around 0 75.2%
+-commutative75.2%
unpow275.2%
unpow275.2%
hypot-undefine75.2%
Simplified75.2%
add-sqr-sqrt41.8%
sqrt-unprod80.7%
pow280.7%
*-commutative80.7%
Applied egg-rr80.7%
if -0.0018500000000000001 < y.re < -2.2999999999999999e-241Initial program 38.2%
exp-diff38.2%
exp-to-pow38.2%
hypot-define38.2%
*-commutative38.2%
exp-prod37.4%
fma-define37.4%
hypot-define79.7%
*-commutative79.7%
Simplified79.7%
Taylor expanded in y.im around 0 72.9%
Taylor expanded in y.re around 0 72.2%
if -2.2999999999999999e-241 < y.re < 6.70000000000000003e-31Initial program 49.0%
exp-diff49.0%
exp-to-pow49.0%
hypot-define49.0%
*-commutative49.0%
exp-prod49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Simplified84.9%
fma-undefine84.9%
hypot-define49.0%
*-commutative49.0%
expm1-log1p-u49.0%
*-commutative49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Applied egg-rr84.9%
Taylor expanded in y.re around 0 43.0%
+-commutative43.0%
unpow243.0%
unpow243.0%
hypot-undefine72.9%
exp-prod72.7%
Simplified72.7%
if 6.70000000000000003e-31 < y.re < 3.9e18Initial program 45.3%
exp-diff45.3%
exp-to-pow45.3%
hypot-define45.3%
*-commutative45.3%
exp-prod45.3%
fma-define45.3%
hypot-define63.5%
*-commutative63.5%
Simplified63.5%
Taylor expanded in y.im around 0 63.5%
add-sqr-sqrt36.4%
pow236.4%
*-commutative36.4%
Applied egg-rr36.4%
Taylor expanded in y.re around 0 88.8%
if 3.9e18 < y.re Initial program 38.5%
exp-diff34.6%
exp-to-pow34.6%
hypot-define34.6%
*-commutative34.6%
exp-prod34.6%
fma-define34.6%
hypot-define55.8%
*-commutative55.8%
Simplified55.8%
fma-undefine55.8%
hypot-define34.6%
*-commutative34.6%
expm1-log1p-u34.6%
*-commutative34.6%
fma-define34.6%
hypot-define55.8%
*-commutative55.8%
Applied egg-rr55.8%
Taylor expanded in y.im around 0 57.8%
+-commutative57.8%
unpow257.8%
unpow257.8%
hypot-undefine57.8%
Simplified57.8%
add-cube-cbrt57.8%
pow357.8%
*-commutative57.8%
Applied egg-rr57.8%
Final simplification72.5%
(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 (exp (* y.im (atan2 x.im x.re)))))
(t_2 (pow (hypot x.re x.im) y.re))
(t_3 (sin t_0)))
(if (<= y.re -0.00176)
(* t_2 (sqrt (pow t_3 2.0)))
(if (<= y.re -2.3e-241)
t_1
(if (<= y.re 6.7e-31)
(/
(sin (* y.im (log (hypot x.re x.im))))
(pow (exp y.im) (atan2 x.im x.re)))
(if (<= y.re 2.9e+18) t_1 (* t_2 (pow (cbrt t_3) 3.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);
double t_1 = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re)));
double t_2 = pow(hypot(x_46_re, x_46_im), y_46_re);
double t_3 = sin(t_0);
double tmp;
if (y_46_re <= -0.00176) {
tmp = t_2 * sqrt(pow(t_3, 2.0));
} else if (y_46_re <= -2.3e-241) {
tmp = t_1;
} else if (y_46_re <= 6.7e-31) {
tmp = sin((y_46_im * log(hypot(x_46_re, x_46_im)))) / pow(exp(y_46_im), atan2(x_46_im, x_46_re));
} else if (y_46_re <= 2.9e+18) {
tmp = t_1;
} else {
tmp = t_2 * pow(cbrt(t_3), 3.0);
}
return tmp;
}
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.exp((y_46_im * Math.atan2(x_46_im, x_46_re)));
double t_2 = Math.pow(Math.hypot(x_46_re, x_46_im), y_46_re);
double t_3 = Math.sin(t_0);
double tmp;
if (y_46_re <= -0.00176) {
tmp = t_2 * Math.sqrt(Math.pow(t_3, 2.0));
} else if (y_46_re <= -2.3e-241) {
tmp = t_1;
} else if (y_46_re <= 6.7e-31) {
tmp = Math.sin((y_46_im * Math.log(Math.hypot(x_46_re, x_46_im)))) / Math.pow(Math.exp(y_46_im), Math.atan2(x_46_im, x_46_re));
} else if (y_46_re <= 2.9e+18) {
tmp = t_1;
} else {
tmp = t_2 * Math.pow(Math.cbrt(t_3), 3.0);
}
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 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))) t_2 = hypot(x_46_re, x_46_im) ^ y_46_re t_3 = sin(t_0) tmp = 0.0 if (y_46_re <= -0.00176) tmp = Float64(t_2 * sqrt((t_3 ^ 2.0))); elseif (y_46_re <= -2.3e-241) tmp = t_1; elseif (y_46_re <= 6.7e-31) tmp = Float64(sin(Float64(y_46_im * log(hypot(x_46_re, x_46_im)))) / (exp(y_46_im) ^ atan(x_46_im, x_46_re))); elseif (y_46_re <= 2.9e+18) tmp = t_1; else tmp = Float64(t_2 * (cbrt(t_3) ^ 3.0)); 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[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]}, Block[{t$95$3 = N[Sin[t$95$0], $MachinePrecision]}, If[LessEqual[y$46$re, -0.00176], N[(t$95$2 * N[Sqrt[N[Power[t$95$3, 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, -2.3e-241], t$95$1, If[LessEqual[y$46$re, 6.7e-31], N[(N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Power[N[Exp[y$46$im], $MachinePrecision], N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 2.9e+18], t$95$1, N[(t$95$2 * N[Power[N[Power[t$95$3, 1/3], $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := \frac{t\_0}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
t_2 := {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}\\
t_3 := \sin t\_0\\
\mathbf{if}\;y.re \leq -0.00176:\\
\;\;\;\;t\_2 \cdot \sqrt{{t\_3}^{2}}\\
\mathbf{elif}\;y.re \leq -2.3 \cdot 10^{-241}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y.re \leq 6.7 \cdot 10^{-31}:\\
\;\;\;\;\frac{\sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)\right)}{{\left(e^{y.im}\right)}^{\tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.re \leq 2.9 \cdot 10^{+18}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2 \cdot {\left(\sqrt[3]{t\_3}\right)}^{3}\\
\end{array}
\end{array}
if y.re < -0.00176000000000000006Initial program 51.4%
exp-diff44.4%
exp-to-pow44.4%
hypot-define44.4%
*-commutative44.4%
exp-prod43.1%
fma-define43.1%
hypot-define68.1%
*-commutative68.1%
Simplified68.1%
fma-undefine68.1%
hypot-define43.1%
*-commutative43.1%
expm1-log1p-u43.1%
*-commutative43.1%
fma-define43.1%
hypot-define68.1%
*-commutative68.1%
Applied egg-rr68.1%
Taylor expanded in y.im around 0 75.2%
+-commutative75.2%
unpow275.2%
unpow275.2%
hypot-undefine75.2%
Simplified75.2%
add-sqr-sqrt41.8%
sqrt-unprod80.7%
pow280.7%
*-commutative80.7%
Applied egg-rr80.7%
if -0.00176000000000000006 < y.re < -2.2999999999999999e-241 or 6.70000000000000003e-31 < y.re < 2.9e18Initial program 39.6%
exp-diff39.6%
exp-to-pow39.6%
hypot-define39.6%
*-commutative39.6%
exp-prod39.0%
fma-define39.0%
hypot-define76.4%
*-commutative76.4%
Simplified76.4%
Taylor expanded in y.im around 0 71.0%
add-sqr-sqrt42.7%
pow242.7%
*-commutative42.7%
Applied egg-rr42.7%
Taylor expanded in y.re around 0 74.9%
if -2.2999999999999999e-241 < y.re < 6.70000000000000003e-31Initial program 49.0%
exp-diff49.0%
exp-to-pow49.0%
hypot-define49.0%
*-commutative49.0%
exp-prod49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Simplified84.9%
fma-undefine84.9%
hypot-define49.0%
*-commutative49.0%
expm1-log1p-u49.0%
*-commutative49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Applied egg-rr84.9%
Taylor expanded in y.re around 0 43.0%
+-commutative43.0%
unpow243.0%
unpow243.0%
hypot-undefine72.9%
exp-prod72.7%
Simplified72.7%
if 2.9e18 < y.re Initial program 38.5%
exp-diff34.6%
exp-to-pow34.6%
hypot-define34.6%
*-commutative34.6%
exp-prod34.6%
fma-define34.6%
hypot-define55.8%
*-commutative55.8%
Simplified55.8%
fma-undefine55.8%
hypot-define34.6%
*-commutative34.6%
expm1-log1p-u34.6%
*-commutative34.6%
fma-define34.6%
hypot-define55.8%
*-commutative55.8%
Applied egg-rr55.8%
Taylor expanded in y.im around 0 57.8%
+-commutative57.8%
unpow257.8%
unpow257.8%
hypot-undefine57.8%
Simplified57.8%
add-cube-cbrt57.8%
pow357.8%
*-commutative57.8%
Applied egg-rr57.8%
Final simplification72.4%
(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 (exp (* y.im (atan2 x.im x.re)))))
(t_2 (pow (hypot x.re x.im) y.re))
(t_3 (sin t_0)))
(if (<= y.re -0.0017)
(* t_2 (sqrt (pow t_3 2.0)))
(if (<= y.re -2.3e-241)
t_1
(if (<= y.re 6.7e-31)
(/
(sin (* y.im (log (hypot x.re x.im))))
(pow (exp y.im) (atan2 x.im x.re)))
(if (<= y.re 1.4e+21) t_1 (* t_3 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 = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re)));
double t_2 = pow(hypot(x_46_re, x_46_im), y_46_re);
double t_3 = sin(t_0);
double tmp;
if (y_46_re <= -0.0017) {
tmp = t_2 * sqrt(pow(t_3, 2.0));
} else if (y_46_re <= -2.3e-241) {
tmp = t_1;
} else if (y_46_re <= 6.7e-31) {
tmp = sin((y_46_im * log(hypot(x_46_re, x_46_im)))) / pow(exp(y_46_im), atan2(x_46_im, x_46_re));
} else if (y_46_re <= 1.4e+21) {
tmp = t_1;
} else {
tmp = t_3 * t_2;
}
return tmp;
}
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.exp((y_46_im * Math.atan2(x_46_im, x_46_re)));
double t_2 = Math.pow(Math.hypot(x_46_re, x_46_im), y_46_re);
double t_3 = Math.sin(t_0);
double tmp;
if (y_46_re <= -0.0017) {
tmp = t_2 * Math.sqrt(Math.pow(t_3, 2.0));
} else if (y_46_re <= -2.3e-241) {
tmp = t_1;
} else if (y_46_re <= 6.7e-31) {
tmp = Math.sin((y_46_im * Math.log(Math.hypot(x_46_re, x_46_im)))) / Math.pow(Math.exp(y_46_im), Math.atan2(x_46_im, x_46_re));
} else if (y_46_re <= 1.4e+21) {
tmp = t_1;
} else {
tmp = t_3 * t_2;
}
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.exp((y_46_im * math.atan2(x_46_im, x_46_re))) t_2 = math.pow(math.hypot(x_46_re, x_46_im), y_46_re) t_3 = math.sin(t_0) tmp = 0 if y_46_re <= -0.0017: tmp = t_2 * math.sqrt(math.pow(t_3, 2.0)) elif y_46_re <= -2.3e-241: tmp = t_1 elif y_46_re <= 6.7e-31: tmp = math.sin((y_46_im * math.log(math.hypot(x_46_re, x_46_im)))) / math.pow(math.exp(y_46_im), math.atan2(x_46_im, x_46_re)) elif y_46_re <= 1.4e+21: tmp = t_1 else: tmp = t_3 * 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 = Float64(t_0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))) t_2 = hypot(x_46_re, x_46_im) ^ y_46_re t_3 = sin(t_0) tmp = 0.0 if (y_46_re <= -0.0017) tmp = Float64(t_2 * sqrt((t_3 ^ 2.0))); elseif (y_46_re <= -2.3e-241) tmp = t_1; elseif (y_46_re <= 6.7e-31) tmp = Float64(sin(Float64(y_46_im * log(hypot(x_46_re, x_46_im)))) / (exp(y_46_im) ^ atan(x_46_im, x_46_re))); elseif (y_46_re <= 1.4e+21) tmp = t_1; else tmp = Float64(t_3 * t_2); 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 / exp((y_46_im * atan2(x_46_im, x_46_re))); t_2 = hypot(x_46_re, x_46_im) ^ y_46_re; t_3 = sin(t_0); tmp = 0.0; if (y_46_re <= -0.0017) tmp = t_2 * sqrt((t_3 ^ 2.0)); elseif (y_46_re <= -2.3e-241) tmp = t_1; elseif (y_46_re <= 6.7e-31) tmp = sin((y_46_im * log(hypot(x_46_re, x_46_im)))) / (exp(y_46_im) ^ atan2(x_46_im, x_46_re)); elseif (y_46_re <= 1.4e+21) tmp = t_1; else tmp = t_3 * t_2; 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[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]}, Block[{t$95$3 = N[Sin[t$95$0], $MachinePrecision]}, If[LessEqual[y$46$re, -0.0017], N[(t$95$2 * N[Sqrt[N[Power[t$95$3, 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, -2.3e-241], t$95$1, If[LessEqual[y$46$re, 6.7e-31], N[(N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Power[N[Exp[y$46$im], $MachinePrecision], N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 1.4e+21], t$95$1, N[(t$95$3 * t$95$2), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := \frac{t\_0}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
t_2 := {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}\\
t_3 := \sin t\_0\\
\mathbf{if}\;y.re \leq -0.0017:\\
\;\;\;\;t\_2 \cdot \sqrt{{t\_3}^{2}}\\
\mathbf{elif}\;y.re \leq -2.3 \cdot 10^{-241}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y.re \leq 6.7 \cdot 10^{-31}:\\
\;\;\;\;\frac{\sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)\right)}{{\left(e^{y.im}\right)}^{\tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.re \leq 1.4 \cdot 10^{+21}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_3 \cdot t\_2\\
\end{array}
\end{array}
if y.re < -0.00169999999999999991Initial program 51.4%
exp-diff44.4%
exp-to-pow44.4%
hypot-define44.4%
*-commutative44.4%
exp-prod43.1%
fma-define43.1%
hypot-define68.1%
*-commutative68.1%
Simplified68.1%
fma-undefine68.1%
hypot-define43.1%
*-commutative43.1%
expm1-log1p-u43.1%
*-commutative43.1%
fma-define43.1%
hypot-define68.1%
*-commutative68.1%
Applied egg-rr68.1%
Taylor expanded in y.im around 0 75.2%
+-commutative75.2%
unpow275.2%
unpow275.2%
hypot-undefine75.2%
Simplified75.2%
add-sqr-sqrt41.8%
sqrt-unprod80.7%
pow280.7%
*-commutative80.7%
Applied egg-rr80.7%
if -0.00169999999999999991 < y.re < -2.2999999999999999e-241 or 6.70000000000000003e-31 < y.re < 1.4e21Initial program 39.6%
exp-diff39.6%
exp-to-pow39.6%
hypot-define39.6%
*-commutative39.6%
exp-prod39.0%
fma-define39.0%
hypot-define76.4%
*-commutative76.4%
Simplified76.4%
Taylor expanded in y.im around 0 71.0%
add-sqr-sqrt42.7%
pow242.7%
*-commutative42.7%
Applied egg-rr42.7%
Taylor expanded in y.re around 0 74.9%
if -2.2999999999999999e-241 < y.re < 6.70000000000000003e-31Initial program 49.0%
exp-diff49.0%
exp-to-pow49.0%
hypot-define49.0%
*-commutative49.0%
exp-prod49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Simplified84.9%
fma-undefine84.9%
hypot-define49.0%
*-commutative49.0%
expm1-log1p-u49.0%
*-commutative49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Applied egg-rr84.9%
Taylor expanded in y.re around 0 43.0%
+-commutative43.0%
unpow243.0%
unpow243.0%
hypot-undefine72.9%
exp-prod72.7%
Simplified72.7%
if 1.4e21 < y.re Initial program 38.5%
exp-diff34.6%
exp-to-pow34.6%
hypot-define34.6%
*-commutative34.6%
exp-prod34.6%
fma-define34.6%
hypot-define55.8%
*-commutative55.8%
Simplified55.8%
fma-undefine55.8%
hypot-define34.6%
*-commutative34.6%
expm1-log1p-u34.6%
*-commutative34.6%
fma-define34.6%
hypot-define55.8%
*-commutative55.8%
Applied egg-rr55.8%
Taylor expanded in y.im around 0 57.8%
+-commutative57.8%
unpow257.8%
unpow257.8%
hypot-undefine57.8%
Simplified57.8%
Final simplification72.4%
(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 (exp (* y.im (atan2 x.im x.re)))))
(t_2 (* (sin t_0) (pow (hypot x.re x.im) y.re))))
(if (<= y.re -0.00165)
t_2
(if (<= y.re -2.3e-241)
t_1
(if (<= y.re 2.85e-30)
(/
(sin (* y.im (log (hypot x.re x.im))))
(pow (exp y.im) (atan2 x.im x.re)))
(if (<= y.re 4.4e+18) 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 = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re)));
double t_2 = sin(t_0) * pow(hypot(x_46_re, x_46_im), y_46_re);
double tmp;
if (y_46_re <= -0.00165) {
tmp = t_2;
} else if (y_46_re <= -2.3e-241) {
tmp = t_1;
} else if (y_46_re <= 2.85e-30) {
tmp = sin((y_46_im * log(hypot(x_46_re, x_46_im)))) / pow(exp(y_46_im), atan2(x_46_im, x_46_re));
} else if (y_46_re <= 4.4e+18) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
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.exp((y_46_im * Math.atan2(x_46_im, x_46_re)));
double t_2 = Math.sin(t_0) * Math.pow(Math.hypot(x_46_re, x_46_im), y_46_re);
double tmp;
if (y_46_re <= -0.00165) {
tmp = t_2;
} else if (y_46_re <= -2.3e-241) {
tmp = t_1;
} else if (y_46_re <= 2.85e-30) {
tmp = Math.sin((y_46_im * Math.log(Math.hypot(x_46_re, x_46_im)))) / Math.pow(Math.exp(y_46_im), Math.atan2(x_46_im, x_46_re));
} else if (y_46_re <= 4.4e+18) {
tmp = t_1;
} else {
tmp = t_2;
}
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.exp((y_46_im * math.atan2(x_46_im, x_46_re))) t_2 = math.sin(t_0) * math.pow(math.hypot(x_46_re, x_46_im), y_46_re) tmp = 0 if y_46_re <= -0.00165: tmp = t_2 elif y_46_re <= -2.3e-241: tmp = t_1 elif y_46_re <= 2.85e-30: tmp = math.sin((y_46_im * math.log(math.hypot(x_46_re, x_46_im)))) / math.pow(math.exp(y_46_im), math.atan2(x_46_im, x_46_re)) elif y_46_re <= 4.4e+18: 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 = Float64(t_0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))) t_2 = Float64(sin(t_0) * (hypot(x_46_re, x_46_im) ^ y_46_re)) tmp = 0.0 if (y_46_re <= -0.00165) tmp = t_2; elseif (y_46_re <= -2.3e-241) tmp = t_1; elseif (y_46_re <= 2.85e-30) tmp = Float64(sin(Float64(y_46_im * log(hypot(x_46_re, x_46_im)))) / (exp(y_46_im) ^ atan(x_46_im, x_46_re))); elseif (y_46_re <= 4.4e+18) tmp = t_1; else tmp = t_2; 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 / exp((y_46_im * atan2(x_46_im, x_46_re))); t_2 = sin(t_0) * (hypot(x_46_re, x_46_im) ^ y_46_re); tmp = 0.0; if (y_46_re <= -0.00165) tmp = t_2; elseif (y_46_re <= -2.3e-241) tmp = t_1; elseif (y_46_re <= 2.85e-30) tmp = sin((y_46_im * log(hypot(x_46_re, x_46_im)))) / (exp(y_46_im) ^ atan2(x_46_im, x_46_re)); elseif (y_46_re <= 4.4e+18) tmp = t_1; else tmp = t_2; 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[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[Sin[t$95$0], $MachinePrecision] * N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -0.00165], t$95$2, If[LessEqual[y$46$re, -2.3e-241], t$95$1, If[LessEqual[y$46$re, 2.85e-30], N[(N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Power[N[Exp[y$46$im], $MachinePrecision], N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 4.4e+18], 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 := \frac{t\_0}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
t_2 := \sin t\_0 \cdot {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}\\
\mathbf{if}\;y.re \leq -0.00165:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y.re \leq -2.3 \cdot 10^{-241}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y.re \leq 2.85 \cdot 10^{-30}:\\
\;\;\;\;\frac{\sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)\right)}{{\left(e^{y.im}\right)}^{\tan^{-1}_* \frac{x.im}{x.re}}}\\
\mathbf{elif}\;y.re \leq 4.4 \cdot 10^{+18}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y.re < -0.00165 or 4.4e18 < y.re Initial program 46.0%
exp-diff40.3%
exp-to-pow40.3%
hypot-define40.3%
*-commutative40.3%
exp-prod39.5%
fma-define39.5%
hypot-define62.9%
*-commutative62.9%
Simplified62.9%
fma-undefine62.9%
hypot-define39.5%
*-commutative39.5%
expm1-log1p-u39.5%
*-commutative39.5%
fma-define39.5%
hypot-define62.9%
*-commutative62.9%
Applied egg-rr62.9%
Taylor expanded in y.im around 0 67.9%
+-commutative67.9%
unpow267.9%
unpow267.9%
hypot-undefine67.9%
Simplified67.9%
if -0.00165 < y.re < -2.2999999999999999e-241 or 2.84999999999999989e-30 < y.re < 4.4e18Initial program 39.6%
exp-diff39.6%
exp-to-pow39.6%
hypot-define39.6%
*-commutative39.6%
exp-prod39.0%
fma-define39.0%
hypot-define76.4%
*-commutative76.4%
Simplified76.4%
Taylor expanded in y.im around 0 71.0%
add-sqr-sqrt42.7%
pow242.7%
*-commutative42.7%
Applied egg-rr42.7%
Taylor expanded in y.re around 0 74.9%
if -2.2999999999999999e-241 < y.re < 2.84999999999999989e-30Initial program 49.0%
exp-diff49.0%
exp-to-pow49.0%
hypot-define49.0%
*-commutative49.0%
exp-prod49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Simplified84.9%
fma-undefine84.9%
hypot-define49.0%
*-commutative49.0%
expm1-log1p-u49.0%
*-commutative49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Applied egg-rr84.9%
Taylor expanded in y.re around 0 43.0%
+-commutative43.0%
unpow243.0%
unpow243.0%
hypot-undefine72.9%
exp-prod72.7%
Simplified72.7%
(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 (exp (* y.im (atan2 x.im x.re)))))
(t_2 (* (sin t_0) (pow (hypot x.re x.im) y.re))))
(if (<= y.re -0.00145)
t_2
(if (<= y.re -2.3e-241)
t_1
(if (<= y.re 6.8e-31)
(/
(sin (* y.im (log (hypot x.im x.re))))
(pow (exp (atan2 x.im x.re)) y.im))
(if (<= y.re 4.8e+19) 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 = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re)));
double t_2 = sin(t_0) * pow(hypot(x_46_re, x_46_im), y_46_re);
double tmp;
if (y_46_re <= -0.00145) {
tmp = t_2;
} else if (y_46_re <= -2.3e-241) {
tmp = t_1;
} else if (y_46_re <= 6.8e-31) {
tmp = sin((y_46_im * log(hypot(x_46_im, x_46_re)))) / pow(exp(atan2(x_46_im, x_46_re)), y_46_im);
} else if (y_46_re <= 4.8e+19) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
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.exp((y_46_im * Math.atan2(x_46_im, x_46_re)));
double t_2 = Math.sin(t_0) * Math.pow(Math.hypot(x_46_re, x_46_im), y_46_re);
double tmp;
if (y_46_re <= -0.00145) {
tmp = t_2;
} else if (y_46_re <= -2.3e-241) {
tmp = t_1;
} else if (y_46_re <= 6.8e-31) {
tmp = Math.sin((y_46_im * Math.log(Math.hypot(x_46_im, x_46_re)))) / Math.pow(Math.exp(Math.atan2(x_46_im, x_46_re)), y_46_im);
} else if (y_46_re <= 4.8e+19) {
tmp = t_1;
} else {
tmp = t_2;
}
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.exp((y_46_im * math.atan2(x_46_im, x_46_re))) t_2 = math.sin(t_0) * math.pow(math.hypot(x_46_re, x_46_im), y_46_re) tmp = 0 if y_46_re <= -0.00145: tmp = t_2 elif y_46_re <= -2.3e-241: tmp = t_1 elif y_46_re <= 6.8e-31: tmp = math.sin((y_46_im * math.log(math.hypot(x_46_im, x_46_re)))) / math.pow(math.exp(math.atan2(x_46_im, x_46_re)), y_46_im) elif y_46_re <= 4.8e+19: 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 = Float64(t_0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))) t_2 = Float64(sin(t_0) * (hypot(x_46_re, x_46_im) ^ y_46_re)) tmp = 0.0 if (y_46_re <= -0.00145) tmp = t_2; elseif (y_46_re <= -2.3e-241) tmp = t_1; elseif (y_46_re <= 6.8e-31) tmp = Float64(sin(Float64(y_46_im * log(hypot(x_46_im, x_46_re)))) / (exp(atan(x_46_im, x_46_re)) ^ y_46_im)); elseif (y_46_re <= 4.8e+19) tmp = t_1; else tmp = t_2; 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 / exp((y_46_im * atan2(x_46_im, x_46_re))); t_2 = sin(t_0) * (hypot(x_46_re, x_46_im) ^ y_46_re); tmp = 0.0; if (y_46_re <= -0.00145) tmp = t_2; elseif (y_46_re <= -2.3e-241) tmp = t_1; elseif (y_46_re <= 6.8e-31) tmp = sin((y_46_im * log(hypot(x_46_im, x_46_re)))) / (exp(atan2(x_46_im, x_46_re)) ^ y_46_im); elseif (y_46_re <= 4.8e+19) tmp = t_1; else tmp = t_2; 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[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[Sin[t$95$0], $MachinePrecision] * N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -0.00145], t$95$2, If[LessEqual[y$46$re, -2.3e-241], t$95$1, If[LessEqual[y$46$re, 6.8e-31], N[(N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Power[N[Exp[N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision], y$46$im], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 4.8e+19], 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 := \frac{t\_0}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
t_2 := \sin t\_0 \cdot {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}\\
\mathbf{if}\;y.re \leq -0.00145:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y.re \leq -2.3 \cdot 10^{-241}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y.re \leq 6.8 \cdot 10^{-31}:\\
\;\;\;\;\frac{\sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right)}{{\left(e^{\tan^{-1}_* \frac{x.im}{x.re}}\right)}^{y.im}}\\
\mathbf{elif}\;y.re \leq 4.8 \cdot 10^{+19}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y.re < -0.00145 or 4.8e19 < y.re Initial program 46.0%
exp-diff40.3%
exp-to-pow40.3%
hypot-define40.3%
*-commutative40.3%
exp-prod39.5%
fma-define39.5%
hypot-define62.9%
*-commutative62.9%
Simplified62.9%
fma-undefine62.9%
hypot-define39.5%
*-commutative39.5%
expm1-log1p-u39.5%
*-commutative39.5%
fma-define39.5%
hypot-define62.9%
*-commutative62.9%
Applied egg-rr62.9%
Taylor expanded in y.im around 0 67.9%
+-commutative67.9%
unpow267.9%
unpow267.9%
hypot-undefine67.9%
Simplified67.9%
if -0.00145 < y.re < -2.2999999999999999e-241 or 6.8000000000000002e-31 < y.re < 4.8e19Initial program 39.6%
exp-diff39.6%
exp-to-pow39.6%
hypot-define39.6%
*-commutative39.6%
exp-prod39.0%
fma-define39.0%
hypot-define76.4%
*-commutative76.4%
Simplified76.4%
Taylor expanded in y.im around 0 71.0%
add-sqr-sqrt42.7%
pow242.7%
*-commutative42.7%
Applied egg-rr42.7%
Taylor expanded in y.re around 0 74.9%
if -2.2999999999999999e-241 < y.re < 6.8000000000000002e-31Initial program 49.0%
exp-diff49.0%
exp-to-pow49.0%
hypot-define49.0%
*-commutative49.0%
exp-prod49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Simplified84.9%
fma-undefine84.9%
hypot-define49.0%
*-commutative49.0%
expm1-log1p-u49.0%
*-commutative49.0%
fma-define49.0%
hypot-define84.9%
*-commutative84.9%
Applied egg-rr84.9%
Taylor expanded in y.re around 0 43.0%
unpow243.0%
unpow243.0%
hypot-define72.9%
*-commutative72.9%
exp-prod70.5%
Simplified70.5%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re))))
(if (or (<= y.re -0.0013) (not (<= y.re 2.1e+18)))
(* (sin t_0) (pow (hypot x.re x.im) y.re))
(/ t_0 (exp (* y.im (atan2 x.im 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 tmp;
if ((y_46_re <= -0.0013) || !(y_46_re <= 2.1e+18)) {
tmp = sin(t_0) * pow(hypot(x_46_re, x_46_im), y_46_re);
} else {
tmp = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re)));
}
return tmp;
}
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 tmp;
if ((y_46_re <= -0.0013) || !(y_46_re <= 2.1e+18)) {
tmp = Math.sin(t_0) * Math.pow(Math.hypot(x_46_re, x_46_im), y_46_re);
} else {
tmp = t_0 / Math.exp((y_46_im * Math.atan2(x_46_im, x_46_re)));
}
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) tmp = 0 if (y_46_re <= -0.0013) or not (y_46_re <= 2.1e+18): tmp = math.sin(t_0) * math.pow(math.hypot(x_46_re, x_46_im), y_46_re) else: tmp = t_0 / math.exp((y_46_im * math.atan2(x_46_im, 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)) tmp = 0.0 if ((y_46_re <= -0.0013) || !(y_46_re <= 2.1e+18)) tmp = Float64(sin(t_0) * (hypot(x_46_re, x_46_im) ^ y_46_re)); else tmp = Float64(t_0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))); 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); tmp = 0.0; if ((y_46_re <= -0.0013) || ~((y_46_re <= 2.1e+18))) tmp = sin(t_0) * (hypot(x_46_re, x_46_im) ^ y_46_re); else tmp = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re))); 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]}, If[Or[LessEqual[y$46$re, -0.0013], N[Not[LessEqual[y$46$re, 2.1e+18]], $MachinePrecision]], N[(N[Sin[t$95$0], $MachinePrecision] * N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision], N[(t$95$0 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
\mathbf{if}\;y.re \leq -0.0013 \lor \neg \left(y.re \leq 2.1 \cdot 10^{+18}\right):\\
\;\;\;\;\sin t\_0 \cdot {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}\\
\mathbf{else}:\\
\;\;\;\;\frac{t\_0}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\end{array}
\end{array}
if y.re < -0.0012999999999999999 or 2.1e18 < y.re Initial program 46.0%
exp-diff40.3%
exp-to-pow40.3%
hypot-define40.3%
*-commutative40.3%
exp-prod39.5%
fma-define39.5%
hypot-define62.9%
*-commutative62.9%
Simplified62.9%
fma-undefine62.9%
hypot-define39.5%
*-commutative39.5%
expm1-log1p-u39.5%
*-commutative39.5%
fma-define39.5%
hypot-define62.9%
*-commutative62.9%
Applied egg-rr62.9%
Taylor expanded in y.im around 0 67.9%
+-commutative67.9%
unpow267.9%
unpow267.9%
hypot-undefine67.9%
Simplified67.9%
if -0.0012999999999999999 < y.re < 2.1e18Initial program 45.2%
exp-diff45.2%
exp-to-pow45.2%
hypot-define45.2%
*-commutative45.2%
exp-prod44.9%
fma-define44.9%
hypot-define81.4%
*-commutative81.4%
Simplified81.4%
Taylor expanded in y.im around 0 56.5%
add-sqr-sqrt33.4%
pow233.4%
*-commutative33.4%
Applied egg-rr33.4%
Taylor expanded in y.re around 0 58.2%
Final simplification62.9%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re))))
(if (or (<= y.re -1.3e+24) (not (<= y.re 2.15e+18)))
(* t_0 (pow (hypot x.re x.im) y.re))
(/ t_0 (exp (* y.im (atan2 x.im 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 tmp;
if ((y_46_re <= -1.3e+24) || !(y_46_re <= 2.15e+18)) {
tmp = t_0 * pow(hypot(x_46_re, x_46_im), y_46_re);
} else {
tmp = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re)));
}
return tmp;
}
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 tmp;
if ((y_46_re <= -1.3e+24) || !(y_46_re <= 2.15e+18)) {
tmp = t_0 * Math.pow(Math.hypot(x_46_re, x_46_im), y_46_re);
} else {
tmp = t_0 / Math.exp((y_46_im * Math.atan2(x_46_im, x_46_re)));
}
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) tmp = 0 if (y_46_re <= -1.3e+24) or not (y_46_re <= 2.15e+18): tmp = t_0 * math.pow(math.hypot(x_46_re, x_46_im), y_46_re) else: tmp = t_0 / math.exp((y_46_im * math.atan2(x_46_im, 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)) tmp = 0.0 if ((y_46_re <= -1.3e+24) || !(y_46_re <= 2.15e+18)) tmp = Float64(t_0 * (hypot(x_46_re, x_46_im) ^ y_46_re)); else tmp = Float64(t_0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))); 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); tmp = 0.0; if ((y_46_re <= -1.3e+24) || ~((y_46_re <= 2.15e+18))) tmp = t_0 * (hypot(x_46_re, x_46_im) ^ y_46_re); else tmp = t_0 / exp((y_46_im * atan2(x_46_im, x_46_re))); 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]}, If[Or[LessEqual[y$46$re, -1.3e+24], N[Not[LessEqual[y$46$re, 2.15e+18]], $MachinePrecision]], N[(t$95$0 * N[Power[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision], N[(t$95$0 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
\mathbf{if}\;y.re \leq -1.3 \cdot 10^{+24} \lor \neg \left(y.re \leq 2.15 \cdot 10^{+18}\right):\\
\;\;\;\;t\_0 \cdot {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}\\
\mathbf{else}:\\
\;\;\;\;\frac{t\_0}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\end{array}
\end{array}
if y.re < -1.2999999999999999e24 or 2.15e18 < y.re Initial program 45.7%
exp-diff40.5%
exp-to-pow40.5%
hypot-define40.5%
*-commutative40.5%
exp-prod39.7%
fma-define39.7%
hypot-define62.9%
*-commutative62.9%
Simplified62.9%
fma-undefine62.9%
hypot-define39.7%
*-commutative39.7%
expm1-log1p-u39.7%
*-commutative39.7%
fma-define39.7%
hypot-define62.9%
*-commutative62.9%
Applied egg-rr62.9%
Taylor expanded in y.im around 0 69.1%
+-commutative69.1%
unpow269.1%
unpow269.1%
hypot-undefine69.1%
Simplified69.1%
Taylor expanded in y.re around 0 63.9%
if -1.2999999999999999e24 < y.re < 2.15e18Initial program 45.5%
exp-diff44.7%
exp-to-pow44.7%
hypot-define44.7%
*-commutative44.7%
exp-prod44.5%
fma-define44.5%
hypot-define80.3%
*-commutative80.3%
Simplified80.3%
Taylor expanded in y.im around 0 56.1%
add-sqr-sqrt32.2%
pow232.2%
*-commutative32.2%
Applied egg-rr32.2%
Taylor expanded in y.re around 0 57.7%
Final simplification60.5%
(FPCore (x.re x.im y.re y.im) :precision binary64 (* (* y.re (atan2 x.im x.re)) (pow (hypot x.re x.im) 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(hypot(x_46_re, x_46_im), y_46_re);
}
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)) * Math.pow(Math.hypot(x_46_re, x_46_im), y_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)) * math.pow(math.hypot(x_46_re, x_46_im), 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)) * (hypot(x_46_re, x_46_im) ^ y_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)) * (hypot(x_46_re, x_46_im) ^ 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[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right) \cdot {\left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{y.re}
\end{array}
Initial program 45.6%
exp-diff42.8%
exp-to-pow42.8%
hypot-define42.8%
*-commutative42.8%
exp-prod42.3%
fma-define42.3%
hypot-define72.4%
*-commutative72.4%
Simplified72.4%
fma-undefine72.4%
hypot-define42.3%
*-commutative42.3%
expm1-log1p-u42.3%
*-commutative42.3%
fma-define42.3%
hypot-define72.5%
*-commutative72.5%
Applied egg-rr72.5%
Taylor expanded in y.im around 0 43.6%
+-commutative43.6%
unpow243.6%
unpow243.6%
hypot-undefine46.8%
Simplified46.8%
Taylor expanded in y.re around 0 44.3%
herbie shell --seed 2024111
(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)))))