
(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 25 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 (* y.re (atan2 x.im x.re)))
(t_1
(*
(exp
(-
(* y.re (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
(* y.im (atan2 x.im x.re))))
(sin (* y.im (log (hypot x.im x.re)))))))
(if (<= y.re -60000000000000.0)
t_1
(if (<= y.re 2.7e+71)
(*
(/ (pow (hypot x.re x.im) y.re) (pow (exp y.im) (atan2 x.im x.re)))
(sin (fma (log (hypot x.re x.im)) y.im t_0)))
(if (<= y.re 2.65e+249)
t_1
(pow (pow (* (pow x.im y.re) (sin t_0)) 3.0) 0.3333333333333333))))))
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 = 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)))) * sin((y_46_im * log(hypot(x_46_im, x_46_re))));
double tmp;
if (y_46_re <= -60000000000000.0) {
tmp = t_1;
} else if (y_46_re <= 2.7e+71) {
tmp = (pow(hypot(x_46_re, x_46_im), y_46_re) / pow(exp(y_46_im), atan2(x_46_im, x_46_re))) * sin(fma(log(hypot(x_46_re, x_46_im)), y_46_im, t_0));
} else if (y_46_re <= 2.65e+249) {
tmp = t_1;
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * sin(t_0)), 3.0), 0.3333333333333333);
}
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(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)))) * sin(Float64(y_46_im * log(hypot(x_46_im, x_46_re))))) tmp = 0.0 if (y_46_re <= -60000000000000.0) tmp = t_1; elseif (y_46_re <= 2.7e+71) tmp = Float64(Float64((hypot(x_46_re, x_46_im) ^ y_46_re) / (exp(y_46_im) ^ atan(x_46_im, x_46_re))) * sin(fma(log(hypot(x_46_re, x_46_im)), y_46_im, t_0))); elseif (y_46_re <= 2.65e+249) tmp = t_1; else tmp = (Float64((x_46_im ^ y_46_re) * sin(t_0)) ^ 3.0) ^ 0.3333333333333333; end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[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] * N[Sin[N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -60000000000000.0], t$95$1, If[LessEqual[y$46$re, 2.7e+71], N[(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] * N[Sin[N[(N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision] * y$46$im + t$95$0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 2.65e+249], t$95$1, N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := 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}} \cdot \sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right)\\
\mathbf{if}\;y.re \leq -60000000000000:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y.re \leq 2.7 \cdot 10^{+71}:\\
\;\;\;\;\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}}} \cdot \sin \left(\mathsf{fma}\left(\log \left(\mathsf{hypot}\left(x.re, x.im\right)\right), y.im, t\_0\right)\right)\\
\mathbf{elif}\;y.re \leq 2.65 \cdot 10^{+249}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot \sin t\_0\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -6e13 or 2.69999999999999997e71 < y.re < 2.65000000000000019e249Initial program 42.3%
Taylor expanded in y.re around 0 46.2%
unpow246.2%
unpow246.2%
hypot-undefine84.7%
Simplified84.7%
if -6e13 < y.re < 2.69999999999999997e71Initial program 46.0%
exp-diff46.0%
exp-to-pow46.0%
hypot-define46.3%
*-commutative46.3%
exp-prod46.2%
fma-define46.2%
hypot-define80.1%
*-commutative80.1%
Simplified80.1%
if 2.65000000000000019e249 < y.re Initial program 37.5%
fma-neg37.5%
hypot-define37.5%
distribute-rgt-neg-out37.5%
fma-define37.5%
hypot-define37.5%
*-commutative37.5%
Simplified37.5%
Taylor expanded in y.im around 0 37.5%
unpow237.5%
unpow237.5%
hypot-undefine37.5%
Simplified37.5%
Taylor expanded in x.re around 0 37.7%
add-cbrt-cube37.7%
pow1/387.7%
pow387.7%
*-commutative87.7%
Applied egg-rr87.7%
Final simplification82.2%
(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)))
(t_2 (cbrt (fma y.im t_0 t_1))))
(if (<= x.re -1.2e+223)
(*
(/ (pow (hypot x.re x.im) y.re) (pow (exp y.im) (atan2 x.im x.re)))
(sin (* t_2 (pow (pow (cbrt t_2) 2.0) 3.0))))
(*
(exp (fma t_0 y.re (* y.im (- (atan2 x.im x.re)))))
(sin (fma t_0 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 = log(hypot(x_46_re, x_46_im));
double t_1 = y_46_re * atan2(x_46_im, x_46_re);
double t_2 = cbrt(fma(y_46_im, t_0, t_1));
double tmp;
if (x_46_re <= -1.2e+223) {
tmp = (pow(hypot(x_46_re, x_46_im), y_46_re) / pow(exp(y_46_im), atan2(x_46_im, x_46_re))) * sin((t_2 * pow(pow(cbrt(t_2), 2.0), 3.0)));
} else {
tmp = exp(fma(t_0, y_46_re, (y_46_im * -atan2(x_46_im, x_46_re)))) * sin(fma(t_0, y_46_im, t_1));
}
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)) t_2 = cbrt(fma(y_46_im, t_0, t_1)) tmp = 0.0 if (x_46_re <= -1.2e+223) tmp = Float64(Float64((hypot(x_46_re, x_46_im) ^ y_46_re) / (exp(y_46_im) ^ atan(x_46_im, x_46_re))) * sin(Float64(t_2 * ((cbrt(t_2) ^ 2.0) ^ 3.0)))); else tmp = Float64(exp(fma(t_0, y_46_re, Float64(y_46_im * Float64(-atan(x_46_im, x_46_re))))) * sin(fma(t_0, 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[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]}, Block[{t$95$2 = N[Power[N[(y$46$im * t$95$0 + t$95$1), $MachinePrecision], 1/3], $MachinePrecision]}, If[LessEqual[x$46$re, -1.2e+223], N[(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] * N[Sin[N[(t$95$2 * N[Power[N[Power[N[Power[t$95$2, 1/3], $MachinePrecision], 2.0], $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Exp[N[(t$95$0 * y$46$re + N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(t$95$0 * y$46$im + t$95$1), $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}\\
t_2 := \sqrt[3]{\mathsf{fma}\left(y.im, t\_0, t\_1\right)}\\
\mathbf{if}\;x.re \leq -1.2 \cdot 10^{+223}:\\
\;\;\;\;\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}}} \cdot \sin \left(t\_2 \cdot {\left({\left(\sqrt[3]{t\_2}\right)}^{2}\right)}^{3}\right)\\
\mathbf{else}:\\
\;\;\;\;e^{\mathsf{fma}\left(t\_0, y.re, y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \cdot \sin \left(\mathsf{fma}\left(t\_0, y.im, t\_1\right)\right)\\
\end{array}
\end{array}
if x.re < -1.20000000000000006e223Initial program 0.0%
exp-diff0.0%
exp-to-pow0.0%
hypot-define0.0%
*-commutative0.0%
exp-prod0.0%
fma-define0.0%
hypot-define55.5%
*-commutative55.5%
Simplified55.5%
add-cube-cbrt71.3%
pow371.4%
fma-undefine71.4%
*-commutative71.4%
*-commutative71.4%
fma-define71.4%
Applied egg-rr71.4%
add-cube-cbrt87.5%
unpow-prod-down87.5%
pow287.5%
pow381.9%
add-cube-cbrt93.1%
Applied egg-rr93.1%
if -1.20000000000000006e223 < x.re Initial program 47.6%
fma-neg47.6%
hypot-define47.7%
distribute-rgt-neg-out47.7%
fma-define47.7%
hypot-define81.2%
*-commutative81.2%
Simplified81.2%
Final simplification82.1%
(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.re x.im))))
(if (<= y.re 6.8e+66)
(*
(exp (fma t_1 y.re (* y.im (- (atan2 x.im x.re)))))
(sin (fma t_1 y.im t_0)))
(*
(pow (hypot x.im x.re) y.re)
(sin (pow (pow (cbrt (cbrt (fma y.im t_1 t_0))) 3.0) 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 = log(hypot(x_46_re, x_46_im));
double tmp;
if (y_46_re <= 6.8e+66) {
tmp = exp(fma(t_1, y_46_re, (y_46_im * -atan2(x_46_im, x_46_re)))) * sin(fma(t_1, y_46_im, t_0));
} else {
tmp = pow(hypot(x_46_im, x_46_re), y_46_re) * sin(pow(pow(cbrt(cbrt(fma(y_46_im, t_1, t_0))), 3.0), 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 = log(hypot(x_46_re, x_46_im)) tmp = 0.0 if (y_46_re <= 6.8e+66) tmp = Float64(exp(fma(t_1, y_46_re, Float64(y_46_im * Float64(-atan(x_46_im, x_46_re))))) * sin(fma(t_1, y_46_im, t_0))); else tmp = Float64((hypot(x_46_im, x_46_re) ^ y_46_re) * sin(((cbrt(cbrt(fma(y_46_im, t_1, t_0))) ^ 3.0) ^ 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[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]}, If[LessEqual[y$46$re, 6.8e+66], N[(N[Exp[N[(t$95$1 * y$46$re + N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(t$95$1 * y$46$im + t$95$0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] * N[Sin[N[Power[N[Power[N[Power[N[Power[N[(y$46$im * t$95$1 + t$95$0), $MachinePrecision], 1/3], $MachinePrecision], 1/3], $MachinePrecision], 3.0], $MachinePrecision], 3.0], $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.re, x.im\right)\right)\\
\mathbf{if}\;y.re \leq 6.8 \cdot 10^{+66}:\\
\;\;\;\;e^{\mathsf{fma}\left(t\_1, y.re, y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \cdot \sin \left(\mathsf{fma}\left(t\_1, y.im, t\_0\right)\right)\\
\mathbf{else}:\\
\;\;\;\;{\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re} \cdot \sin \left({\left({\left(\sqrt[3]{\sqrt[3]{\mathsf{fma}\left(y.im, t\_1, t\_0\right)}}\right)}^{3}\right)}^{3}\right)\\
\end{array}
\end{array}
if y.re < 6.8000000000000006e66Initial program 44.7%
fma-neg44.7%
hypot-define44.9%
distribute-rgt-neg-out44.9%
fma-define44.9%
hypot-define84.4%
*-commutative84.4%
Simplified84.4%
if 6.8000000000000006e66 < y.re Initial program 42.3%
exp-diff26.9%
exp-to-pow26.9%
hypot-define26.9%
*-commutative26.9%
exp-prod26.9%
fma-define26.9%
hypot-define36.5%
*-commutative36.5%
Simplified36.5%
add-cube-cbrt34.6%
pow336.5%
fma-undefine36.5%
*-commutative36.5%
*-commutative36.5%
fma-define36.5%
Applied egg-rr36.5%
Taylor expanded in y.im around 0 55.9%
unpow255.9%
unpow255.9%
hypot-undefine55.9%
Simplified55.9%
add-cube-cbrt67.5%
pow369.4%
Applied egg-rr69.4%
Final simplification81.4%
(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.re x.im))))
(if (<= y.im -6.7e+165)
(*
(/ 1.0 (exp (* y.im (atan2 x.im x.re))))
(sin (fabs (fma y.im (log (hypot x.im x.re)) t_0))))
(*
(exp (fma t_1 y.re (* y.im (- (atan2 x.im x.re)))))
(sin (fma t_1 y.im t_0))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = y_46_re * atan2(x_46_im, x_46_re);
double t_1 = log(hypot(x_46_re, x_46_im));
double tmp;
if (y_46_im <= -6.7e+165) {
tmp = (1.0 / exp((y_46_im * atan2(x_46_im, x_46_re)))) * sin(fabs(fma(y_46_im, log(hypot(x_46_im, x_46_re)), t_0)));
} else {
tmp = exp(fma(t_1, y_46_re, (y_46_im * -atan2(x_46_im, x_46_re)))) * sin(fma(t_1, y_46_im, t_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 = log(hypot(x_46_re, x_46_im)) tmp = 0.0 if (y_46_im <= -6.7e+165) tmp = Float64(Float64(1.0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))) * sin(abs(fma(y_46_im, log(hypot(x_46_im, x_46_re)), t_0)))); else tmp = Float64(exp(fma(t_1, y_46_re, Float64(y_46_im * Float64(-atan(x_46_im, x_46_re))))) * sin(fma(t_1, y_46_im, t_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[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]}, If[LessEqual[y$46$im, -6.7e+165], N[(N[(1.0 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Sin[N[Abs[N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision] + t$95$0), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Exp[N[(t$95$1 * y$46$re + N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sin[N[(t$95$1 * y$46$im + t$95$0), $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.re, x.im\right)\right)\\
\mathbf{if}\;y.im \leq -6.7 \cdot 10^{+165}:\\
\;\;\;\;\frac{1}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(\left|\mathsf{fma}\left(y.im, \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right), t\_0\right)\right|\right)\\
\mathbf{else}:\\
\;\;\;\;e^{\mathsf{fma}\left(t\_1, y.re, y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)\right)} \cdot \sin \left(\mathsf{fma}\left(t\_1, y.im, t\_0\right)\right)\\
\end{array}
\end{array}
if y.im < -6.70000000000000037e165Initial program 24.2%
exp-diff17.3%
exp-to-pow17.3%
hypot-define17.3%
*-commutative17.3%
exp-prod17.3%
fma-define17.3%
hypot-define35.2%
*-commutative35.2%
Simplified35.2%
Taylor expanded in y.re around 0 45.6%
add-sqr-sqrt7.0%
sqrt-unprod0.0%
pow20.0%
fma-undefine0.0%
*-commutative0.0%
*-commutative0.0%
fma-define0.0%
Applied egg-rr0.0%
unpow20.0%
rem-sqrt-square62.8%
hypot-undefine28.3%
unpow228.3%
unpow228.3%
+-commutative28.3%
*-commutative28.3%
unpow228.3%
unpow228.3%
hypot-undefine62.8%
Simplified62.8%
if -6.70000000000000037e165 < y.im Initial program 46.8%
fma-neg46.8%
hypot-define47.0%
distribute-rgt-neg-out47.0%
fma-define47.0%
hypot-define83.7%
*-commutative83.7%
Simplified83.7%
Final simplification81.4%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (log (hypot x.im x.re)))
(t_1
(*
(exp
(-
(* y.re (log (sqrt (+ (* x.re x.re) (* x.im x.im)))))
(* y.im (atan2 x.im x.re))))
(sin (* y.im t_0)))))
(if (<= y.re -1.58e+29)
t_1
(if (<= y.re 3.4e+28)
(*
(/ (pow (hypot x.re x.im) y.re) (pow (exp y.im) (atan2 x.im x.re)))
(sin (* y.im (+ t_0 (* y.re (/ (atan2 x.im x.re) y.im))))))
(if (<= y.re 1.2e+249)
t_1
(pow
(pow (* (pow x.im y.re) (sin (* y.re (atan2 x.im x.re)))) 3.0)
0.3333333333333333))))))
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 = 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)))) * sin((y_46_im * t_0));
double tmp;
if (y_46_re <= -1.58e+29) {
tmp = t_1;
} else if (y_46_re <= 3.4e+28) {
tmp = (pow(hypot(x_46_re, x_46_im), y_46_re) / pow(exp(y_46_im), atan2(x_46_im, x_46_re))) * sin((y_46_im * (t_0 + (y_46_re * (atan2(x_46_im, x_46_re) / y_46_im)))));
} else if (y_46_re <= 1.2e+249) {
tmp = t_1;
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * sin((y_46_re * atan2(x_46_im, x_46_re)))), 3.0), 0.3333333333333333);
}
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 = Math.log(Math.hypot(x_46_im, x_46_re));
double t_1 = Math.exp(((y_46_re * Math.log(Math.sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - (y_46_im * Math.atan2(x_46_im, x_46_re)))) * Math.sin((y_46_im * t_0));
double tmp;
if (y_46_re <= -1.58e+29) {
tmp = t_1;
} else if (y_46_re <= 3.4e+28) {
tmp = (Math.pow(Math.hypot(x_46_re, x_46_im), y_46_re) / Math.pow(Math.exp(y_46_im), Math.atan2(x_46_im, x_46_re))) * Math.sin((y_46_im * (t_0 + (y_46_re * (Math.atan2(x_46_im, x_46_re) / y_46_im)))));
} else if (y_46_re <= 1.2e+249) {
tmp = t_1;
} else {
tmp = Math.pow(Math.pow((Math.pow(x_46_im, y_46_re) * Math.sin((y_46_re * Math.atan2(x_46_im, x_46_re)))), 3.0), 0.3333333333333333);
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): t_0 = math.log(math.hypot(x_46_im, x_46_re)) t_1 = math.exp(((y_46_re * math.log(math.sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - (y_46_im * math.atan2(x_46_im, x_46_re)))) * math.sin((y_46_im * t_0)) tmp = 0 if y_46_re <= -1.58e+29: tmp = t_1 elif y_46_re <= 3.4e+28: tmp = (math.pow(math.hypot(x_46_re, x_46_im), y_46_re) / math.pow(math.exp(y_46_im), math.atan2(x_46_im, x_46_re))) * math.sin((y_46_im * (t_0 + (y_46_re * (math.atan2(x_46_im, x_46_re) / y_46_im))))) elif y_46_re <= 1.2e+249: tmp = t_1 else: tmp = math.pow(math.pow((math.pow(x_46_im, y_46_re) * math.sin((y_46_re * math.atan2(x_46_im, x_46_re)))), 3.0), 0.3333333333333333) 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(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)))) * sin(Float64(y_46_im * t_0))) tmp = 0.0 if (y_46_re <= -1.58e+29) tmp = t_1; elseif (y_46_re <= 3.4e+28) tmp = Float64(Float64((hypot(x_46_re, x_46_im) ^ y_46_re) / (exp(y_46_im) ^ atan(x_46_im, x_46_re))) * sin(Float64(y_46_im * Float64(t_0 + Float64(y_46_re * Float64(atan(x_46_im, x_46_re) / y_46_im)))))); elseif (y_46_re <= 1.2e+249) tmp = t_1; else tmp = (Float64((x_46_im ^ y_46_re) * sin(Float64(y_46_re * atan(x_46_im, x_46_re)))) ^ 3.0) ^ 0.3333333333333333; end return tmp end
function tmp_2 = 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 = 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)))) * sin((y_46_im * t_0)); tmp = 0.0; if (y_46_re <= -1.58e+29) tmp = t_1; elseif (y_46_re <= 3.4e+28) tmp = ((hypot(x_46_re, x_46_im) ^ y_46_re) / (exp(y_46_im) ^ atan2(x_46_im, x_46_re))) * sin((y_46_im * (t_0 + (y_46_re * (atan2(x_46_im, x_46_re) / y_46_im))))); elseif (y_46_re <= 1.2e+249) tmp = t_1; else tmp = (((x_46_im ^ y_46_re) * sin((y_46_re * atan2(x_46_im, x_46_re)))) ^ 3.0) ^ 0.3333333333333333; end tmp_2 = 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[(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] * N[Sin[N[(y$46$im * t$95$0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -1.58e+29], t$95$1, If[LessEqual[y$46$re, 3.4e+28], N[(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] * N[Sin[N[(y$46$im * N[(t$95$0 + N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] / y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 1.2e+249], t$95$1, N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\\
t_1 := 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}} \cdot \sin \left(y.im \cdot t\_0\right)\\
\mathbf{if}\;y.re \leq -1.58 \cdot 10^{+29}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y.re \leq 3.4 \cdot 10^{+28}:\\
\;\;\;\;\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}}} \cdot \sin \left(y.im \cdot \left(t\_0 + y.re \cdot \frac{\tan^{-1}_* \frac{x.im}{x.re}}{y.im}\right)\right)\\
\mathbf{elif}\;y.re \leq 1.2 \cdot 10^{+249}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -1.5799999999999999e29 or 3.4e28 < y.re < 1.2e249Initial program 42.9%
Taylor expanded in y.re around 0 43.8%
unpow243.8%
unpow243.8%
hypot-undefine82.2%
Simplified82.2%
if -1.5799999999999999e29 < y.re < 3.4e28Initial program 45.8%
exp-diff45.8%
exp-to-pow45.8%
hypot-define46.1%
*-commutative46.1%
exp-prod46.0%
fma-define46.0%
hypot-define80.4%
*-commutative80.4%
Simplified80.4%
Taylor expanded in y.im around inf 46.0%
unpow246.0%
unpow246.0%
hypot-undefine80.4%
associate-/l*81.1%
Simplified81.1%
if 1.2e249 < y.re Initial program 37.5%
fma-neg37.5%
hypot-define37.5%
distribute-rgt-neg-out37.5%
fma-define37.5%
hypot-define37.5%
*-commutative37.5%
Simplified37.5%
Taylor expanded in y.im around 0 37.5%
unpow237.5%
unpow237.5%
hypot-undefine37.5%
Simplified37.5%
Taylor expanded in x.re around 0 37.7%
add-cbrt-cube37.7%
pow1/387.7%
pow387.7%
*-commutative87.7%
Applied egg-rr87.7%
Final simplification81.8%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re)))
(t_1 (* y.im (atan2 x.im x.re)))
(t_2
(*
(exp (- (* y.re (log (sqrt (+ (* x.re x.re) (* x.im x.im))))) t_1))
(sin (* y.im (log (hypot x.im x.re)))))))
(if (<= y.re -0.91)
t_2
(if (<= y.re 6.5e+38)
(* (sin (fma (log (hypot x.re x.im)) y.im t_0)) (/ 1.0 (exp t_1)))
(if (<= y.re 1.04e+251)
t_2
(pow (pow (* (pow x.im y.re) (sin t_0)) 3.0) 0.3333333333333333))))))
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 = y_46_im * atan2(x_46_im, x_46_re);
double t_2 = exp(((y_46_re * log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - t_1)) * sin((y_46_im * log(hypot(x_46_im, x_46_re))));
double tmp;
if (y_46_re <= -0.91) {
tmp = t_2;
} else if (y_46_re <= 6.5e+38) {
tmp = sin(fma(log(hypot(x_46_re, x_46_im)), y_46_im, t_0)) * (1.0 / exp(t_1));
} else if (y_46_re <= 1.04e+251) {
tmp = t_2;
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * sin(t_0)), 3.0), 0.3333333333333333);
}
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(y_46_im * atan(x_46_im, x_46_re)) t_2 = Float64(exp(Float64(Float64(y_46_re * log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))) - t_1)) * sin(Float64(y_46_im * log(hypot(x_46_im, x_46_re))))) tmp = 0.0 if (y_46_re <= -0.91) tmp = t_2; elseif (y_46_re <= 6.5e+38) tmp = Float64(sin(fma(log(hypot(x_46_re, x_46_im)), y_46_im, t_0)) * Float64(1.0 / exp(t_1))); elseif (y_46_re <= 1.04e+251) tmp = t_2; else tmp = (Float64((x_46_im ^ y_46_re) * sin(t_0)) ^ 3.0) ^ 0.3333333333333333; 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[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(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] - t$95$1), $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]}, If[LessEqual[y$46$re, -0.91], t$95$2, If[LessEqual[y$46$re, 6.5e+38], N[(N[Sin[N[(N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision] * y$46$im + t$95$0), $MachinePrecision]], $MachinePrecision] * N[(1.0 / N[Exp[t$95$1], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 1.04e+251], t$95$2, N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_2 := e^{y.re \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) - t\_1} \cdot \sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right)\\
\mathbf{if}\;y.re \leq -0.91:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y.re \leq 6.5 \cdot 10^{+38}:\\
\;\;\;\;\sin \left(\mathsf{fma}\left(\log \left(\mathsf{hypot}\left(x.re, x.im\right)\right), y.im, t\_0\right)\right) \cdot \frac{1}{e^{t\_1}}\\
\mathbf{elif}\;y.re \leq 1.04 \cdot 10^{+251}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot \sin t\_0\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -0.910000000000000031 or 6.5e38 < y.re < 1.04000000000000005e251Initial program 44.1%
Taylor expanded in y.re around 0 46.8%
unpow246.8%
unpow246.8%
hypot-undefine83.8%
Simplified83.8%
if -0.910000000000000031 < y.re < 6.5e38Initial program 44.7%
exp-diff44.7%
exp-to-pow44.7%
hypot-define45.0%
*-commutative45.0%
exp-prod44.9%
fma-define44.9%
hypot-define79.8%
*-commutative79.8%
Simplified79.8%
Taylor expanded in y.re around 0 79.8%
if 1.04000000000000005e251 < y.re Initial program 37.5%
fma-neg37.5%
hypot-define37.5%
distribute-rgt-neg-out37.5%
fma-define37.5%
hypot-define37.5%
*-commutative37.5%
Simplified37.5%
Taylor expanded in y.im around 0 37.5%
unpow237.5%
unpow237.5%
hypot-undefine37.5%
Simplified37.5%
Taylor expanded in x.re around 0 37.7%
add-cbrt-cube37.7%
pow1/387.7%
pow387.7%
*-commutative87.7%
Applied egg-rr87.7%
Final simplification81.8%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.im (atan2 x.im x.re)))
(t_1 (sin (* y.re (atan2 x.im x.re))))
(t_2
(*
(/ 1.0 (exp t_0))
(sin
(*
y.re
(+
(atan2 x.im x.re)
(* y.im (/ (log (hypot x.im x.re)) y.re))))))))
(if (<= y.re -5e-7)
(*
(exp (- (* y.re (log (sqrt (+ (* x.re x.re) (* x.im x.im))))) t_0))
t_1)
(if (<= y.re -4.3e-169)
t_2
(if (<= y.re 1.12e-97)
(*
(sin (* y.im (cbrt (pow (log (hypot x.re x.im)) 3.0))))
(exp (* y.im (- (atan2 x.im x.re)))))
(if (<= y.re 3.6e+56)
t_2
(if (<= y.re 7.2e+103)
(*
y.re
(+
(atan2 x.im x.re)
(*
y.re
(* (atan2 x.im x.re) (log (log (exp (hypot x.re x.im))))))))
(if (<= y.re 6.5e+249)
(*
(pow (hypot x.im x.re) y.re)
(sin (* y.re (sqrt (pow (atan2 x.im x.re) 2.0)))))
(pow
(pow (* (pow x.im y.re) t_1) 3.0)
0.3333333333333333)))))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = y_46_im * atan2(x_46_im, x_46_re);
double t_1 = sin((y_46_re * atan2(x_46_im, x_46_re)));
double t_2 = (1.0 / exp(t_0)) * sin((y_46_re * (atan2(x_46_im, x_46_re) + (y_46_im * (log(hypot(x_46_im, x_46_re)) / y_46_re)))));
double tmp;
if (y_46_re <= -5e-7) {
tmp = exp(((y_46_re * log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - t_0)) * t_1;
} else if (y_46_re <= -4.3e-169) {
tmp = t_2;
} else if (y_46_re <= 1.12e-97) {
tmp = sin((y_46_im * cbrt(pow(log(hypot(x_46_re, x_46_im)), 3.0)))) * exp((y_46_im * -atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 3.6e+56) {
tmp = t_2;
} else if (y_46_re <= 7.2e+103) {
tmp = y_46_re * (atan2(x_46_im, x_46_re) + (y_46_re * (atan2(x_46_im, x_46_re) * log(log(exp(hypot(x_46_re, x_46_im)))))));
} else if (y_46_re <= 6.5e+249) {
tmp = pow(hypot(x_46_im, x_46_re), y_46_re) * sin((y_46_re * sqrt(pow(atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * t_1), 3.0), 0.3333333333333333);
}
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_im * Math.atan2(x_46_im, x_46_re);
double t_1 = Math.sin((y_46_re * Math.atan2(x_46_im, x_46_re)));
double t_2 = (1.0 / Math.exp(t_0)) * Math.sin((y_46_re * (Math.atan2(x_46_im, x_46_re) + (y_46_im * (Math.log(Math.hypot(x_46_im, x_46_re)) / y_46_re)))));
double tmp;
if (y_46_re <= -5e-7) {
tmp = Math.exp(((y_46_re * Math.log(Math.sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - t_0)) * t_1;
} else if (y_46_re <= -4.3e-169) {
tmp = t_2;
} else if (y_46_re <= 1.12e-97) {
tmp = Math.sin((y_46_im * Math.cbrt(Math.pow(Math.log(Math.hypot(x_46_re, x_46_im)), 3.0)))) * Math.exp((y_46_im * -Math.atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 3.6e+56) {
tmp = t_2;
} else if (y_46_re <= 7.2e+103) {
tmp = y_46_re * (Math.atan2(x_46_im, x_46_re) + (y_46_re * (Math.atan2(x_46_im, x_46_re) * Math.log(Math.log(Math.exp(Math.hypot(x_46_re, x_46_im)))))));
} else if (y_46_re <= 6.5e+249) {
tmp = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re) * Math.sin((y_46_re * Math.sqrt(Math.pow(Math.atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = Math.pow(Math.pow((Math.pow(x_46_im, y_46_re) * t_1), 3.0), 0.3333333333333333);
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = Float64(y_46_im * atan(x_46_im, x_46_re)) t_1 = sin(Float64(y_46_re * atan(x_46_im, x_46_re))) t_2 = Float64(Float64(1.0 / exp(t_0)) * sin(Float64(y_46_re * Float64(atan(x_46_im, x_46_re) + Float64(y_46_im * Float64(log(hypot(x_46_im, x_46_re)) / y_46_re)))))) tmp = 0.0 if (y_46_re <= -5e-7) tmp = Float64(exp(Float64(Float64(y_46_re * log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))) - t_0)) * t_1); elseif (y_46_re <= -4.3e-169) tmp = t_2; elseif (y_46_re <= 1.12e-97) tmp = Float64(sin(Float64(y_46_im * cbrt((log(hypot(x_46_re, x_46_im)) ^ 3.0)))) * exp(Float64(y_46_im * Float64(-atan(x_46_im, x_46_re))))); elseif (y_46_re <= 3.6e+56) tmp = t_2; elseif (y_46_re <= 7.2e+103) tmp = Float64(y_46_re * Float64(atan(x_46_im, x_46_re) + Float64(y_46_re * Float64(atan(x_46_im, x_46_re) * log(log(exp(hypot(x_46_re, x_46_im)))))))); elseif (y_46_re <= 6.5e+249) tmp = Float64((hypot(x_46_im, x_46_re) ^ y_46_re) * sin(Float64(y_46_re * sqrt((atan(x_46_im, x_46_re) ^ 2.0))))); else tmp = (Float64((x_46_im ^ y_46_re) * t_1) ^ 3.0) ^ 0.3333333333333333; end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[(N[(1.0 / N[Exp[t$95$0], $MachinePrecision]), $MachinePrecision] * N[Sin[N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(y$46$im * N[(N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision] / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -5e-7], N[(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] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$1), $MachinePrecision], If[LessEqual[y$46$re, -4.3e-169], t$95$2, If[LessEqual[y$46$re, 1.12e-97], N[(N[Sin[N[(y$46$im * N[Power[N[Power[N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision], 3.0], $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Exp[N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 3.6e+56], t$95$2, If[LessEqual[y$46$re, 7.2e+103], N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * N[Log[N[Log[N[Exp[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 6.5e+249], N[(N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] * N[Sin[N[(y$46$re * N[Sqrt[N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * t$95$1), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\
t_2 := \frac{1}{e^{t\_0}} \cdot \sin \left(y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} + y.im \cdot \frac{\log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)}{y.re}\right)\right)\\
\mathbf{if}\;y.re \leq -5 \cdot 10^{-7}:\\
\;\;\;\;e^{y.re \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) - t\_0} \cdot t\_1\\
\mathbf{elif}\;y.re \leq -4.3 \cdot 10^{-169}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y.re \leq 1.12 \cdot 10^{-97}:\\
\;\;\;\;\sin \left(y.im \cdot \sqrt[3]{{\log \left(\mathsf{hypot}\left(x.re, x.im\right)\right)}^{3}}\right) \cdot e^{y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)}\\
\mathbf{elif}\;y.re \leq 3.6 \cdot 10^{+56}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y.re \leq 7.2 \cdot 10^{+103}:\\
\;\;\;\;y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} + y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot \log \log \left(e^{\mathsf{hypot}\left(x.re, x.im\right)}\right)\right)\right)\\
\mathbf{elif}\;y.re \leq 6.5 \cdot 10^{+249}:\\
\;\;\;\;{\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re} \cdot \sin \left(y.re \cdot \sqrt{{\tan^{-1}_* \frac{x.im}{x.re}}^{2}}\right)\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot t\_1\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -4.99999999999999977e-7Initial program 41.8%
Taylor expanded in y.im around 0 88.8%
if -4.99999999999999977e-7 < y.re < -4.29999999999999984e-169 or 1.12e-97 < y.re < 3.59999999999999998e56Initial program 38.5%
exp-diff38.5%
exp-to-pow38.5%
hypot-define38.5%
*-commutative38.5%
exp-prod38.3%
fma-define38.3%
hypot-define81.2%
*-commutative81.2%
Simplified81.2%
Taylor expanded in y.re around 0 80.7%
Taylor expanded in y.re around inf 32.7%
+-commutative32.7%
associate-/l*34.1%
unpow234.1%
unpow234.1%
hypot-undefine74.5%
Simplified74.5%
if -4.29999999999999984e-169 < y.re < 1.12e-97Initial program 52.8%
fma-neg52.8%
hypot-define52.8%
distribute-rgt-neg-out52.8%
fma-define52.8%
hypot-define80.1%
*-commutative80.1%
Simplified80.1%
Taylor expanded in y.re around 0 48.8%
*-commutative48.8%
unpow248.8%
unpow248.8%
hypot-undefine72.9%
neg-mul-172.9%
distribute-lft-neg-in72.9%
Simplified72.9%
add-cbrt-cube74.6%
pow376.1%
hypot-undefine50.3%
unpow250.3%
unpow250.3%
+-commutative50.3%
unpow250.3%
unpow250.3%
hypot-undefine76.1%
Applied egg-rr76.1%
if 3.59999999999999998e56 < y.re < 7.20000000000000033e103Initial program 33.3%
fma-neg33.3%
hypot-define33.3%
distribute-rgt-neg-out33.3%
fma-define33.3%
hypot-define53.3%
*-commutative53.3%
Simplified53.3%
Taylor expanded in y.im around 0 40.3%
unpow240.3%
unpow240.3%
hypot-undefine40.3%
Simplified40.3%
Taylor expanded in y.re around 0 22.3%
+-commutative22.3%
unpow222.3%
unpow222.3%
hypot-undefine3.5%
add-log-exp67.0%
Applied egg-rr67.0%
if 7.20000000000000033e103 < y.re < 6.50000000000000028e249Initial program 50.0%
fma-neg50.0%
hypot-define50.0%
distribute-rgt-neg-out50.0%
fma-define50.0%
hypot-define73.3%
*-commutative73.3%
Simplified73.3%
Taylor expanded in y.im around 0 60.1%
unpow260.1%
unpow260.1%
hypot-undefine60.1%
Simplified60.1%
add-sqr-sqrt33.4%
sqrt-unprod80.1%
pow280.1%
Applied egg-rr80.1%
if 6.50000000000000028e249 < y.re Initial program 37.5%
fma-neg37.5%
hypot-define37.5%
distribute-rgt-neg-out37.5%
fma-define37.5%
hypot-define37.5%
*-commutative37.5%
Simplified37.5%
Taylor expanded in y.im around 0 37.5%
unpow237.5%
unpow237.5%
hypot-undefine37.5%
Simplified37.5%
Taylor expanded in x.re around 0 37.7%
add-cbrt-cube37.7%
pow1/387.7%
pow387.7%
*-commutative87.7%
Applied egg-rr87.7%
Final simplification79.2%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.im (atan2 x.im x.re)))
(t_1 (* y.re (atan2 x.im x.re)))
(t_2 (sin t_1)))
(if (<= y.re -6.8e-6)
(*
(exp (- (* y.re (log (sqrt (+ (* x.re x.re) (* x.im x.im))))) t_0))
t_2)
(if (<= y.re 3.4e+57)
(* (sin (fma (log (hypot x.re x.im)) y.im t_1)) (/ 1.0 (exp t_0)))
(if (<= y.re 7.2e+103)
(*
y.re
(+
(atan2 x.im x.re)
(* y.re (* (atan2 x.im x.re) (log (log (exp (hypot x.re x.im))))))))
(if (<= y.re 2.05e+250)
(*
(pow (hypot x.im x.re) y.re)
(sin (* y.re (sqrt (pow (atan2 x.im x.re) 2.0)))))
(pow (pow (* (pow x.im y.re) t_2) 3.0) 0.3333333333333333)))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = y_46_im * atan2(x_46_im, x_46_re);
double t_1 = y_46_re * atan2(x_46_im, x_46_re);
double t_2 = sin(t_1);
double tmp;
if (y_46_re <= -6.8e-6) {
tmp = exp(((y_46_re * log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - t_0)) * t_2;
} else if (y_46_re <= 3.4e+57) {
tmp = sin(fma(log(hypot(x_46_re, x_46_im)), y_46_im, t_1)) * (1.0 / exp(t_0));
} else if (y_46_re <= 7.2e+103) {
tmp = y_46_re * (atan2(x_46_im, x_46_re) + (y_46_re * (atan2(x_46_im, x_46_re) * log(log(exp(hypot(x_46_re, x_46_im)))))));
} else if (y_46_re <= 2.05e+250) {
tmp = pow(hypot(x_46_im, x_46_re), y_46_re) * sin((y_46_re * sqrt(pow(atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * t_2), 3.0), 0.3333333333333333);
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = Float64(y_46_im * atan(x_46_im, x_46_re)) t_1 = Float64(y_46_re * atan(x_46_im, x_46_re)) t_2 = sin(t_1) tmp = 0.0 if (y_46_re <= -6.8e-6) tmp = Float64(exp(Float64(Float64(y_46_re * log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))) - t_0)) * t_2); elseif (y_46_re <= 3.4e+57) tmp = Float64(sin(fma(log(hypot(x_46_re, x_46_im)), y_46_im, t_1)) * Float64(1.0 / exp(t_0))); elseif (y_46_re <= 7.2e+103) tmp = Float64(y_46_re * Float64(atan(x_46_im, x_46_re) + Float64(y_46_re * Float64(atan(x_46_im, x_46_re) * log(log(exp(hypot(x_46_re, x_46_im)))))))); elseif (y_46_re <= 2.05e+250) tmp = Float64((hypot(x_46_im, x_46_re) ^ y_46_re) * sin(Float64(y_46_re * sqrt((atan(x_46_im, x_46_re) ^ 2.0))))); else tmp = (Float64((x_46_im ^ y_46_re) * t_2) ^ 3.0) ^ 0.3333333333333333; end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Sin[t$95$1], $MachinePrecision]}, If[LessEqual[y$46$re, -6.8e-6], N[(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] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$2), $MachinePrecision], If[LessEqual[y$46$re, 3.4e+57], N[(N[Sin[N[(N[Log[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision] * y$46$im + t$95$1), $MachinePrecision]], $MachinePrecision] * N[(1.0 / N[Exp[t$95$0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 7.2e+103], N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * N[Log[N[Log[N[Exp[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 2.05e+250], N[(N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] * N[Sin[N[(y$46$re * N[Sqrt[N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * t$95$2), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_2 := \sin t\_1\\
\mathbf{if}\;y.re \leq -6.8 \cdot 10^{-6}:\\
\;\;\;\;e^{y.re \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) - t\_0} \cdot t\_2\\
\mathbf{elif}\;y.re \leq 3.4 \cdot 10^{+57}:\\
\;\;\;\;\sin \left(\mathsf{fma}\left(\log \left(\mathsf{hypot}\left(x.re, x.im\right)\right), y.im, t\_1\right)\right) \cdot \frac{1}{e^{t\_0}}\\
\mathbf{elif}\;y.re \leq 7.2 \cdot 10^{+103}:\\
\;\;\;\;y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} + y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot \log \log \left(e^{\mathsf{hypot}\left(x.re, x.im\right)}\right)\right)\right)\\
\mathbf{elif}\;y.re \leq 2.05 \cdot 10^{+250}:\\
\;\;\;\;{\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re} \cdot \sin \left(y.re \cdot \sqrt{{\tan^{-1}_* \frac{x.im}{x.re}}^{2}}\right)\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot t\_2\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -6.80000000000000012e-6Initial program 41.8%
Taylor expanded in y.im around 0 88.8%
if -6.80000000000000012e-6 < y.re < 3.39999999999999992e57Initial program 45.7%
exp-diff45.7%
exp-to-pow45.7%
hypot-define45.7%
*-commutative45.7%
exp-prod45.6%
fma-define45.6%
hypot-define80.6%
*-commutative80.6%
Simplified80.6%
Taylor expanded in y.re around 0 80.4%
if 3.39999999999999992e57 < y.re < 7.20000000000000033e103Initial program 33.3%
fma-neg33.3%
hypot-define33.3%
distribute-rgt-neg-out33.3%
fma-define33.3%
hypot-define53.3%
*-commutative53.3%
Simplified53.3%
Taylor expanded in y.im around 0 40.3%
unpow240.3%
unpow240.3%
hypot-undefine40.3%
Simplified40.3%
Taylor expanded in y.re around 0 22.3%
+-commutative22.3%
unpow222.3%
unpow222.3%
hypot-undefine3.5%
add-log-exp67.0%
Applied egg-rr67.0%
if 7.20000000000000033e103 < y.re < 2.05e250Initial program 50.0%
fma-neg50.0%
hypot-define50.0%
distribute-rgt-neg-out50.0%
fma-define50.0%
hypot-define73.3%
*-commutative73.3%
Simplified73.3%
Taylor expanded in y.im around 0 60.1%
unpow260.1%
unpow260.1%
hypot-undefine60.1%
Simplified60.1%
add-sqr-sqrt33.4%
sqrt-unprod80.1%
pow280.1%
Applied egg-rr80.1%
if 2.05e250 < y.re Initial program 37.5%
fma-neg37.5%
hypot-define37.5%
distribute-rgt-neg-out37.5%
fma-define37.5%
hypot-define37.5%
*-commutative37.5%
Simplified37.5%
Taylor expanded in y.im around 0 37.5%
unpow237.5%
unpow237.5%
hypot-undefine37.5%
Simplified37.5%
Taylor expanded in x.re around 0 37.7%
add-cbrt-cube37.7%
pow1/387.7%
pow387.7%
*-commutative87.7%
Applied egg-rr87.7%
Final simplification82.0%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.im (atan2 x.im x.re)))
(t_1 (log (hypot x.im x.re)))
(t_2 (sin (* y.re (atan2 x.im x.re))))
(t_3
(*
(/ 1.0 (exp t_0))
(sin (* y.re (+ (atan2 x.im x.re) (* y.im (/ t_1 y.re))))))))
(if (<= y.re -4.8e-5)
(*
(exp (- (* y.re (log (sqrt (+ (* x.re x.re) (* x.im x.im))))) t_0))
t_2)
(if (<= y.re -1.65e-170)
t_3
(if (<= y.re 9.5e-98)
(* (sin (* y.im t_1)) (exp (* y.im (- (atan2 x.im x.re)))))
(if (<= y.re 1.4e+57)
t_3
(if (<= y.re 7.5e+103)
(*
y.re
(+
(atan2 x.im x.re)
(*
y.re
(* (atan2 x.im x.re) (log (log (exp (hypot x.re x.im))))))))
(if (<= y.re 1.12e+249)
(*
(pow (hypot x.im x.re) y.re)
(sin (* y.re (sqrt (pow (atan2 x.im x.re) 2.0)))))
(pow
(pow (* (pow x.im y.re) t_2) 3.0)
0.3333333333333333)))))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = y_46_im * atan2(x_46_im, x_46_re);
double t_1 = log(hypot(x_46_im, x_46_re));
double t_2 = sin((y_46_re * atan2(x_46_im, x_46_re)));
double t_3 = (1.0 / exp(t_0)) * sin((y_46_re * (atan2(x_46_im, x_46_re) + (y_46_im * (t_1 / y_46_re)))));
double tmp;
if (y_46_re <= -4.8e-5) {
tmp = exp(((y_46_re * log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - t_0)) * t_2;
} else if (y_46_re <= -1.65e-170) {
tmp = t_3;
} else if (y_46_re <= 9.5e-98) {
tmp = sin((y_46_im * t_1)) * exp((y_46_im * -atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 1.4e+57) {
tmp = t_3;
} else if (y_46_re <= 7.5e+103) {
tmp = y_46_re * (atan2(x_46_im, x_46_re) + (y_46_re * (atan2(x_46_im, x_46_re) * log(log(exp(hypot(x_46_re, x_46_im)))))));
} else if (y_46_re <= 1.12e+249) {
tmp = pow(hypot(x_46_im, x_46_re), y_46_re) * sin((y_46_re * sqrt(pow(atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * t_2), 3.0), 0.3333333333333333);
}
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_im * Math.atan2(x_46_im, x_46_re);
double t_1 = Math.log(Math.hypot(x_46_im, x_46_re));
double t_2 = Math.sin((y_46_re * Math.atan2(x_46_im, x_46_re)));
double t_3 = (1.0 / Math.exp(t_0)) * Math.sin((y_46_re * (Math.atan2(x_46_im, x_46_re) + (y_46_im * (t_1 / y_46_re)))));
double tmp;
if (y_46_re <= -4.8e-5) {
tmp = Math.exp(((y_46_re * Math.log(Math.sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - t_0)) * t_2;
} else if (y_46_re <= -1.65e-170) {
tmp = t_3;
} else if (y_46_re <= 9.5e-98) {
tmp = Math.sin((y_46_im * t_1)) * Math.exp((y_46_im * -Math.atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 1.4e+57) {
tmp = t_3;
} else if (y_46_re <= 7.5e+103) {
tmp = y_46_re * (Math.atan2(x_46_im, x_46_re) + (y_46_re * (Math.atan2(x_46_im, x_46_re) * Math.log(Math.log(Math.exp(Math.hypot(x_46_re, x_46_im)))))));
} else if (y_46_re <= 1.12e+249) {
tmp = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re) * Math.sin((y_46_re * Math.sqrt(Math.pow(Math.atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = Math.pow(Math.pow((Math.pow(x_46_im, y_46_re) * t_2), 3.0), 0.3333333333333333);
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): t_0 = y_46_im * math.atan2(x_46_im, x_46_re) t_1 = math.log(math.hypot(x_46_im, x_46_re)) t_2 = math.sin((y_46_re * math.atan2(x_46_im, x_46_re))) t_3 = (1.0 / math.exp(t_0)) * math.sin((y_46_re * (math.atan2(x_46_im, x_46_re) + (y_46_im * (t_1 / y_46_re))))) tmp = 0 if y_46_re <= -4.8e-5: tmp = math.exp(((y_46_re * math.log(math.sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - t_0)) * t_2 elif y_46_re <= -1.65e-170: tmp = t_3 elif y_46_re <= 9.5e-98: tmp = math.sin((y_46_im * t_1)) * math.exp((y_46_im * -math.atan2(x_46_im, x_46_re))) elif y_46_re <= 1.4e+57: tmp = t_3 elif y_46_re <= 7.5e+103: tmp = y_46_re * (math.atan2(x_46_im, x_46_re) + (y_46_re * (math.atan2(x_46_im, x_46_re) * math.log(math.log(math.exp(math.hypot(x_46_re, x_46_im))))))) elif y_46_re <= 1.12e+249: tmp = math.pow(math.hypot(x_46_im, x_46_re), y_46_re) * math.sin((y_46_re * math.sqrt(math.pow(math.atan2(x_46_im, x_46_re), 2.0)))) else: tmp = math.pow(math.pow((math.pow(x_46_im, y_46_re) * t_2), 3.0), 0.3333333333333333) return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = Float64(y_46_im * atan(x_46_im, x_46_re)) t_1 = log(hypot(x_46_im, x_46_re)) t_2 = sin(Float64(y_46_re * atan(x_46_im, x_46_re))) t_3 = Float64(Float64(1.0 / exp(t_0)) * sin(Float64(y_46_re * Float64(atan(x_46_im, x_46_re) + Float64(y_46_im * Float64(t_1 / y_46_re)))))) tmp = 0.0 if (y_46_re <= -4.8e-5) tmp = Float64(exp(Float64(Float64(y_46_re * log(sqrt(Float64(Float64(x_46_re * x_46_re) + Float64(x_46_im * x_46_im))))) - t_0)) * t_2); elseif (y_46_re <= -1.65e-170) tmp = t_3; elseif (y_46_re <= 9.5e-98) tmp = Float64(sin(Float64(y_46_im * t_1)) * exp(Float64(y_46_im * Float64(-atan(x_46_im, x_46_re))))); elseif (y_46_re <= 1.4e+57) tmp = t_3; elseif (y_46_re <= 7.5e+103) tmp = Float64(y_46_re * Float64(atan(x_46_im, x_46_re) + Float64(y_46_re * Float64(atan(x_46_im, x_46_re) * log(log(exp(hypot(x_46_re, x_46_im)))))))); elseif (y_46_re <= 1.12e+249) tmp = Float64((hypot(x_46_im, x_46_re) ^ y_46_re) * sin(Float64(y_46_re * sqrt((atan(x_46_im, x_46_re) ^ 2.0))))); else tmp = (Float64((x_46_im ^ y_46_re) * t_2) ^ 3.0) ^ 0.3333333333333333; end return tmp end
function tmp_2 = code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = y_46_im * atan2(x_46_im, x_46_re); t_1 = log(hypot(x_46_im, x_46_re)); t_2 = sin((y_46_re * atan2(x_46_im, x_46_re))); t_3 = (1.0 / exp(t_0)) * sin((y_46_re * (atan2(x_46_im, x_46_re) + (y_46_im * (t_1 / y_46_re))))); tmp = 0.0; if (y_46_re <= -4.8e-5) tmp = exp(((y_46_re * log(sqrt(((x_46_re * x_46_re) + (x_46_im * x_46_im))))) - t_0)) * t_2; elseif (y_46_re <= -1.65e-170) tmp = t_3; elseif (y_46_re <= 9.5e-98) tmp = sin((y_46_im * t_1)) * exp((y_46_im * -atan2(x_46_im, x_46_re))); elseif (y_46_re <= 1.4e+57) tmp = t_3; elseif (y_46_re <= 7.5e+103) tmp = y_46_re * (atan2(x_46_im, x_46_re) + (y_46_re * (atan2(x_46_im, x_46_re) * log(log(exp(hypot(x_46_re, x_46_im))))))); elseif (y_46_re <= 1.12e+249) tmp = (hypot(x_46_im, x_46_re) ^ y_46_re) * sin((y_46_re * sqrt((atan2(x_46_im, x_46_re) ^ 2.0)))); else tmp = (((x_46_im ^ y_46_re) * t_2) ^ 3.0) ^ 0.3333333333333333; 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$im * 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[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[(N[(1.0 / N[Exp[t$95$0], $MachinePrecision]), $MachinePrecision] * N[Sin[N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(y$46$im * N[(t$95$1 / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -4.8e-5], N[(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] - t$95$0), $MachinePrecision]], $MachinePrecision] * t$95$2), $MachinePrecision], If[LessEqual[y$46$re, -1.65e-170], t$95$3, If[LessEqual[y$46$re, 9.5e-98], N[(N[Sin[N[(y$46$im * t$95$1), $MachinePrecision]], $MachinePrecision] * N[Exp[N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 1.4e+57], t$95$3, If[LessEqual[y$46$re, 7.5e+103], N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * N[Log[N[Log[N[Exp[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 1.12e+249], N[(N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] * N[Sin[N[(y$46$re * N[Sqrt[N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * t$95$2), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\\
t_2 := \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\
t_3 := \frac{1}{e^{t\_0}} \cdot \sin \left(y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} + y.im \cdot \frac{t\_1}{y.re}\right)\right)\\
\mathbf{if}\;y.re \leq -4.8 \cdot 10^{-5}:\\
\;\;\;\;e^{y.re \cdot \log \left(\sqrt{x.re \cdot x.re + x.im \cdot x.im}\right) - t\_0} \cdot t\_2\\
\mathbf{elif}\;y.re \leq -1.65 \cdot 10^{-170}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;y.re \leq 9.5 \cdot 10^{-98}:\\
\;\;\;\;\sin \left(y.im \cdot t\_1\right) \cdot e^{y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)}\\
\mathbf{elif}\;y.re \leq 1.4 \cdot 10^{+57}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;y.re \leq 7.5 \cdot 10^{+103}:\\
\;\;\;\;y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} + y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot \log \log \left(e^{\mathsf{hypot}\left(x.re, x.im\right)}\right)\right)\right)\\
\mathbf{elif}\;y.re \leq 1.12 \cdot 10^{+249}:\\
\;\;\;\;{\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re} \cdot \sin \left(y.re \cdot \sqrt{{\tan^{-1}_* \frac{x.im}{x.re}}^{2}}\right)\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot t\_2\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -4.8000000000000001e-5Initial program 41.8%
Taylor expanded in y.im around 0 88.8%
if -4.8000000000000001e-5 < y.re < -1.65000000000000002e-170 or 9.5000000000000001e-98 < y.re < 1.4e57Initial program 38.5%
exp-diff38.5%
exp-to-pow38.5%
hypot-define38.5%
*-commutative38.5%
exp-prod38.3%
fma-define38.3%
hypot-define81.2%
*-commutative81.2%
Simplified81.2%
Taylor expanded in y.re around 0 80.7%
Taylor expanded in y.re around inf 32.7%
+-commutative32.7%
associate-/l*34.1%
unpow234.1%
unpow234.1%
hypot-undefine74.5%
Simplified74.5%
if -1.65000000000000002e-170 < y.re < 9.5000000000000001e-98Initial program 52.8%
fma-neg52.8%
hypot-define52.8%
distribute-rgt-neg-out52.8%
fma-define52.8%
hypot-define80.1%
*-commutative80.1%
Simplified80.1%
Taylor expanded in y.re around 0 48.8%
*-commutative48.8%
unpow248.8%
unpow248.8%
hypot-undefine72.9%
neg-mul-172.9%
distribute-lft-neg-in72.9%
Simplified72.9%
if 1.4e57 < y.re < 7.49999999999999922e103Initial program 33.3%
fma-neg33.3%
hypot-define33.3%
distribute-rgt-neg-out33.3%
fma-define33.3%
hypot-define53.3%
*-commutative53.3%
Simplified53.3%
Taylor expanded in y.im around 0 40.3%
unpow240.3%
unpow240.3%
hypot-undefine40.3%
Simplified40.3%
Taylor expanded in y.re around 0 22.3%
+-commutative22.3%
unpow222.3%
unpow222.3%
hypot-undefine3.5%
add-log-exp67.0%
Applied egg-rr67.0%
if 7.49999999999999922e103 < y.re < 1.1200000000000001e249Initial program 50.0%
fma-neg50.0%
hypot-define50.0%
distribute-rgt-neg-out50.0%
fma-define50.0%
hypot-define73.3%
*-commutative73.3%
Simplified73.3%
Taylor expanded in y.im around 0 60.1%
unpow260.1%
unpow260.1%
hypot-undefine60.1%
Simplified60.1%
add-sqr-sqrt33.4%
sqrt-unprod80.1%
pow280.1%
Applied egg-rr80.1%
if 1.1200000000000001e249 < y.re Initial program 37.5%
fma-neg37.5%
hypot-define37.5%
distribute-rgt-neg-out37.5%
fma-define37.5%
hypot-define37.5%
*-commutative37.5%
Simplified37.5%
Taylor expanded in y.im around 0 37.5%
unpow237.5%
unpow237.5%
hypot-undefine37.5%
Simplified37.5%
Taylor expanded in x.re around 0 37.7%
add-cbrt-cube37.7%
pow1/387.7%
pow387.7%
*-commutative87.7%
Applied egg-rr87.7%
Final simplification78.4%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (log (hypot x.im x.re)))
(t_1
(*
(/ 1.0 (exp (* y.im (atan2 x.im x.re))))
(sin (* y.re (+ (atan2 x.im x.re) (* y.im (/ t_0 y.re)))))))
(t_2 (pow (hypot x.im x.re) y.re))
(t_3 (sin (* y.re (atan2 x.im x.re)))))
(if (<= y.re -0.00015)
(* t_2 (sqrt (pow t_3 2.0)))
(if (<= y.re -9e-173)
t_1
(if (<= y.re 3.7e-97)
(* (sin (* y.im t_0)) (exp (* y.im (- (atan2 x.im x.re)))))
(if (<= y.re 8.3e+55)
t_1
(if (<= y.re 7.2e+103)
(*
y.re
(+
(atan2 x.im x.re)
(*
y.re
(* (atan2 x.im x.re) (log (log (exp (hypot x.re x.im))))))))
(if (<= y.re 1.06e+250)
(* t_2 (sin (* y.re (sqrt (pow (atan2 x.im x.re) 2.0)))))
(pow
(pow (* (pow x.im y.re) t_3) 3.0)
0.3333333333333333)))))))))
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 = (1.0 / exp((y_46_im * atan2(x_46_im, x_46_re)))) * sin((y_46_re * (atan2(x_46_im, x_46_re) + (y_46_im * (t_0 / y_46_re)))));
double t_2 = pow(hypot(x_46_im, x_46_re), y_46_re);
double t_3 = sin((y_46_re * atan2(x_46_im, x_46_re)));
double tmp;
if (y_46_re <= -0.00015) {
tmp = t_2 * sqrt(pow(t_3, 2.0));
} else if (y_46_re <= -9e-173) {
tmp = t_1;
} else if (y_46_re <= 3.7e-97) {
tmp = sin((y_46_im * t_0)) * exp((y_46_im * -atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 8.3e+55) {
tmp = t_1;
} else if (y_46_re <= 7.2e+103) {
tmp = y_46_re * (atan2(x_46_im, x_46_re) + (y_46_re * (atan2(x_46_im, x_46_re) * log(log(exp(hypot(x_46_re, x_46_im)))))));
} else if (y_46_re <= 1.06e+250) {
tmp = t_2 * sin((y_46_re * sqrt(pow(atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * t_3), 3.0), 0.3333333333333333);
}
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 = Math.log(Math.hypot(x_46_im, x_46_re));
double t_1 = (1.0 / Math.exp((y_46_im * Math.atan2(x_46_im, x_46_re)))) * Math.sin((y_46_re * (Math.atan2(x_46_im, x_46_re) + (y_46_im * (t_0 / y_46_re)))));
double t_2 = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re);
double t_3 = Math.sin((y_46_re * Math.atan2(x_46_im, x_46_re)));
double tmp;
if (y_46_re <= -0.00015) {
tmp = t_2 * Math.sqrt(Math.pow(t_3, 2.0));
} else if (y_46_re <= -9e-173) {
tmp = t_1;
} else if (y_46_re <= 3.7e-97) {
tmp = Math.sin((y_46_im * t_0)) * Math.exp((y_46_im * -Math.atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 8.3e+55) {
tmp = t_1;
} else if (y_46_re <= 7.2e+103) {
tmp = y_46_re * (Math.atan2(x_46_im, x_46_re) + (y_46_re * (Math.atan2(x_46_im, x_46_re) * Math.log(Math.log(Math.exp(Math.hypot(x_46_re, x_46_im)))))));
} else if (y_46_re <= 1.06e+250) {
tmp = t_2 * Math.sin((y_46_re * Math.sqrt(Math.pow(Math.atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = Math.pow(Math.pow((Math.pow(x_46_im, y_46_re) * t_3), 3.0), 0.3333333333333333);
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): t_0 = math.log(math.hypot(x_46_im, x_46_re)) t_1 = (1.0 / math.exp((y_46_im * math.atan2(x_46_im, x_46_re)))) * math.sin((y_46_re * (math.atan2(x_46_im, x_46_re) + (y_46_im * (t_0 / y_46_re))))) t_2 = math.pow(math.hypot(x_46_im, x_46_re), y_46_re) t_3 = math.sin((y_46_re * math.atan2(x_46_im, x_46_re))) tmp = 0 if y_46_re <= -0.00015: tmp = t_2 * math.sqrt(math.pow(t_3, 2.0)) elif y_46_re <= -9e-173: tmp = t_1 elif y_46_re <= 3.7e-97: tmp = math.sin((y_46_im * t_0)) * math.exp((y_46_im * -math.atan2(x_46_im, x_46_re))) elif y_46_re <= 8.3e+55: tmp = t_1 elif y_46_re <= 7.2e+103: tmp = y_46_re * (math.atan2(x_46_im, x_46_re) + (y_46_re * (math.atan2(x_46_im, x_46_re) * math.log(math.log(math.exp(math.hypot(x_46_re, x_46_im))))))) elif y_46_re <= 1.06e+250: tmp = t_2 * math.sin((y_46_re * math.sqrt(math.pow(math.atan2(x_46_im, x_46_re), 2.0)))) else: tmp = math.pow(math.pow((math.pow(x_46_im, y_46_re) * t_3), 3.0), 0.3333333333333333) 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(Float64(1.0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))) * sin(Float64(y_46_re * Float64(atan(x_46_im, x_46_re) + Float64(y_46_im * Float64(t_0 / y_46_re)))))) t_2 = hypot(x_46_im, x_46_re) ^ y_46_re t_3 = sin(Float64(y_46_re * atan(x_46_im, x_46_re))) tmp = 0.0 if (y_46_re <= -0.00015) tmp = Float64(t_2 * sqrt((t_3 ^ 2.0))); elseif (y_46_re <= -9e-173) tmp = t_1; elseif (y_46_re <= 3.7e-97) tmp = Float64(sin(Float64(y_46_im * t_0)) * exp(Float64(y_46_im * Float64(-atan(x_46_im, x_46_re))))); elseif (y_46_re <= 8.3e+55) tmp = t_1; elseif (y_46_re <= 7.2e+103) tmp = Float64(y_46_re * Float64(atan(x_46_im, x_46_re) + Float64(y_46_re * Float64(atan(x_46_im, x_46_re) * log(log(exp(hypot(x_46_re, x_46_im)))))))); elseif (y_46_re <= 1.06e+250) tmp = Float64(t_2 * sin(Float64(y_46_re * sqrt((atan(x_46_im, x_46_re) ^ 2.0))))); else tmp = (Float64((x_46_im ^ y_46_re) * t_3) ^ 3.0) ^ 0.3333333333333333; end return tmp end
function tmp_2 = 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 = (1.0 / exp((y_46_im * atan2(x_46_im, x_46_re)))) * sin((y_46_re * (atan2(x_46_im, x_46_re) + (y_46_im * (t_0 / y_46_re))))); t_2 = hypot(x_46_im, x_46_re) ^ y_46_re; t_3 = sin((y_46_re * atan2(x_46_im, x_46_re))); tmp = 0.0; if (y_46_re <= -0.00015) tmp = t_2 * sqrt((t_3 ^ 2.0)); elseif (y_46_re <= -9e-173) tmp = t_1; elseif (y_46_re <= 3.7e-97) tmp = sin((y_46_im * t_0)) * exp((y_46_im * -atan2(x_46_im, x_46_re))); elseif (y_46_re <= 8.3e+55) tmp = t_1; elseif (y_46_re <= 7.2e+103) tmp = y_46_re * (atan2(x_46_im, x_46_re) + (y_46_re * (atan2(x_46_im, x_46_re) * log(log(exp(hypot(x_46_re, x_46_im))))))); elseif (y_46_re <= 1.06e+250) tmp = t_2 * sin((y_46_re * sqrt((atan2(x_46_im, x_46_re) ^ 2.0)))); else tmp = (((x_46_im ^ y_46_re) * t_3) ^ 3.0) ^ 0.3333333333333333; end tmp_2 = 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[(N[(1.0 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Sin[N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(y$46$im * N[(t$95$0 / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]}, Block[{t$95$3 = N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[y$46$re, -0.00015], N[(t$95$2 * N[Sqrt[N[Power[t$95$3, 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, -9e-173], t$95$1, If[LessEqual[y$46$re, 3.7e-97], N[(N[Sin[N[(y$46$im * t$95$0), $MachinePrecision]], $MachinePrecision] * N[Exp[N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 8.3e+55], t$95$1, If[LessEqual[y$46$re, 7.2e+103], N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] + N[(y$46$re * N[(N[ArcTan[x$46$im / x$46$re], $MachinePrecision] * N[Log[N[Log[N[Exp[N[Sqrt[x$46$re ^ 2 + x$46$im ^ 2], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 1.06e+250], N[(t$95$2 * N[Sin[N[(y$46$re * N[Sqrt[N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * t$95$3), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\\
t_1 := \frac{1}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} + y.im \cdot \frac{t\_0}{y.re}\right)\right)\\
t_2 := {\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re}\\
t_3 := \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\
\mathbf{if}\;y.re \leq -0.00015:\\
\;\;\;\;t\_2 \cdot \sqrt{{t\_3}^{2}}\\
\mathbf{elif}\;y.re \leq -9 \cdot 10^{-173}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y.re \leq 3.7 \cdot 10^{-97}:\\
\;\;\;\;\sin \left(y.im \cdot t\_0\right) \cdot e^{y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)}\\
\mathbf{elif}\;y.re \leq 8.3 \cdot 10^{+55}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y.re \leq 7.2 \cdot 10^{+103}:\\
\;\;\;\;y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} + y.re \cdot \left(\tan^{-1}_* \frac{x.im}{x.re} \cdot \log \log \left(e^{\mathsf{hypot}\left(x.re, x.im\right)}\right)\right)\right)\\
\mathbf{elif}\;y.re \leq 1.06 \cdot 10^{+250}:\\
\;\;\;\;t\_2 \cdot \sin \left(y.re \cdot \sqrt{{\tan^{-1}_* \frac{x.im}{x.re}}^{2}}\right)\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot t\_3\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -1.49999999999999987e-4Initial program 41.8%
fma-neg41.8%
hypot-define42.4%
distribute-rgt-neg-out42.4%
fma-define42.4%
hypot-define89.4%
*-commutative89.4%
Simplified89.4%
Taylor expanded in y.im around 0 84.3%
unpow284.3%
unpow284.3%
hypot-undefine84.9%
Simplified84.9%
add-sqr-sqrt50.0%
sqrt-unprod87.9%
pow287.9%
*-commutative87.9%
Applied egg-rr87.9%
if -1.49999999999999987e-4 < y.re < -9.00000000000000037e-173 or 3.69999999999999976e-97 < y.re < 8.30000000000000048e55Initial program 38.5%
exp-diff38.5%
exp-to-pow38.5%
hypot-define38.5%
*-commutative38.5%
exp-prod38.3%
fma-define38.3%
hypot-define81.2%
*-commutative81.2%
Simplified81.2%
Taylor expanded in y.re around 0 80.7%
Taylor expanded in y.re around inf 32.7%
+-commutative32.7%
associate-/l*34.1%
unpow234.1%
unpow234.1%
hypot-undefine74.5%
Simplified74.5%
if -9.00000000000000037e-173 < y.re < 3.69999999999999976e-97Initial program 52.8%
fma-neg52.8%
hypot-define52.8%
distribute-rgt-neg-out52.8%
fma-define52.8%
hypot-define80.1%
*-commutative80.1%
Simplified80.1%
Taylor expanded in y.re around 0 48.8%
*-commutative48.8%
unpow248.8%
unpow248.8%
hypot-undefine72.9%
neg-mul-172.9%
distribute-lft-neg-in72.9%
Simplified72.9%
if 8.30000000000000048e55 < y.re < 7.20000000000000033e103Initial program 33.3%
fma-neg33.3%
hypot-define33.3%
distribute-rgt-neg-out33.3%
fma-define33.3%
hypot-define53.3%
*-commutative53.3%
Simplified53.3%
Taylor expanded in y.im around 0 40.3%
unpow240.3%
unpow240.3%
hypot-undefine40.3%
Simplified40.3%
Taylor expanded in y.re around 0 22.3%
+-commutative22.3%
unpow222.3%
unpow222.3%
hypot-undefine3.5%
add-log-exp67.0%
Applied egg-rr67.0%
if 7.20000000000000033e103 < y.re < 1.06000000000000008e250Initial program 50.0%
fma-neg50.0%
hypot-define50.0%
distribute-rgt-neg-out50.0%
fma-define50.0%
hypot-define73.3%
*-commutative73.3%
Simplified73.3%
Taylor expanded in y.im around 0 60.1%
unpow260.1%
unpow260.1%
hypot-undefine60.1%
Simplified60.1%
add-sqr-sqrt33.4%
sqrt-unprod80.1%
pow280.1%
Applied egg-rr80.1%
if 1.06000000000000008e250 < y.re Initial program 37.5%
fma-neg37.5%
hypot-define37.5%
distribute-rgt-neg-out37.5%
fma-define37.5%
hypot-define37.5%
*-commutative37.5%
Simplified37.5%
Taylor expanded in y.im around 0 37.5%
unpow237.5%
unpow237.5%
hypot-undefine37.5%
Simplified37.5%
Taylor expanded in x.re around 0 37.7%
add-cbrt-cube37.7%
pow1/387.7%
pow387.7%
*-commutative87.7%
Applied egg-rr87.7%
Final simplification78.2%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (pow (hypot x.im x.re) y.re))
(t_1 (sin (* y.re (atan2 x.im x.re)))))
(if (<= y.re -0.00165)
(* t_0 (sqrt (pow t_1 2.0)))
(if (<= y.re 2.5e-42)
(*
(* y.im (log (hypot x.im x.re)))
(exp (* y.im (- (atan2 x.im x.re)))))
(if (<= y.re 7.5e+250)
(* t_0 (sin (* y.re (sqrt (pow (atan2 x.im x.re) 2.0)))))
(pow (pow (* (pow x.im y.re) t_1) 3.0) 0.3333333333333333))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = pow(hypot(x_46_im, x_46_re), y_46_re);
double t_1 = sin((y_46_re * atan2(x_46_im, x_46_re)));
double tmp;
if (y_46_re <= -0.00165) {
tmp = t_0 * sqrt(pow(t_1, 2.0));
} else if (y_46_re <= 2.5e-42) {
tmp = (y_46_im * log(hypot(x_46_im, x_46_re))) * exp((y_46_im * -atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 7.5e+250) {
tmp = t_0 * sin((y_46_re * sqrt(pow(atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * t_1), 3.0), 0.3333333333333333);
}
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 = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re);
double t_1 = Math.sin((y_46_re * Math.atan2(x_46_im, x_46_re)));
double tmp;
if (y_46_re <= -0.00165) {
tmp = t_0 * Math.sqrt(Math.pow(t_1, 2.0));
} else if (y_46_re <= 2.5e-42) {
tmp = (y_46_im * Math.log(Math.hypot(x_46_im, x_46_re))) * Math.exp((y_46_im * -Math.atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 7.5e+250) {
tmp = t_0 * Math.sin((y_46_re * Math.sqrt(Math.pow(Math.atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = Math.pow(Math.pow((Math.pow(x_46_im, y_46_re) * t_1), 3.0), 0.3333333333333333);
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): t_0 = math.pow(math.hypot(x_46_im, x_46_re), y_46_re) t_1 = math.sin((y_46_re * math.atan2(x_46_im, x_46_re))) tmp = 0 if y_46_re <= -0.00165: tmp = t_0 * math.sqrt(math.pow(t_1, 2.0)) elif y_46_re <= 2.5e-42: tmp = (y_46_im * math.log(math.hypot(x_46_im, x_46_re))) * math.exp((y_46_im * -math.atan2(x_46_im, x_46_re))) elif y_46_re <= 7.5e+250: tmp = t_0 * math.sin((y_46_re * math.sqrt(math.pow(math.atan2(x_46_im, x_46_re), 2.0)))) else: tmp = math.pow(math.pow((math.pow(x_46_im, y_46_re) * t_1), 3.0), 0.3333333333333333) return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = hypot(x_46_im, x_46_re) ^ y_46_re t_1 = sin(Float64(y_46_re * atan(x_46_im, x_46_re))) tmp = 0.0 if (y_46_re <= -0.00165) tmp = Float64(t_0 * sqrt((t_1 ^ 2.0))); elseif (y_46_re <= 2.5e-42) tmp = Float64(Float64(y_46_im * log(hypot(x_46_im, x_46_re))) * exp(Float64(y_46_im * Float64(-atan(x_46_im, x_46_re))))); elseif (y_46_re <= 7.5e+250) tmp = Float64(t_0 * sin(Float64(y_46_re * sqrt((atan(x_46_im, x_46_re) ^ 2.0))))); else tmp = (Float64((x_46_im ^ y_46_re) * t_1) ^ 3.0) ^ 0.3333333333333333; end return tmp end
function tmp_2 = code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = hypot(x_46_im, x_46_re) ^ y_46_re; t_1 = sin((y_46_re * atan2(x_46_im, x_46_re))); tmp = 0.0; if (y_46_re <= -0.00165) tmp = t_0 * sqrt((t_1 ^ 2.0)); elseif (y_46_re <= 2.5e-42) tmp = (y_46_im * log(hypot(x_46_im, x_46_re))) * exp((y_46_im * -atan2(x_46_im, x_46_re))); elseif (y_46_re <= 7.5e+250) tmp = t_0 * sin((y_46_re * sqrt((atan2(x_46_im, x_46_re) ^ 2.0)))); else tmp = (((x_46_im ^ y_46_re) * t_1) ^ 3.0) ^ 0.3333333333333333; end tmp_2 = tmp; end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]}, Block[{t$95$1 = N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[y$46$re, -0.00165], N[(t$95$0 * N[Sqrt[N[Power[t$95$1, 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 2.5e-42], N[(N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Exp[N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 7.5e+250], N[(t$95$0 * N[Sin[N[(y$46$re * N[Sqrt[N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * t$95$1), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := {\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re}\\
t_1 := \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\
\mathbf{if}\;y.re \leq -0.00165:\\
\;\;\;\;t\_0 \cdot \sqrt{{t\_1}^{2}}\\
\mathbf{elif}\;y.re \leq 2.5 \cdot 10^{-42}:\\
\;\;\;\;\left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right) \cdot e^{y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)}\\
\mathbf{elif}\;y.re \leq 7.5 \cdot 10^{+250}:\\
\;\;\;\;t\_0 \cdot \sin \left(y.re \cdot \sqrt{{\tan^{-1}_* \frac{x.im}{x.re}}^{2}}\right)\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot t\_1\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -0.00165Initial program 42.4%
fma-neg42.4%
hypot-define43.0%
distribute-rgt-neg-out43.0%
fma-define43.0%
hypot-define90.7%
*-commutative90.7%
Simplified90.7%
Taylor expanded in y.im around 0 85.6%
unpow285.6%
unpow285.6%
hypot-undefine86.2%
Simplified86.2%
add-sqr-sqrt50.8%
sqrt-unprod89.3%
pow289.3%
*-commutative89.3%
Applied egg-rr89.3%
if -0.00165 < y.re < 2.50000000000000001e-42Initial program 45.3%
fma-neg45.3%
hypot-define45.3%
distribute-rgt-neg-out45.3%
fma-define45.3%
hypot-define80.7%
*-commutative80.7%
Simplified80.7%
Taylor expanded in y.re around 0 37.5%
*-commutative37.5%
unpow237.5%
unpow237.5%
hypot-undefine63.5%
neg-mul-163.5%
distribute-lft-neg-in63.5%
Simplified63.5%
Taylor expanded in y.im around 0 41.3%
unpow241.3%
unpow241.3%
hypot-undefine63.6%
Simplified63.6%
if 2.50000000000000001e-42 < y.re < 7.4999999999999997e250Initial program 45.0%
fma-neg45.0%
hypot-define45.0%
distribute-rgt-neg-out45.0%
fma-define45.0%
hypot-define71.7%
*-commutative71.7%
Simplified71.7%
Taylor expanded in y.im around 0 50.4%
unpow250.4%
unpow250.4%
hypot-undefine55.2%
Simplified55.2%
add-sqr-sqrt36.7%
sqrt-unprod65.2%
pow265.2%
Applied egg-rr65.2%
if 7.4999999999999997e250 < y.re Initial program 37.5%
fma-neg37.5%
hypot-define37.5%
distribute-rgt-neg-out37.5%
fma-define37.5%
hypot-define37.5%
*-commutative37.5%
Simplified37.5%
Taylor expanded in y.im around 0 37.5%
unpow237.5%
unpow237.5%
hypot-undefine37.5%
Simplified37.5%
Taylor expanded in x.re around 0 37.7%
add-cbrt-cube37.7%
pow1/387.7%
pow387.7%
*-commutative87.7%
Applied egg-rr87.7%
Final simplification71.2%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (pow (hypot x.im x.re) y.re)))
(if (<= y.re -0.00092)
(* t_0 (sin (* y.re (log1p (expm1 (atan2 x.im x.re))))))
(if (<= y.re 7.2e-43)
(*
(* y.im (log (hypot x.im x.re)))
(exp (* y.im (- (atan2 x.im x.re)))))
(if (<= y.re 3.7e+249)
(* t_0 (sin (* y.re (sqrt (pow (atan2 x.im x.re) 2.0)))))
(pow
(pow (* (pow x.im y.re) (sin (* y.re (atan2 x.im x.re)))) 3.0)
0.3333333333333333))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = pow(hypot(x_46_im, x_46_re), y_46_re);
double tmp;
if (y_46_re <= -0.00092) {
tmp = t_0 * sin((y_46_re * log1p(expm1(atan2(x_46_im, x_46_re)))));
} else if (y_46_re <= 7.2e-43) {
tmp = (y_46_im * log(hypot(x_46_im, x_46_re))) * exp((y_46_im * -atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 3.7e+249) {
tmp = t_0 * sin((y_46_re * sqrt(pow(atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * sin((y_46_re * atan2(x_46_im, x_46_re)))), 3.0), 0.3333333333333333);
}
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 = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re);
double tmp;
if (y_46_re <= -0.00092) {
tmp = t_0 * Math.sin((y_46_re * Math.log1p(Math.expm1(Math.atan2(x_46_im, x_46_re)))));
} else if (y_46_re <= 7.2e-43) {
tmp = (y_46_im * Math.log(Math.hypot(x_46_im, x_46_re))) * Math.exp((y_46_im * -Math.atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 3.7e+249) {
tmp = t_0 * Math.sin((y_46_re * Math.sqrt(Math.pow(Math.atan2(x_46_im, x_46_re), 2.0))));
} else {
tmp = Math.pow(Math.pow((Math.pow(x_46_im, y_46_re) * Math.sin((y_46_re * Math.atan2(x_46_im, x_46_re)))), 3.0), 0.3333333333333333);
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): t_0 = math.pow(math.hypot(x_46_im, x_46_re), y_46_re) tmp = 0 if y_46_re <= -0.00092: tmp = t_0 * math.sin((y_46_re * math.log1p(math.expm1(math.atan2(x_46_im, x_46_re))))) elif y_46_re <= 7.2e-43: tmp = (y_46_im * math.log(math.hypot(x_46_im, x_46_re))) * math.exp((y_46_im * -math.atan2(x_46_im, x_46_re))) elif y_46_re <= 3.7e+249: tmp = t_0 * math.sin((y_46_re * math.sqrt(math.pow(math.atan2(x_46_im, x_46_re), 2.0)))) else: tmp = math.pow(math.pow((math.pow(x_46_im, y_46_re) * math.sin((y_46_re * math.atan2(x_46_im, x_46_re)))), 3.0), 0.3333333333333333) return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = hypot(x_46_im, x_46_re) ^ y_46_re tmp = 0.0 if (y_46_re <= -0.00092) tmp = Float64(t_0 * sin(Float64(y_46_re * log1p(expm1(atan(x_46_im, x_46_re)))))); elseif (y_46_re <= 7.2e-43) tmp = Float64(Float64(y_46_im * log(hypot(x_46_im, x_46_re))) * exp(Float64(y_46_im * Float64(-atan(x_46_im, x_46_re))))); elseif (y_46_re <= 3.7e+249) tmp = Float64(t_0 * sin(Float64(y_46_re * sqrt((atan(x_46_im, x_46_re) ^ 2.0))))); else tmp = (Float64((x_46_im ^ y_46_re) * sin(Float64(y_46_re * atan(x_46_im, x_46_re)))) ^ 3.0) ^ 0.3333333333333333; end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision]}, If[LessEqual[y$46$re, -0.00092], N[(t$95$0 * N[Sin[N[(y$46$re * N[Log[1 + N[(Exp[N[ArcTan[x$46$im / x$46$re], $MachinePrecision]] - 1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 7.2e-43], N[(N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Exp[N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 3.7e+249], N[(t$95$0 * N[Sin[N[(y$46$re * N[Sqrt[N[Power[N[ArcTan[x$46$im / x$46$re], $MachinePrecision], 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := {\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re}\\
\mathbf{if}\;y.re \leq -0.00092:\\
\;\;\;\;t\_0 \cdot \sin \left(y.re \cdot \mathsf{log1p}\left(\mathsf{expm1}\left(\tan^{-1}_* \frac{x.im}{x.re}\right)\right)\right)\\
\mathbf{elif}\;y.re \leq 7.2 \cdot 10^{-43}:\\
\;\;\;\;\left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right) \cdot e^{y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)}\\
\mathbf{elif}\;y.re \leq 3.7 \cdot 10^{+249}:\\
\;\;\;\;t\_0 \cdot \sin \left(y.re \cdot \sqrt{{\tan^{-1}_* \frac{x.im}{x.re}}^{2}}\right)\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -9.2000000000000003e-4Initial program 42.4%
fma-neg42.4%
hypot-define43.0%
distribute-rgt-neg-out43.0%
fma-define43.0%
hypot-define90.7%
*-commutative90.7%
Simplified90.7%
Taylor expanded in y.im around 0 85.6%
unpow285.6%
unpow285.6%
hypot-undefine86.2%
Simplified86.2%
log1p-expm1-u87.7%
Applied egg-rr87.7%
if -9.2000000000000003e-4 < y.re < 7.1999999999999998e-43Initial program 45.3%
fma-neg45.3%
hypot-define45.3%
distribute-rgt-neg-out45.3%
fma-define45.3%
hypot-define80.7%
*-commutative80.7%
Simplified80.7%
Taylor expanded in y.re around 0 37.5%
*-commutative37.5%
unpow237.5%
unpow237.5%
hypot-undefine63.5%
neg-mul-163.5%
distribute-lft-neg-in63.5%
Simplified63.5%
Taylor expanded in y.im around 0 41.3%
unpow241.3%
unpow241.3%
hypot-undefine63.6%
Simplified63.6%
if 7.1999999999999998e-43 < y.re < 3.6999999999999997e249Initial program 45.0%
fma-neg45.0%
hypot-define45.0%
distribute-rgt-neg-out45.0%
fma-define45.0%
hypot-define71.7%
*-commutative71.7%
Simplified71.7%
Taylor expanded in y.im around 0 50.4%
unpow250.4%
unpow250.4%
hypot-undefine55.2%
Simplified55.2%
add-sqr-sqrt36.7%
sqrt-unprod65.2%
pow265.2%
Applied egg-rr65.2%
if 3.6999999999999997e249 < y.re Initial program 37.5%
fma-neg37.5%
hypot-define37.5%
distribute-rgt-neg-out37.5%
fma-define37.5%
hypot-define37.5%
*-commutative37.5%
Simplified37.5%
Taylor expanded in y.im around 0 37.5%
unpow237.5%
unpow237.5%
hypot-undefine37.5%
Simplified37.5%
Taylor expanded in x.re around 0 37.7%
add-cbrt-cube37.7%
pow1/387.7%
pow387.7%
*-commutative87.7%
Applied egg-rr87.7%
Final simplification70.8%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0
(*
(pow (hypot x.im x.re) y.re)
(sin (* y.re (log1p (expm1 (atan2 x.im x.re))))))))
(if (<= y.re -5.4e-8)
t_0
(if (<= y.re 2.6e-84)
(*
(/ 1.0 (exp (* y.im (atan2 x.im x.re))))
(sin (* y.im (log (hypot x.im x.re)))))
(if (<= y.re 4.7e+250)
t_0
(pow
(pow (* (pow x.im y.re) (sin (* y.re (atan2 x.im x.re)))) 3.0)
0.3333333333333333))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = pow(hypot(x_46_im, x_46_re), y_46_re) * sin((y_46_re * log1p(expm1(atan2(x_46_im, x_46_re)))));
double tmp;
if (y_46_re <= -5.4e-8) {
tmp = t_0;
} else if (y_46_re <= 2.6e-84) {
tmp = (1.0 / exp((y_46_im * atan2(x_46_im, x_46_re)))) * sin((y_46_im * log(hypot(x_46_im, x_46_re))));
} else if (y_46_re <= 4.7e+250) {
tmp = t_0;
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * sin((y_46_re * atan2(x_46_im, x_46_re)))), 3.0), 0.3333333333333333);
}
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 = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re) * Math.sin((y_46_re * Math.log1p(Math.expm1(Math.atan2(x_46_im, x_46_re)))));
double tmp;
if (y_46_re <= -5.4e-8) {
tmp = t_0;
} else if (y_46_re <= 2.6e-84) {
tmp = (1.0 / Math.exp((y_46_im * Math.atan2(x_46_im, x_46_re)))) * Math.sin((y_46_im * Math.log(Math.hypot(x_46_im, x_46_re))));
} else if (y_46_re <= 4.7e+250) {
tmp = t_0;
} else {
tmp = Math.pow(Math.pow((Math.pow(x_46_im, y_46_re) * Math.sin((y_46_re * Math.atan2(x_46_im, x_46_re)))), 3.0), 0.3333333333333333);
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): t_0 = math.pow(math.hypot(x_46_im, x_46_re), y_46_re) * math.sin((y_46_re * math.log1p(math.expm1(math.atan2(x_46_im, x_46_re))))) tmp = 0 if y_46_re <= -5.4e-8: tmp = t_0 elif y_46_re <= 2.6e-84: tmp = (1.0 / math.exp((y_46_im * math.atan2(x_46_im, x_46_re)))) * math.sin((y_46_im * math.log(math.hypot(x_46_im, x_46_re)))) elif y_46_re <= 4.7e+250: tmp = t_0 else: tmp = math.pow(math.pow((math.pow(x_46_im, y_46_re) * math.sin((y_46_re * math.atan2(x_46_im, x_46_re)))), 3.0), 0.3333333333333333) return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = Float64((hypot(x_46_im, x_46_re) ^ y_46_re) * sin(Float64(y_46_re * log1p(expm1(atan(x_46_im, x_46_re)))))) tmp = 0.0 if (y_46_re <= -5.4e-8) tmp = t_0; elseif (y_46_re <= 2.6e-84) tmp = Float64(Float64(1.0 / exp(Float64(y_46_im * atan(x_46_im, x_46_re)))) * sin(Float64(y_46_im * log(hypot(x_46_im, x_46_re))))); elseif (y_46_re <= 4.7e+250) tmp = t_0; else tmp = (Float64((x_46_im ^ y_46_re) * sin(Float64(y_46_re * atan(x_46_im, x_46_re)))) ^ 3.0) ^ 0.3333333333333333; end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] * N[Sin[N[(y$46$re * N[Log[1 + N[(Exp[N[ArcTan[x$46$im / x$46$re], $MachinePrecision]] - 1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -5.4e-8], t$95$0, If[LessEqual[y$46$re, 2.6e-84], N[(N[(1.0 / N[Exp[N[(y$46$im * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $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], If[LessEqual[y$46$re, 4.7e+250], t$95$0, N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := {\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re} \cdot \sin \left(y.re \cdot \mathsf{log1p}\left(\mathsf{expm1}\left(\tan^{-1}_* \frac{x.im}{x.re}\right)\right)\right)\\
\mathbf{if}\;y.re \leq -5.4 \cdot 10^{-8}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;y.re \leq 2.6 \cdot 10^{-84}:\\
\;\;\;\;\frac{1}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}} \cdot \sin \left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right)\\
\mathbf{elif}\;y.re \leq 4.7 \cdot 10^{+250}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -5.40000000000000005e-8 or 2.6e-84 < y.re < 4.6999999999999999e250Initial program 41.2%
fma-neg41.2%
hypot-define41.5%
distribute-rgt-neg-out41.5%
fma-define41.5%
hypot-define80.7%
*-commutative80.7%
Simplified80.7%
Taylor expanded in y.im around 0 65.2%
unpow265.2%
unpow265.2%
hypot-undefine69.1%
Simplified69.1%
log1p-expm1-u71.3%
Applied egg-rr71.3%
if -5.40000000000000005e-8 < y.re < 2.6e-84Initial program 48.4%
exp-diff48.4%
exp-to-pow48.4%
hypot-define48.4%
*-commutative48.4%
exp-prod48.2%
fma-define48.2%
hypot-define80.9%
*-commutative80.9%
Simplified80.9%
Taylor expanded in y.re around 0 81.6%
Taylor expanded in y.im around inf 40.8%
unpow240.8%
unpow240.8%
hypot-undefine66.3%
Simplified66.3%
if 4.6999999999999999e250 < y.re Initial program 37.5%
fma-neg37.5%
hypot-define37.5%
distribute-rgt-neg-out37.5%
fma-define37.5%
hypot-define37.5%
*-commutative37.5%
Simplified37.5%
Taylor expanded in y.im around 0 37.5%
unpow237.5%
unpow237.5%
hypot-undefine37.5%
Simplified37.5%
Taylor expanded in x.re around 0 37.7%
add-cbrt-cube37.7%
pow1/387.7%
pow387.7%
*-commutative87.7%
Applied egg-rr87.7%
Final simplification69.6%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (sin (* y.re (atan2 x.im x.re)))))
(if (<= y.re -0.00032)
(* (pow (hypot x.im x.re) y.re) t_0)
(if (<= y.re 8e-42)
(*
(* y.im (log (hypot x.im x.re)))
(exp (* y.im (- (atan2 x.im x.re)))))
(pow (pow (* (pow x.im y.re) t_0) 3.0) 0.3333333333333333)))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = sin((y_46_re * atan2(x_46_im, x_46_re)));
double tmp;
if (y_46_re <= -0.00032) {
tmp = pow(hypot(x_46_im, x_46_re), y_46_re) * t_0;
} else if (y_46_re <= 8e-42) {
tmp = (y_46_im * log(hypot(x_46_im, x_46_re))) * exp((y_46_im * -atan2(x_46_im, x_46_re)));
} else {
tmp = pow(pow((pow(x_46_im, y_46_re) * t_0), 3.0), 0.3333333333333333);
}
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 = Math.sin((y_46_re * Math.atan2(x_46_im, x_46_re)));
double tmp;
if (y_46_re <= -0.00032) {
tmp = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re) * t_0;
} else if (y_46_re <= 8e-42) {
tmp = (y_46_im * Math.log(Math.hypot(x_46_im, x_46_re))) * Math.exp((y_46_im * -Math.atan2(x_46_im, x_46_re)));
} else {
tmp = Math.pow(Math.pow((Math.pow(x_46_im, y_46_re) * t_0), 3.0), 0.3333333333333333);
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): t_0 = math.sin((y_46_re * math.atan2(x_46_im, x_46_re))) tmp = 0 if y_46_re <= -0.00032: tmp = math.pow(math.hypot(x_46_im, x_46_re), y_46_re) * t_0 elif y_46_re <= 8e-42: tmp = (y_46_im * math.log(math.hypot(x_46_im, x_46_re))) * math.exp((y_46_im * -math.atan2(x_46_im, x_46_re))) else: tmp = math.pow(math.pow((math.pow(x_46_im, y_46_re) * t_0), 3.0), 0.3333333333333333) return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = sin(Float64(y_46_re * atan(x_46_im, x_46_re))) tmp = 0.0 if (y_46_re <= -0.00032) tmp = Float64((hypot(x_46_im, x_46_re) ^ y_46_re) * t_0); elseif (y_46_re <= 8e-42) tmp = Float64(Float64(y_46_im * log(hypot(x_46_im, x_46_re))) * exp(Float64(y_46_im * Float64(-atan(x_46_im, x_46_re))))); else tmp = (Float64((x_46_im ^ y_46_re) * t_0) ^ 3.0) ^ 0.3333333333333333; end return tmp end
function tmp_2 = code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = sin((y_46_re * atan2(x_46_im, x_46_re))); tmp = 0.0; if (y_46_re <= -0.00032) tmp = (hypot(x_46_im, x_46_re) ^ y_46_re) * t_0; elseif (y_46_re <= 8e-42) tmp = (y_46_im * log(hypot(x_46_im, x_46_re))) * exp((y_46_im * -atan2(x_46_im, x_46_re))); else tmp = (((x_46_im ^ y_46_re) * t_0) ^ 3.0) ^ 0.3333333333333333; end tmp_2 = tmp; end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[y$46$re, -0.00032], N[(N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] * t$95$0), $MachinePrecision], If[LessEqual[y$46$re, 8e-42], N[(N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Exp[N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Power[N[Power[N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * t$95$0), $MachinePrecision], 3.0], $MachinePrecision], 0.3333333333333333], $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\
\mathbf{if}\;y.re \leq -0.00032:\\
\;\;\;\;{\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re} \cdot t\_0\\
\mathbf{elif}\;y.re \leq 8 \cdot 10^{-42}:\\
\;\;\;\;\left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right) \cdot e^{y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)}\\
\mathbf{else}:\\
\;\;\;\;{\left({\left({x.im}^{y.re} \cdot t\_0\right)}^{3}\right)}^{0.3333333333333333}\\
\end{array}
\end{array}
if y.re < -3.20000000000000026e-4Initial program 42.4%
fma-neg42.4%
hypot-define43.0%
distribute-rgt-neg-out43.0%
fma-define43.0%
hypot-define90.7%
*-commutative90.7%
Simplified90.7%
Taylor expanded in y.im around 0 85.6%
unpow285.6%
unpow285.6%
hypot-undefine86.2%
Simplified86.2%
if -3.20000000000000026e-4 < y.re < 8.0000000000000003e-42Initial program 45.3%
fma-neg45.3%
hypot-define45.3%
distribute-rgt-neg-out45.3%
fma-define45.3%
hypot-define80.7%
*-commutative80.7%
Simplified80.7%
Taylor expanded in y.re around 0 37.5%
*-commutative37.5%
unpow237.5%
unpow237.5%
hypot-undefine63.5%
neg-mul-163.5%
distribute-lft-neg-in63.5%
Simplified63.5%
Taylor expanded in y.im around 0 41.3%
unpow241.3%
unpow241.3%
hypot-undefine63.6%
Simplified63.6%
if 8.0000000000000003e-42 < y.re Initial program 44.1%
fma-neg44.1%
hypot-define44.1%
distribute-rgt-neg-out44.1%
fma-define44.1%
hypot-define67.6%
*-commutative67.6%
Simplified67.6%
Taylor expanded in y.im around 0 48.8%
unpow248.8%
unpow248.8%
hypot-undefine53.1%
Simplified53.1%
Taylor expanded in x.re around 0 44.6%
add-cbrt-cube44.5%
pow1/354.5%
pow354.5%
*-commutative54.5%
Applied egg-rr54.5%
Final simplification66.9%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re))))
(if (<= y.re -0.0064)
(* (pow (hypot x.im x.re) y.re) (sin t_0))
(if (<= y.re 6.2e-42)
(*
(* y.im (log (hypot x.im x.re)))
(exp (* y.im (- (atan2 x.im x.re)))))
(* (pow x.im y.re) (sin (pow (cbrt t_0) 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 tmp;
if (y_46_re <= -0.0064) {
tmp = pow(hypot(x_46_im, x_46_re), y_46_re) * sin(t_0);
} else if (y_46_re <= 6.2e-42) {
tmp = (y_46_im * log(hypot(x_46_im, x_46_re))) * exp((y_46_im * -atan2(x_46_im, x_46_re)));
} else {
tmp = pow(x_46_im, y_46_re) * sin(pow(cbrt(t_0), 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 tmp;
if (y_46_re <= -0.0064) {
tmp = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re) * Math.sin(t_0);
} else if (y_46_re <= 6.2e-42) {
tmp = (y_46_im * Math.log(Math.hypot(x_46_im, x_46_re))) * Math.exp((y_46_im * -Math.atan2(x_46_im, x_46_re)));
} else {
tmp = Math.pow(x_46_im, y_46_re) * Math.sin(Math.pow(Math.cbrt(t_0), 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)) tmp = 0.0 if (y_46_re <= -0.0064) tmp = Float64((hypot(x_46_im, x_46_re) ^ y_46_re) * sin(t_0)); elseif (y_46_re <= 6.2e-42) tmp = Float64(Float64(y_46_im * log(hypot(x_46_im, x_46_re))) * exp(Float64(y_46_im * Float64(-atan(x_46_im, x_46_re))))); else tmp = Float64((x_46_im ^ y_46_re) * sin((cbrt(t_0) ^ 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]}, If[LessEqual[y$46$re, -0.0064], N[(N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 6.2e-42], N[(N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Exp[N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * N[Sin[N[Power[N[Power[t$95$0, 1/3], $MachinePrecision], 3.0], $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.0064:\\
\;\;\;\;{\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re} \cdot \sin t\_0\\
\mathbf{elif}\;y.re \leq 6.2 \cdot 10^{-42}:\\
\;\;\;\;\left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right) \cdot e^{y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)}\\
\mathbf{else}:\\
\;\;\;\;{x.im}^{y.re} \cdot \sin \left({\left(\sqrt[3]{t\_0}\right)}^{3}\right)\\
\end{array}
\end{array}
if y.re < -0.00640000000000000031Initial program 42.4%
fma-neg42.4%
hypot-define43.0%
distribute-rgt-neg-out43.0%
fma-define43.0%
hypot-define90.7%
*-commutative90.7%
Simplified90.7%
Taylor expanded in y.im around 0 85.6%
unpow285.6%
unpow285.6%
hypot-undefine86.2%
Simplified86.2%
if -0.00640000000000000031 < y.re < 6.2000000000000005e-42Initial program 45.3%
fma-neg45.3%
hypot-define45.3%
distribute-rgt-neg-out45.3%
fma-define45.3%
hypot-define80.7%
*-commutative80.7%
Simplified80.7%
Taylor expanded in y.re around 0 37.5%
*-commutative37.5%
unpow237.5%
unpow237.5%
hypot-undefine63.5%
neg-mul-163.5%
distribute-lft-neg-in63.5%
Simplified63.5%
Taylor expanded in y.im around 0 41.3%
unpow241.3%
unpow241.3%
hypot-undefine63.6%
Simplified63.6%
if 6.2000000000000005e-42 < y.re Initial program 44.1%
fma-neg44.1%
hypot-define44.1%
distribute-rgt-neg-out44.1%
fma-define44.1%
hypot-define67.6%
*-commutative67.6%
Simplified67.6%
Taylor expanded in y.im around 0 48.8%
unpow248.8%
unpow248.8%
hypot-undefine53.1%
Simplified53.1%
Taylor expanded in x.re around 0 44.6%
add-cube-cbrt50.3%
pow353.2%
*-commutative53.2%
Applied egg-rr53.2%
Final simplification66.6%
(FPCore (x.re x.im y.re y.im) :precision binary64 (if (or (<= y.re -0.00025) (not (<= y.re 3.6e-43))) (* (pow (hypot x.im x.re) y.re) (sin (* y.re (atan2 x.im x.re)))) (* (* y.im (log (hypot x.im x.re))) (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 tmp;
if ((y_46_re <= -0.00025) || !(y_46_re <= 3.6e-43)) {
tmp = pow(hypot(x_46_im, x_46_re), y_46_re) * sin((y_46_re * atan2(x_46_im, x_46_re)));
} else {
tmp = (y_46_im * log(hypot(x_46_im, x_46_re))) * 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 tmp;
if ((y_46_re <= -0.00025) || !(y_46_re <= 3.6e-43)) {
tmp = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re) * Math.sin((y_46_re * Math.atan2(x_46_im, x_46_re)));
} else {
tmp = (y_46_im * Math.log(Math.hypot(x_46_im, x_46_re))) * 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): tmp = 0 if (y_46_re <= -0.00025) or not (y_46_re <= 3.6e-43): tmp = math.pow(math.hypot(x_46_im, x_46_re), y_46_re) * math.sin((y_46_re * math.atan2(x_46_im, x_46_re))) else: tmp = (y_46_im * math.log(math.hypot(x_46_im, x_46_re))) * 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) tmp = 0.0 if ((y_46_re <= -0.00025) || !(y_46_re <= 3.6e-43)) tmp = Float64((hypot(x_46_im, x_46_re) ^ y_46_re) * sin(Float64(y_46_re * atan(x_46_im, x_46_re)))); else tmp = Float64(Float64(y_46_im * log(hypot(x_46_im, x_46_re))) * exp(Float64(y_46_im * Float64(-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) tmp = 0.0; if ((y_46_re <= -0.00025) || ~((y_46_re <= 3.6e-43))) tmp = (hypot(x_46_im, x_46_re) ^ y_46_re) * sin((y_46_re * atan2(x_46_im, x_46_re))); else tmp = (y_46_im * log(hypot(x_46_im, x_46_re))) * 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_] := If[Or[LessEqual[y$46$re, -0.00025], N[Not[LessEqual[y$46$re, 3.6e-43]], $MachinePrecision]], N[(N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] * N[Sin[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[(y$46$im * N[Log[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Exp[N[(y$46$im * (-N[ArcTan[x$46$im / x$46$re], $MachinePrecision])), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y.re \leq -0.00025 \lor \neg \left(y.re \leq 3.6 \cdot 10^{-43}\right):\\
\;\;\;\;{\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re} \cdot \sin \left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\
\mathbf{else}:\\
\;\;\;\;\left(y.im \cdot \log \left(\mathsf{hypot}\left(x.im, x.re\right)\right)\right) \cdot e^{y.im \cdot \left(-\tan^{-1}_* \frac{x.im}{x.re}\right)}\\
\end{array}
\end{array}
if y.re < -2.5000000000000001e-4 or 3.5999999999999999e-43 < y.re Initial program 43.3%
fma-neg43.3%
hypot-define43.6%
distribute-rgt-neg-out43.6%
fma-define43.6%
hypot-define78.9%
*-commutative78.9%
Simplified78.9%
Taylor expanded in y.im around 0 66.8%
unpow266.8%
unpow266.8%
hypot-undefine69.3%
Simplified69.3%
if -2.5000000000000001e-4 < y.re < 3.5999999999999999e-43Initial program 45.3%
fma-neg45.3%
hypot-define45.3%
distribute-rgt-neg-out45.3%
fma-define45.3%
hypot-define80.7%
*-commutative80.7%
Simplified80.7%
Taylor expanded in y.re around 0 37.5%
*-commutative37.5%
unpow237.5%
unpow237.5%
hypot-undefine63.5%
neg-mul-163.5%
distribute-lft-neg-in63.5%
Simplified63.5%
Taylor expanded in y.im around 0 41.3%
unpow241.3%
unpow241.3%
hypot-undefine63.6%
Simplified63.6%
Final simplification66.5%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re))))
(if (<= y.im -4.5e+150)
(log (+ 1.0 (expm1 t_0)))
(if (<= y.im 7.6e-15)
(* (pow (hypot x.im x.re) y.re) (sin t_0))
(/ (sin (* y.im (log x.im))) (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_im <= -4.5e+150) {
tmp = log((1.0 + expm1(t_0)));
} else if (y_46_im <= 7.6e-15) {
tmp = pow(hypot(x_46_im, x_46_re), y_46_re) * sin(t_0);
} else {
tmp = sin((y_46_im * log(x_46_im))) / 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_im <= -4.5e+150) {
tmp = Math.log((1.0 + Math.expm1(t_0)));
} else if (y_46_im <= 7.6e-15) {
tmp = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re) * Math.sin(t_0);
} else {
tmp = Math.sin((y_46_im * Math.log(x_46_im))) / 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_im <= -4.5e+150: tmp = math.log((1.0 + math.expm1(t_0))) elif y_46_im <= 7.6e-15: tmp = math.pow(math.hypot(x_46_im, x_46_re), y_46_re) * math.sin(t_0) else: tmp = math.sin((y_46_im * math.log(x_46_im))) / 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_im <= -4.5e+150) tmp = log(Float64(1.0 + expm1(t_0))); elseif (y_46_im <= 7.6e-15) tmp = Float64((hypot(x_46_im, x_46_re) ^ y_46_re) * sin(t_0)); else tmp = Float64(sin(Float64(y_46_im * log(x_46_im))) / exp(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[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$im, -4.5e+150], N[Log[N[(1.0 + N[(Exp[t$95$0] - 1), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[y$46$im, 7.6e-15], N[(N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision], N[(N[Sin[N[(y$46$im * N[Log[x$46$im], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / 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.im \leq -4.5 \cdot 10^{+150}:\\
\;\;\;\;\log \left(1 + \mathsf{expm1}\left(t\_0\right)\right)\\
\mathbf{elif}\;y.im \leq 7.6 \cdot 10^{-15}:\\
\;\;\;\;{\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re} \cdot \sin t\_0\\
\mathbf{else}:\\
\;\;\;\;\frac{\sin \left(y.im \cdot \log x.im\right)}{e^{y.im \cdot \tan^{-1}_* \frac{x.im}{x.re}}}\\
\end{array}
\end{array}
if y.im < -4.5e150Initial program 25.9%
fma-neg25.9%
hypot-define25.9%
distribute-rgt-neg-out25.9%
fma-define25.9%
hypot-define52.2%
*-commutative52.2%
Simplified52.2%
Taylor expanded in y.im around 0 24.3%
unpow224.3%
unpow224.3%
hypot-undefine15.0%
Simplified15.0%
Taylor expanded in x.re around 0 13.8%
Taylor expanded in y.re around 0 3.0%
log1p-expm1-u15.2%
log1p-undefine36.6%
*-commutative36.6%
Applied egg-rr36.6%
if -4.5e150 < y.im < 7.6000000000000004e-15Initial program 49.4%
fma-neg49.4%
hypot-define49.6%
distribute-rgt-neg-out49.6%
fma-define49.6%
hypot-define86.5%
*-commutative86.5%
Simplified86.5%
Taylor expanded in y.im around 0 49.9%
unpow249.9%
unpow249.9%
hypot-undefine59.1%
Simplified59.1%
if 7.6000000000000004e-15 < y.im Initial program 41.4%
exp-diff35.9%
exp-to-pow35.9%
hypot-define35.9%
*-commutative35.9%
exp-prod34.2%
fma-define34.2%
hypot-define64.7%
*-commutative64.7%
Simplified64.7%
add-cube-cbrt62.3%
pow362.1%
fma-undefine62.1%
*-commutative62.1%
*-commutative62.1%
fma-define62.1%
Applied egg-rr62.1%
Taylor expanded in x.re around 0 48.2%
Taylor expanded in y.re around 0 54.0%
Final simplification54.9%
(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.7e+146)
(log (+ 1.0 (expm1 t_0)))
(* (pow (hypot x.im x.re) y.re) (sin t_0)))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = y_46_re * atan2(x_46_im, x_46_re);
double tmp;
if (y_46_im <= -3.7e+146) {
tmp = log((1.0 + expm1(t_0)));
} else {
tmp = pow(hypot(x_46_im, x_46_re), y_46_re) * sin(t_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 tmp;
if (y_46_im <= -3.7e+146) {
tmp = Math.log((1.0 + Math.expm1(t_0)));
} else {
tmp = Math.pow(Math.hypot(x_46_im, x_46_re), y_46_re) * Math.sin(t_0);
}
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_im <= -3.7e+146: tmp = math.log((1.0 + math.expm1(t_0))) else: tmp = math.pow(math.hypot(x_46_im, x_46_re), y_46_re) * math.sin(t_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)) tmp = 0.0 if (y_46_im <= -3.7e+146) tmp = log(Float64(1.0 + expm1(t_0))); else tmp = Float64((hypot(x_46_im, x_46_re) ^ y_46_re) * sin(t_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]}, If[LessEqual[y$46$im, -3.7e+146], N[Log[N[(1.0 + N[(Exp[t$95$0] - 1), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Power[N[Sqrt[x$46$im ^ 2 + x$46$re ^ 2], $MachinePrecision], y$46$re], $MachinePrecision] * N[Sin[t$95$0], $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.7 \cdot 10^{+146}:\\
\;\;\;\;\log \left(1 + \mathsf{expm1}\left(t\_0\right)\right)\\
\mathbf{else}:\\
\;\;\;\;{\left(\mathsf{hypot}\left(x.im, x.re\right)\right)}^{y.re} \cdot \sin t\_0\\
\end{array}
\end{array}
if y.im < -3.70000000000000004e146Initial program 25.9%
fma-neg25.9%
hypot-define25.9%
distribute-rgt-neg-out25.9%
fma-define25.9%
hypot-define52.2%
*-commutative52.2%
Simplified52.2%
Taylor expanded in y.im around 0 24.3%
unpow224.3%
unpow224.3%
hypot-undefine15.0%
Simplified15.0%
Taylor expanded in x.re around 0 13.8%
Taylor expanded in y.re around 0 3.0%
log1p-expm1-u15.2%
log1p-undefine36.6%
*-commutative36.6%
Applied egg-rr36.6%
if -3.70000000000000004e146 < y.im Initial program 46.8%
fma-neg46.8%
hypot-define46.9%
distribute-rgt-neg-out46.9%
fma-define46.9%
hypot-define83.6%
*-commutative83.6%
Simplified83.6%
Taylor expanded in y.im around 0 46.5%
unpow246.5%
unpow246.5%
hypot-undefine50.8%
Simplified50.8%
Final simplification49.1%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re)))
(t_1 (expm1 t_0))
(t_2 (* (pow x.im y.re) (sin t_0))))
(if (<= y.re -8.5e+79)
t_2
(if (<= y.re 2.4e-89)
(log (+ 1.0 t_1))
(if (<= y.re 5.4e+101) (log1p 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 = expm1(t_0);
double t_2 = pow(x_46_im, y_46_re) * sin(t_0);
double tmp;
if (y_46_re <= -8.5e+79) {
tmp = t_2;
} else if (y_46_re <= 2.4e-89) {
tmp = log((1.0 + t_1));
} else if (y_46_re <= 5.4e+101) {
tmp = log1p(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 = Math.expm1(t_0);
double t_2 = Math.pow(x_46_im, y_46_re) * Math.sin(t_0);
double tmp;
if (y_46_re <= -8.5e+79) {
tmp = t_2;
} else if (y_46_re <= 2.4e-89) {
tmp = Math.log((1.0 + t_1));
} else if (y_46_re <= 5.4e+101) {
tmp = Math.log1p(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 = math.expm1(t_0) t_2 = math.pow(x_46_im, y_46_re) * math.sin(t_0) tmp = 0 if y_46_re <= -8.5e+79: tmp = t_2 elif y_46_re <= 2.4e-89: tmp = math.log((1.0 + t_1)) elif y_46_re <= 5.4e+101: tmp = math.log1p(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 = expm1(t_0) t_2 = Float64((x_46_im ^ y_46_re) * sin(t_0)) tmp = 0.0 if (y_46_re <= -8.5e+79) tmp = t_2; elseif (y_46_re <= 2.4e-89) tmp = log(Float64(1.0 + t_1)); elseif (y_46_re <= 5.4e+101) tmp = log1p(t_1); else tmp = t_2; end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(Exp[t$95$0] - 1), $MachinePrecision]}, Block[{t$95$2 = N[(N[Power[x$46$im, y$46$re], $MachinePrecision] * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$re, -8.5e+79], t$95$2, If[LessEqual[y$46$re, 2.4e-89], N[Log[N[(1.0 + t$95$1), $MachinePrecision]], $MachinePrecision], If[LessEqual[y$46$re, 5.4e+101], N[Log[1 + t$95$1], $MachinePrecision], t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
t_1 := \mathsf{expm1}\left(t\_0\right)\\
t_2 := {x.im}^{y.re} \cdot \sin t\_0\\
\mathbf{if}\;y.re \leq -8.5 \cdot 10^{+79}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y.re \leq 2.4 \cdot 10^{-89}:\\
\;\;\;\;\log \left(1 + t\_1\right)\\
\mathbf{elif}\;y.re \leq 5.4 \cdot 10^{+101}:\\
\;\;\;\;\mathsf{log1p}\left(t\_1\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y.re < -8.4999999999999998e79 or 5.40000000000000012e101 < y.re Initial program 41.8%
fma-neg41.8%
hypot-define41.8%
distribute-rgt-neg-out41.8%
fma-define41.8%
hypot-define80.2%
*-commutative80.2%
Simplified80.2%
Taylor expanded in y.im around 0 72.6%
unpow272.6%
unpow272.6%
hypot-undefine72.6%
Simplified72.6%
Taylor expanded in x.re around 0 56.4%
if -8.4999999999999998e79 < y.re < 2.40000000000000016e-89Initial program 48.6%
fma-neg48.6%
hypot-define48.9%
distribute-rgt-neg-out48.9%
fma-define48.9%
hypot-define81.2%
*-commutative81.2%
Simplified81.2%
Taylor expanded in y.im around 0 24.5%
unpow224.5%
unpow224.5%
hypot-undefine25.9%
Simplified25.9%
Taylor expanded in x.re around 0 11.0%
Taylor expanded in y.re around 0 19.0%
log1p-expm1-u19.7%
log1p-undefine27.4%
*-commutative27.4%
Applied egg-rr27.4%
if 2.40000000000000016e-89 < y.re < 5.40000000000000012e101Initial program 35.9%
fma-neg35.9%
hypot-define35.9%
distribute-rgt-neg-out35.9%
fma-define35.9%
hypot-define74.3%
*-commutative74.3%
Simplified74.3%
Taylor expanded in y.im around 0 39.2%
unpow239.2%
unpow239.2%
hypot-undefine51.8%
Simplified51.8%
Taylor expanded in x.re around 0 36.4%
Taylor expanded in y.re around 0 25.2%
*-commutative25.2%
log1p-expm1-u52.1%
Applied egg-rr52.1%
Final simplification41.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 -5000.0) (not (<= y.re 7.6e-5)))
(* (sin t_0) (pow x.re y.re))
(cbrt (pow t_0 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 tmp;
if ((y_46_re <= -5000.0) || !(y_46_re <= 7.6e-5)) {
tmp = sin(t_0) * pow(x_46_re, y_46_re);
} else {
tmp = cbrt(pow(t_0, 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 tmp;
if ((y_46_re <= -5000.0) || !(y_46_re <= 7.6e-5)) {
tmp = Math.sin(t_0) * Math.pow(x_46_re, y_46_re);
} else {
tmp = Math.cbrt(Math.pow(t_0, 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)) tmp = 0.0 if ((y_46_re <= -5000.0) || !(y_46_re <= 7.6e-5)) tmp = Float64(sin(t_0) * (x_46_re ^ y_46_re)); else tmp = cbrt((t_0 ^ 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]}, If[Or[LessEqual[y$46$re, -5000.0], N[Not[LessEqual[y$46$re, 7.6e-5]], $MachinePrecision]], N[(N[Sin[t$95$0], $MachinePrecision] * N[Power[x$46$re, y$46$re], $MachinePrecision]), $MachinePrecision], N[Power[N[Power[t$95$0, 3.0], $MachinePrecision], 1/3], $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\\
\mathbf{if}\;y.re \leq -5000 \lor \neg \left(y.re \leq 7.6 \cdot 10^{-5}\right):\\
\;\;\;\;\sin t\_0 \cdot {x.re}^{y.re}\\
\mathbf{else}:\\
\;\;\;\;\sqrt[3]{{t\_0}^{3}}\\
\end{array}
\end{array}
if y.re < -5e3 or 7.6000000000000004e-5 < y.re Initial program 43.3%
fma-neg43.3%
hypot-define43.3%
distribute-rgt-neg-out43.3%
fma-define43.3%
hypot-define78.0%
*-commutative78.0%
Simplified78.0%
Taylor expanded in y.im around 0 68.6%
unpow268.6%
unpow268.6%
hypot-undefine68.6%
Simplified68.6%
Taylor expanded in x.im around 0 55.5%
if -5e3 < y.re < 7.6000000000000004e-5Initial program 45.1%
fma-neg45.1%
hypot-define45.5%
distribute-rgt-neg-out45.5%
fma-define45.5%
hypot-define81.6%
*-commutative81.6%
Simplified81.6%
Taylor expanded in y.im around 0 19.5%
unpow219.5%
unpow219.5%
hypot-undefine24.6%
Simplified24.6%
Taylor expanded in x.re around 0 13.1%
Taylor expanded in y.re around 0 23.8%
add-cbrt-cube28.3%
pow328.3%
*-commutative28.3%
Applied egg-rr28.3%
Final simplification41.8%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (expm1 (* y.re (atan2 x.im x.re)))))
(if (or (<= y.im -30000000000000.0) (not (<= y.im 3.5e-63)))
(log (+ 1.0 t_0))
(log1p t_0))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = expm1((y_46_re * atan2(x_46_im, x_46_re)));
double tmp;
if ((y_46_im <= -30000000000000.0) || !(y_46_im <= 3.5e-63)) {
tmp = log((1.0 + t_0));
} else {
tmp = log1p(t_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 = Math.expm1((y_46_re * Math.atan2(x_46_im, x_46_re)));
double tmp;
if ((y_46_im <= -30000000000000.0) || !(y_46_im <= 3.5e-63)) {
tmp = Math.log((1.0 + t_0));
} else {
tmp = Math.log1p(t_0);
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): t_0 = math.expm1((y_46_re * math.atan2(x_46_im, x_46_re))) tmp = 0 if (y_46_im <= -30000000000000.0) or not (y_46_im <= 3.5e-63): tmp = math.log((1.0 + t_0)) else: tmp = math.log1p(t_0) return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = expm1(Float64(y_46_re * atan(x_46_im, x_46_re))) tmp = 0.0 if ((y_46_im <= -30000000000000.0) || !(y_46_im <= 3.5e-63)) tmp = log(Float64(1.0 + t_0)); else tmp = log1p(t_0); end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(Exp[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]] - 1), $MachinePrecision]}, If[Or[LessEqual[y$46$im, -30000000000000.0], N[Not[LessEqual[y$46$im, 3.5e-63]], $MachinePrecision]], N[Log[N[(1.0 + t$95$0), $MachinePrecision]], $MachinePrecision], N[Log[1 + t$95$0], $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \mathsf{expm1}\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\\
\mathbf{if}\;y.im \leq -30000000000000 \lor \neg \left(y.im \leq 3.5 \cdot 10^{-63}\right):\\
\;\;\;\;\log \left(1 + t\_0\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{log1p}\left(t\_0\right)\\
\end{array}
\end{array}
if y.im < -3e13 or 3.50000000000000003e-63 < y.im Initial program 40.7%
fma-neg40.7%
hypot-define40.7%
distribute-rgt-neg-out40.7%
fma-define40.7%
hypot-define73.0%
*-commutative73.0%
Simplified73.0%
Taylor expanded in y.im around 0 40.5%
unpow240.5%
unpow240.5%
hypot-undefine34.9%
Simplified34.9%
Taylor expanded in x.re around 0 24.9%
Taylor expanded in y.re around 0 5.0%
log1p-expm1-u15.8%
log1p-undefine37.0%
*-commutative37.0%
Applied egg-rr37.0%
if -3e13 < y.im < 3.50000000000000003e-63Initial program 49.1%
fma-neg49.1%
hypot-define49.5%
distribute-rgt-neg-out49.5%
fma-define49.5%
hypot-define89.1%
*-commutative89.1%
Simplified89.1%
Taylor expanded in y.im around 0 48.5%
unpow248.5%
unpow248.5%
hypot-undefine62.3%
Simplified62.3%
Taylor expanded in x.re around 0 39.5%
Taylor expanded in y.re around 0 28.3%
*-commutative28.3%
log1p-expm1-u35.9%
Applied egg-rr35.9%
Final simplification36.5%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (* y.re (atan2 x.im x.re))))
(if (<= y.re -3.1e-150)
(* y.re (log (exp (atan2 x.im x.re))))
(if (<= y.re 6.8e-249) (cbrt (pow t_0 3.0)) (log1p (expm1 t_0))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = y_46_re * atan2(x_46_im, x_46_re);
double tmp;
if (y_46_re <= -3.1e-150) {
tmp = y_46_re * log(exp(atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 6.8e-249) {
tmp = cbrt(pow(t_0, 3.0));
} else {
tmp = log1p(expm1(t_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 tmp;
if (y_46_re <= -3.1e-150) {
tmp = y_46_re * Math.log(Math.exp(Math.atan2(x_46_im, x_46_re)));
} else if (y_46_re <= 6.8e-249) {
tmp = Math.cbrt(Math.pow(t_0, 3.0));
} else {
tmp = Math.log1p(Math.expm1(t_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)) tmp = 0.0 if (y_46_re <= -3.1e-150) tmp = Float64(y_46_re * log(exp(atan(x_46_im, x_46_re)))); elseif (y_46_re <= 6.8e-249) tmp = cbrt((t_0 ^ 3.0)); else tmp = log1p(expm1(t_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]}, If[LessEqual[y$46$re, -3.1e-150], N[(y$46$re * N[Log[N[Exp[N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$re, 6.8e-249], N[Power[N[Power[t$95$0, 3.0], $MachinePrecision], 1/3], $MachinePrecision], N[Log[1 + N[(Exp[t$95$0] - 1), $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 -3.1 \cdot 10^{-150}:\\
\;\;\;\;y.re \cdot \log \left(e^{\tan^{-1}_* \frac{x.im}{x.re}}\right)\\
\mathbf{elif}\;y.re \leq 6.8 \cdot 10^{-249}:\\
\;\;\;\;\sqrt[3]{{t\_0}^{3}}\\
\mathbf{else}:\\
\;\;\;\;\mathsf{log1p}\left(\mathsf{expm1}\left(t\_0\right)\right)\\
\end{array}
\end{array}
if y.re < -3.09999999999999998e-150Initial program 42.2%
fma-neg42.2%
hypot-define42.6%
distribute-rgt-neg-out42.6%
fma-define42.6%
hypot-define85.9%
*-commutative85.9%
Simplified85.9%
Taylor expanded in y.im around 0 65.1%
unpow265.1%
unpow265.1%
hypot-undefine67.4%
Simplified67.4%
Taylor expanded in x.re around 0 40.8%
Taylor expanded in y.re around 0 16.2%
add-log-exp27.9%
Applied egg-rr27.9%
if -3.09999999999999998e-150 < y.re < 6.7999999999999996e-249Initial program 44.8%
fma-neg44.8%
hypot-define44.8%
distribute-rgt-neg-out44.8%
fma-define44.8%
hypot-define77.7%
*-commutative77.7%
Simplified77.7%
Taylor expanded in y.im around 0 10.4%
unpow210.4%
unpow210.4%
hypot-undefine10.9%
Simplified10.9%
Taylor expanded in x.re around 0 5.5%
Taylor expanded in y.re around 0 10.9%
add-cbrt-cube27.2%
pow327.2%
*-commutative27.2%
Applied egg-rr27.2%
if 6.7999999999999996e-249 < y.re Initial program 46.0%
fma-neg46.0%
hypot-define46.0%
distribute-rgt-neg-out46.0%
fma-define46.0%
hypot-define74.9%
*-commutative74.9%
Simplified74.9%
Taylor expanded in y.im around 0 41.9%
unpow241.9%
unpow241.9%
hypot-undefine46.0%
Simplified46.0%
Taylor expanded in x.re around 0 35.9%
Taylor expanded in y.re around 0 15.7%
*-commutative15.7%
log1p-expm1-u36.4%
Applied egg-rr36.4%
Final simplification31.1%
(FPCore (x.re x.im y.re y.im) :precision binary64 (if (<= x.re 3.2e-170) (log1p (expm1 (* y.re (atan2 x.im x.re)))) (* y.re (log (exp (atan2 x.im x.re))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if (x_46_re <= 3.2e-170) {
tmp = log1p(expm1((y_46_re * atan2(x_46_im, x_46_re))));
} else {
tmp = y_46_re * log(exp(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 tmp;
if (x_46_re <= 3.2e-170) {
tmp = Math.log1p(Math.expm1((y_46_re * Math.atan2(x_46_im, x_46_re))));
} else {
tmp = y_46_re * Math.log(Math.exp(Math.atan2(x_46_im, x_46_re)));
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): tmp = 0 if x_46_re <= 3.2e-170: tmp = math.log1p(math.expm1((y_46_re * math.atan2(x_46_im, x_46_re)))) else: tmp = y_46_re * math.log(math.exp(math.atan2(x_46_im, x_46_re))) return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = 0.0 if (x_46_re <= 3.2e-170) tmp = log1p(expm1(Float64(y_46_re * atan(x_46_im, x_46_re)))); else tmp = Float64(y_46_re * log(exp(atan(x_46_im, x_46_re)))); end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := If[LessEqual[x$46$re, 3.2e-170], N[Log[1 + N[(Exp[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]] - 1), $MachinePrecision]], $MachinePrecision], N[(y$46$re * N[Log[N[Exp[N[ArcTan[x$46$im / x$46$re], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x.re \leq 3.2 \cdot 10^{-170}:\\
\;\;\;\;\mathsf{log1p}\left(\mathsf{expm1}\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y.re \cdot \log \left(e^{\tan^{-1}_* \frac{x.im}{x.re}}\right)\\
\end{array}
\end{array}
if x.re < 3.1999999999999999e-170Initial program 46.3%
fma-neg46.3%
hypot-define46.5%
distribute-rgt-neg-out46.5%
fma-define46.5%
hypot-define78.6%
*-commutative78.6%
Simplified78.6%
Taylor expanded in y.im around 0 42.3%
unpow242.3%
unpow242.3%
hypot-undefine44.5%
Simplified44.5%
Taylor expanded in x.re around 0 30.9%
Taylor expanded in y.re around 0 15.6%
*-commutative15.6%
log1p-expm1-u27.9%
Applied egg-rr27.9%
if 3.1999999999999999e-170 < x.re Initial program 40.8%
fma-neg40.8%
hypot-define40.8%
distribute-rgt-neg-out40.8%
fma-define40.8%
hypot-define81.7%
*-commutative81.7%
Simplified81.7%
Taylor expanded in y.im around 0 46.4%
unpow246.4%
unpow246.4%
hypot-undefine49.7%
Simplified49.7%
Taylor expanded in x.re around 0 31.2%
Taylor expanded in y.re around 0 13.5%
add-log-exp30.5%
Applied egg-rr30.5%
Final simplification28.9%
(FPCore (x.re x.im y.re y.im) :precision binary64 (log1p (expm1 (* y.re (atan2 x.im x.re)))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
return log1p(expm1((y_46_re * atan2(x_46_im, x_46_re))));
}
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
return Math.log1p(Math.expm1((y_46_re * Math.atan2(x_46_im, x_46_re))));
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): return math.log1p(math.expm1((y_46_re * math.atan2(x_46_im, x_46_re))))
function code(x_46_re, x_46_im, y_46_re, y_46_im) return log1p(expm1(Float64(y_46_re * atan(x_46_im, x_46_re)))) end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := N[Log[1 + N[(Exp[N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]] - 1), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
\\
\mathsf{log1p}\left(\mathsf{expm1}\left(y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}\right)\right)
\end{array}
Initial program 44.2%
fma-neg44.2%
hypot-define44.4%
distribute-rgt-neg-out44.4%
fma-define44.4%
hypot-define79.8%
*-commutative79.8%
Simplified79.8%
Taylor expanded in y.im around 0 43.9%
unpow243.9%
unpow243.9%
hypot-undefine46.4%
Simplified46.4%
Taylor expanded in x.re around 0 31.0%
Taylor expanded in y.re around 0 14.8%
*-commutative14.8%
log1p-expm1-u24.3%
Applied egg-rr24.3%
Final simplification24.3%
(FPCore (x.re x.im y.re y.im) :precision binary64 (* y.re (atan2 x.im x.re)))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
return y_46_re * atan2(x_46_im, x_46_re);
}
real(8) function code(x_46re, x_46im, y_46re, y_46im)
real(8), intent (in) :: x_46re
real(8), intent (in) :: x_46im
real(8), intent (in) :: y_46re
real(8), intent (in) :: y_46im
code = y_46re * atan2(x_46im, x_46re)
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
return y_46_re * Math.atan2(x_46_im, x_46_re);
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): return y_46_re * math.atan2(x_46_im, x_46_re)
function code(x_46_re, x_46_im, y_46_re, y_46_im) return Float64(y_46_re * atan(x_46_im, x_46_re)) end
function tmp = code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = y_46_re * atan2(x_46_im, x_46_re); end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := N[(y$46$re * N[ArcTan[x$46$im / x$46$re], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
y.re \cdot \tan^{-1}_* \frac{x.im}{x.re}
\end{array}
Initial program 44.2%
fma-neg44.2%
hypot-define44.4%
distribute-rgt-neg-out44.4%
fma-define44.4%
hypot-define79.8%
*-commutative79.8%
Simplified79.8%
Taylor expanded in y.im around 0 43.9%
unpow243.9%
unpow243.9%
hypot-undefine46.4%
Simplified46.4%
Taylor expanded in x.re around 0 31.0%
Taylor expanded in y.re around 0 14.8%
herbie shell --seed 2024113
(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)))))