
(FPCore (x.re x.im y.re y.im) :precision binary64 (/ (- (* x.im y.re) (* x.re y.im)) (+ (* y.re y.re) (* y.im y.im))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
return ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im));
}
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 = ((x_46im * y_46re) - (x_46re * y_46im)) / ((y_46re * y_46re) + (y_46im * y_46im))
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
return ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im));
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): return ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im))
function code(x_46_re, x_46_im, y_46_re, y_46_im) return Float64(Float64(Float64(x_46_im * y_46_re) - Float64(x_46_re * y_46_im)) / Float64(Float64(y_46_re * y_46_re) + Float64(y_46_im * y_46_im))) end
function tmp = code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im)); end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := N[(N[(N[(x$46$im * y$46$re), $MachinePrecision] - N[(x$46$re * y$46$im), $MachinePrecision]), $MachinePrecision] / N[(N[(y$46$re * y$46$re), $MachinePrecision] + N[(y$46$im * y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x.im \cdot y.re - x.re \cdot y.im}{y.re \cdot y.re + y.im \cdot y.im}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 14 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x.re x.im y.re y.im) :precision binary64 (/ (- (* x.im y.re) (* x.re y.im)) (+ (* y.re y.re) (* y.im y.im))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
return ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im));
}
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 = ((x_46im * y_46re) - (x_46re * y_46im)) / ((y_46re * y_46re) + (y_46im * y_46im))
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
return ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im));
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): return ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im))
function code(x_46_re, x_46_im, y_46_re, y_46_im) return Float64(Float64(Float64(x_46_im * y_46_re) - Float64(x_46_re * y_46_im)) / Float64(Float64(y_46_re * y_46_re) + Float64(y_46_im * y_46_im))) end
function tmp = code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im)); end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := N[(N[(N[(x$46$im * y$46$re), $MachinePrecision] - N[(x$46$re * y$46$im), $MachinePrecision]), $MachinePrecision] / N[(N[(y$46$re * y$46$re), $MachinePrecision] + N[(y$46$im * y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x.im \cdot y.re - x.re \cdot y.im}{y.re \cdot y.re + y.im \cdot y.im}
\end{array}
(FPCore (x.re x.im y.re y.im)
:precision binary64
(if (or (<= x.re -7.4e+33) (not (<= x.re 5e+46)))
(*
(/ (- (* x.im (/ y.re x.re)) y.im) (hypot y.re y.im))
(/ x.re (hypot y.re y.im)))
(fma
(/ y.re (hypot y.re y.im))
(/ x.im (hypot y.re y.im))
(* (/ y.im (pow (hypot y.re y.im) 2.0)) (- 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 <= -7.4e+33) || !(x_46_re <= 5e+46)) {
tmp = (((x_46_im * (y_46_re / x_46_re)) - y_46_im) / hypot(y_46_re, y_46_im)) * (x_46_re / hypot(y_46_re, y_46_im));
} else {
tmp = fma((y_46_re / hypot(y_46_re, y_46_im)), (x_46_im / hypot(y_46_re, y_46_im)), ((y_46_im / pow(hypot(y_46_re, y_46_im), 2.0)) * -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 <= -7.4e+33) || !(x_46_re <= 5e+46)) tmp = Float64(Float64(Float64(Float64(x_46_im * Float64(y_46_re / x_46_re)) - y_46_im) / hypot(y_46_re, y_46_im)) * Float64(x_46_re / hypot(y_46_re, y_46_im))); else tmp = fma(Float64(y_46_re / hypot(y_46_re, y_46_im)), Float64(x_46_im / hypot(y_46_re, y_46_im)), Float64(Float64(y_46_im / (hypot(y_46_re, y_46_im) ^ 2.0)) * Float64(-x_46_re))); end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := If[Or[LessEqual[x$46$re, -7.4e+33], N[Not[LessEqual[x$46$re, 5e+46]], $MachinePrecision]], N[(N[(N[(N[(x$46$im * N[(y$46$re / x$46$re), $MachinePrecision]), $MachinePrecision] - y$46$im), $MachinePrecision] / N[Sqrt[y$46$re ^ 2 + y$46$im ^ 2], $MachinePrecision]), $MachinePrecision] * N[(x$46$re / N[Sqrt[y$46$re ^ 2 + y$46$im ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y$46$re / N[Sqrt[y$46$re ^ 2 + y$46$im ^ 2], $MachinePrecision]), $MachinePrecision] * N[(x$46$im / N[Sqrt[y$46$re ^ 2 + y$46$im ^ 2], $MachinePrecision]), $MachinePrecision] + N[(N[(y$46$im / N[Power[N[Sqrt[y$46$re ^ 2 + y$46$im ^ 2], $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * (-x$46$re)), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x.re \leq -7.4 \cdot 10^{+33} \lor \neg \left(x.re \leq 5 \cdot 10^{+46}\right):\\
\;\;\;\;\frac{x.im \cdot \frac{y.re}{x.re} - y.im}{\mathsf{hypot}\left(y.re, y.im\right)} \cdot \frac{x.re}{\mathsf{hypot}\left(y.re, y.im\right)}\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y.re}{\mathsf{hypot}\left(y.re, y.im\right)}, \frac{x.im}{\mathsf{hypot}\left(y.re, y.im\right)}, \frac{y.im}{{\left(\mathsf{hypot}\left(y.re, y.im\right)\right)}^{2}} \cdot \left(-x.re\right)\right)\\
\end{array}
\end{array}
if x.re < -7.3999999999999997e33 or 5.0000000000000002e46 < x.re Initial program 57.4%
Taylor expanded in x.re around inf 57.4%
*-commutative57.4%
+-commutative57.4%
add-sqr-sqrt57.4%
hypot-undefine57.4%
hypot-undefine57.4%
times-frac92.1%
associate-/l*96.9%
hypot-undefine60.1%
+-commutative60.1%
hypot-define96.9%
hypot-undefine60.1%
+-commutative60.1%
hypot-define96.9%
Applied egg-rr96.9%
if -7.3999999999999997e33 < x.re < 5.0000000000000002e46Initial program 72.2%
div-sub71.3%
*-commutative71.3%
fma-define71.3%
add-sqr-sqrt71.3%
times-frac74.8%
fma-neg74.8%
fma-define74.8%
hypot-define74.9%
fma-define74.9%
hypot-define91.0%
associate-/l*91.9%
fma-define91.9%
add-sqr-sqrt91.9%
pow291.9%
Applied egg-rr91.9%
Final simplification93.8%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (/ (fma y.re (/ x.im y.im) (- x.re)) (hypot y.im y.re))))
(if (<= y.im -7.4e-165)
(* t_0 (/ y.im (hypot y.im y.re)))
(if (<= y.im 1.15e-106)
(/ (- x.im (* x.re (/ y.im y.re))) y.re)
(* t_0 (pow (sqrt (/ y.im (hypot y.re y.im))) 2.0))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = fma(y_46_re, (x_46_im / y_46_im), -x_46_re) / hypot(y_46_im, y_46_re);
double tmp;
if (y_46_im <= -7.4e-165) {
tmp = t_0 * (y_46_im / hypot(y_46_im, y_46_re));
} else if (y_46_im <= 1.15e-106) {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
} else {
tmp = t_0 * pow(sqrt((y_46_im / hypot(y_46_re, y_46_im))), 2.0);
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = Float64(fma(y_46_re, Float64(x_46_im / y_46_im), Float64(-x_46_re)) / hypot(y_46_im, y_46_re)) tmp = 0.0 if (y_46_im <= -7.4e-165) tmp = Float64(t_0 * Float64(y_46_im / hypot(y_46_im, y_46_re))); elseif (y_46_im <= 1.15e-106) tmp = Float64(Float64(x_46_im - Float64(x_46_re * Float64(y_46_im / y_46_re))) / y_46_re); else tmp = Float64(t_0 * (sqrt(Float64(y_46_im / hypot(y_46_re, y_46_im))) ^ 2.0)); end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[(y$46$re * N[(x$46$im / y$46$im), $MachinePrecision] + (-x$46$re)), $MachinePrecision] / N[Sqrt[y$46$im ^ 2 + y$46$re ^ 2], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$im, -7.4e-165], N[(t$95$0 * N[(y$46$im / N[Sqrt[y$46$im ^ 2 + y$46$re ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$im, 1.15e-106], N[(N[(x$46$im - N[(x$46$re * N[(y$46$im / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y$46$re), $MachinePrecision], N[(t$95$0 * N[Power[N[Sqrt[N[(y$46$im / N[Sqrt[y$46$re ^ 2 + y$46$im ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\mathsf{fma}\left(y.re, \frac{x.im}{y.im}, -x.re\right)}{\mathsf{hypot}\left(y.im, y.re\right)}\\
\mathbf{if}\;y.im \leq -7.4 \cdot 10^{-165}:\\
\;\;\;\;t\_0 \cdot \frac{y.im}{\mathsf{hypot}\left(y.im, y.re\right)}\\
\mathbf{elif}\;y.im \leq 1.15 \cdot 10^{-106}:\\
\;\;\;\;\frac{x.im - x.re \cdot \frac{y.im}{y.re}}{y.re}\\
\mathbf{else}:\\
\;\;\;\;t\_0 \cdot {\left(\sqrt{\frac{y.im}{\mathsf{hypot}\left(y.re, y.im\right)}}\right)}^{2}\\
\end{array}
\end{array}
if y.im < -7.40000000000000003e-165Initial program 66.7%
Taylor expanded in y.im around inf 64.8%
*-commutative64.8%
associate-/l*63.9%
Simplified63.9%
*-commutative63.9%
add-sqr-sqrt63.9%
hypot-undefine63.9%
hypot-undefine63.9%
times-frac92.0%
fma-neg92.0%
hypot-undefine67.4%
+-commutative67.4%
hypot-undefine92.0%
hypot-undefine67.4%
+-commutative67.4%
hypot-undefine92.0%
Applied egg-rr92.0%
if -7.40000000000000003e-165 < y.im < 1.15e-106Initial program 76.3%
Taylor expanded in y.re around inf 93.6%
mul-1-neg93.6%
unsub-neg93.6%
unsub-neg93.6%
remove-double-neg93.6%
mul-1-neg93.6%
neg-mul-193.6%
mul-1-neg93.6%
distribute-lft-in93.6%
distribute-lft-in93.6%
mul-1-neg93.6%
unsub-neg93.6%
neg-mul-193.6%
mul-1-neg93.6%
remove-double-neg93.6%
associate-/l*93.7%
Simplified93.7%
if 1.15e-106 < y.im Initial program 56.2%
Taylor expanded in y.im around inf 56.2%
*-commutative56.2%
associate-/l*56.2%
Simplified56.2%
*-commutative56.2%
add-sqr-sqrt56.2%
hypot-undefine56.2%
hypot-undefine56.2%
times-frac91.1%
fma-neg91.1%
hypot-undefine58.0%
+-commutative58.0%
hypot-undefine91.1%
hypot-undefine58.0%
+-commutative58.0%
hypot-undefine91.1%
Applied egg-rr91.1%
add-sqr-sqrt91.1%
pow291.1%
hypot-undefine58.0%
+-commutative58.0%
hypot-define91.1%
Applied egg-rr91.1%
Final simplification92.2%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(if (or (<= y.im -5.5e-165) (not (<= y.im 9.6e-109)))
(*
(/ (fma y.re (/ x.im y.im) (- x.re)) (hypot y.im y.re))
(/ y.im (hypot y.im y.re)))
(/ (- x.im (* x.re (/ y.im y.re))) y.re)))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if ((y_46_im <= -5.5e-165) || !(y_46_im <= 9.6e-109)) {
tmp = (fma(y_46_re, (x_46_im / y_46_im), -x_46_re) / hypot(y_46_im, y_46_re)) * (y_46_im / hypot(y_46_im, y_46_re));
} else {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = 0.0 if ((y_46_im <= -5.5e-165) || !(y_46_im <= 9.6e-109)) tmp = Float64(Float64(fma(y_46_re, Float64(x_46_im / y_46_im), Float64(-x_46_re)) / hypot(y_46_im, y_46_re)) * Float64(y_46_im / hypot(y_46_im, y_46_re))); else tmp = Float64(Float64(x_46_im - Float64(x_46_re * Float64(y_46_im / y_46_re))) / y_46_re); end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := If[Or[LessEqual[y$46$im, -5.5e-165], N[Not[LessEqual[y$46$im, 9.6e-109]], $MachinePrecision]], N[(N[(N[(y$46$re * N[(x$46$im / y$46$im), $MachinePrecision] + (-x$46$re)), $MachinePrecision] / N[Sqrt[y$46$im ^ 2 + y$46$re ^ 2], $MachinePrecision]), $MachinePrecision] * N[(y$46$im / N[Sqrt[y$46$im ^ 2 + y$46$re ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x$46$im - N[(x$46$re * N[(y$46$im / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y$46$re), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y.im \leq -5.5 \cdot 10^{-165} \lor \neg \left(y.im \leq 9.6 \cdot 10^{-109}\right):\\
\;\;\;\;\frac{\mathsf{fma}\left(y.re, \frac{x.im}{y.im}, -x.re\right)}{\mathsf{hypot}\left(y.im, y.re\right)} \cdot \frac{y.im}{\mathsf{hypot}\left(y.im, y.re\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{x.im - x.re \cdot \frac{y.im}{y.re}}{y.re}\\
\end{array}
\end{array}
if y.im < -5.49999999999999969e-165 or 9.59999999999999955e-109 < y.im Initial program 62.2%
Taylor expanded in y.im around inf 61.1%
*-commutative61.1%
associate-/l*60.5%
Simplified60.5%
*-commutative60.5%
add-sqr-sqrt60.5%
hypot-undefine60.5%
hypot-undefine60.5%
times-frac91.6%
fma-neg91.6%
hypot-undefine63.3%
+-commutative63.3%
hypot-undefine91.6%
hypot-undefine63.3%
+-commutative63.3%
hypot-undefine91.6%
Applied egg-rr91.6%
if -5.49999999999999969e-165 < y.im < 9.59999999999999955e-109Initial program 76.3%
Taylor expanded in y.re around inf 93.6%
mul-1-neg93.6%
unsub-neg93.6%
unsub-neg93.6%
remove-double-neg93.6%
mul-1-neg93.6%
neg-mul-193.6%
mul-1-neg93.6%
distribute-lft-in93.6%
distribute-lft-in93.6%
mul-1-neg93.6%
unsub-neg93.6%
neg-mul-193.6%
mul-1-neg93.6%
remove-double-neg93.6%
associate-/l*93.7%
Simplified93.7%
Final simplification92.2%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (- (* x.im y.re) (* x.re y.im))))
(if (<= y.im -5.8e+85)
(/ (- (* y.re (/ x.im y.im)) x.re) y.im)
(if (<= y.im -1.3e-159)
(/ t_0 (fma y.im y.im (* y.re y.re)))
(if (<= y.im 2.05e-46)
(/ (- x.im (* x.re (/ y.im y.re))) y.re)
(if (<= y.im 1.65e+47)
(/ t_0 (+ (* y.re y.re) (* y.im y.im)))
(/ (fma y.re (/ x.im y.im) (- x.re)) (hypot y.im y.re))))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = (x_46_im * y_46_re) - (x_46_re * y_46_im);
double tmp;
if (y_46_im <= -5.8e+85) {
tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im;
} else if (y_46_im <= -1.3e-159) {
tmp = t_0 / fma(y_46_im, y_46_im, (y_46_re * y_46_re));
} else if (y_46_im <= 2.05e-46) {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
} else if (y_46_im <= 1.65e+47) {
tmp = t_0 / ((y_46_re * y_46_re) + (y_46_im * y_46_im));
} else {
tmp = fma(y_46_re, (x_46_im / y_46_im), -x_46_re) / hypot(y_46_im, y_46_re);
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = Float64(Float64(x_46_im * y_46_re) - Float64(x_46_re * y_46_im)) tmp = 0.0 if (y_46_im <= -5.8e+85) tmp = Float64(Float64(Float64(y_46_re * Float64(x_46_im / y_46_im)) - x_46_re) / y_46_im); elseif (y_46_im <= -1.3e-159) tmp = Float64(t_0 / fma(y_46_im, y_46_im, Float64(y_46_re * y_46_re))); elseif (y_46_im <= 2.05e-46) tmp = Float64(Float64(x_46_im - Float64(x_46_re * Float64(y_46_im / y_46_re))) / y_46_re); elseif (y_46_im <= 1.65e+47) tmp = Float64(t_0 / Float64(Float64(y_46_re * y_46_re) + Float64(y_46_im * y_46_im))); else tmp = Float64(fma(y_46_re, Float64(x_46_im / y_46_im), Float64(-x_46_re)) / hypot(y_46_im, y_46_re)); end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[(x$46$im * y$46$re), $MachinePrecision] - N[(x$46$re * y$46$im), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$im, -5.8e+85], N[(N[(N[(y$46$re * N[(x$46$im / y$46$im), $MachinePrecision]), $MachinePrecision] - x$46$re), $MachinePrecision] / y$46$im), $MachinePrecision], If[LessEqual[y$46$im, -1.3e-159], N[(t$95$0 / N[(y$46$im * y$46$im + N[(y$46$re * y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$im, 2.05e-46], N[(N[(x$46$im - N[(x$46$re * N[(y$46$im / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y$46$re), $MachinePrecision], If[LessEqual[y$46$im, 1.65e+47], N[(t$95$0 / N[(N[(y$46$re * y$46$re), $MachinePrecision] + N[(y$46$im * y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y$46$re * N[(x$46$im / y$46$im), $MachinePrecision] + (-x$46$re)), $MachinePrecision] / N[Sqrt[y$46$im ^ 2 + y$46$re ^ 2], $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x.im \cdot y.re - x.re \cdot y.im\\
\mathbf{if}\;y.im \leq -5.8 \cdot 10^{+85}:\\
\;\;\;\;\frac{y.re \cdot \frac{x.im}{y.im} - x.re}{y.im}\\
\mathbf{elif}\;y.im \leq -1.3 \cdot 10^{-159}:\\
\;\;\;\;\frac{t\_0}{\mathsf{fma}\left(y.im, y.im, y.re \cdot y.re\right)}\\
\mathbf{elif}\;y.im \leq 2.05 \cdot 10^{-46}:\\
\;\;\;\;\frac{x.im - x.re \cdot \frac{y.im}{y.re}}{y.re}\\
\mathbf{elif}\;y.im \leq 1.65 \cdot 10^{+47}:\\
\;\;\;\;\frac{t\_0}{y.re \cdot y.re + y.im \cdot y.im}\\
\mathbf{else}:\\
\;\;\;\;\frac{\mathsf{fma}\left(y.re, \frac{x.im}{y.im}, -x.re\right)}{\mathsf{hypot}\left(y.im, y.re\right)}\\
\end{array}
\end{array}
if y.im < -5.79999999999999995e85Initial program 43.7%
Taylor expanded in y.re around 0 72.4%
+-commutative72.4%
mul-1-neg72.4%
unsub-neg72.4%
unpow272.4%
associate-/r*78.3%
div-sub78.3%
*-commutative78.3%
associate-/l*88.3%
Simplified88.3%
if -5.79999999999999995e85 < y.im < -1.2999999999999999e-159Initial program 90.2%
fma-neg90.2%
distribute-rgt-neg-out90.2%
+-commutative90.2%
fma-define90.2%
Simplified90.2%
distribute-rgt-neg-out90.2%
fma-neg90.2%
Applied egg-rr90.2%
if -1.2999999999999999e-159 < y.im < 2.05e-46Initial program 75.0%
Taylor expanded in y.re around inf 90.2%
mul-1-neg90.2%
unsub-neg90.2%
unsub-neg90.2%
remove-double-neg90.2%
mul-1-neg90.2%
neg-mul-190.2%
mul-1-neg90.2%
distribute-lft-in90.2%
distribute-lft-in90.2%
mul-1-neg90.2%
unsub-neg90.2%
neg-mul-190.2%
mul-1-neg90.2%
remove-double-neg90.2%
associate-/l*90.2%
Simplified90.2%
if 2.05e-46 < y.im < 1.65e47Initial program 82.6%
if 1.65e47 < y.im Initial program 38.3%
Taylor expanded in y.im around inf 38.3%
*-commutative38.3%
associate-/l*38.3%
Simplified38.3%
*-commutative38.3%
add-sqr-sqrt38.3%
hypot-undefine38.3%
hypot-undefine38.3%
times-frac95.5%
fma-neg95.5%
hypot-undefine41.4%
+-commutative41.4%
hypot-undefine95.5%
hypot-undefine41.4%
+-commutative41.4%
hypot-undefine95.5%
Applied egg-rr95.5%
Taylor expanded in y.im around inf 80.2%
Final simplification87.5%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(if (or (<= x.re -3e-64) (not (<= x.re 7.2e-35)))
(*
(/ (- (* x.im (/ y.re x.re)) y.im) (hypot y.re y.im))
(/ x.re (hypot y.re y.im)))
(* (/ y.re (hypot y.im y.re)) (/ x.im (hypot y.im y.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 <= -3e-64) || !(x_46_re <= 7.2e-35)) {
tmp = (((x_46_im * (y_46_re / x_46_re)) - y_46_im) / hypot(y_46_re, y_46_im)) * (x_46_re / hypot(y_46_re, y_46_im));
} else {
tmp = (y_46_re / hypot(y_46_im, y_46_re)) * (x_46_im / hypot(y_46_im, y_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 <= -3e-64) || !(x_46_re <= 7.2e-35)) {
tmp = (((x_46_im * (y_46_re / x_46_re)) - y_46_im) / Math.hypot(y_46_re, y_46_im)) * (x_46_re / Math.hypot(y_46_re, y_46_im));
} else {
tmp = (y_46_re / Math.hypot(y_46_im, y_46_re)) * (x_46_im / Math.hypot(y_46_im, y_46_re));
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): tmp = 0 if (x_46_re <= -3e-64) or not (x_46_re <= 7.2e-35): tmp = (((x_46_im * (y_46_re / x_46_re)) - y_46_im) / math.hypot(y_46_re, y_46_im)) * (x_46_re / math.hypot(y_46_re, y_46_im)) else: tmp = (y_46_re / math.hypot(y_46_im, y_46_re)) * (x_46_im / math.hypot(y_46_im, y_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 <= -3e-64) || !(x_46_re <= 7.2e-35)) tmp = Float64(Float64(Float64(Float64(x_46_im * Float64(y_46_re / x_46_re)) - y_46_im) / hypot(y_46_re, y_46_im)) * Float64(x_46_re / hypot(y_46_re, y_46_im))); else tmp = Float64(Float64(y_46_re / hypot(y_46_im, y_46_re)) * Float64(x_46_im / hypot(y_46_im, y_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 ((x_46_re <= -3e-64) || ~((x_46_re <= 7.2e-35))) tmp = (((x_46_im * (y_46_re / x_46_re)) - y_46_im) / hypot(y_46_re, y_46_im)) * (x_46_re / hypot(y_46_re, y_46_im)); else tmp = (y_46_re / hypot(y_46_im, y_46_re)) * (x_46_im / hypot(y_46_im, y_46_re)); end tmp_2 = tmp; end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := If[Or[LessEqual[x$46$re, -3e-64], N[Not[LessEqual[x$46$re, 7.2e-35]], $MachinePrecision]], N[(N[(N[(N[(x$46$im * N[(y$46$re / x$46$re), $MachinePrecision]), $MachinePrecision] - y$46$im), $MachinePrecision] / N[Sqrt[y$46$re ^ 2 + y$46$im ^ 2], $MachinePrecision]), $MachinePrecision] * N[(x$46$re / N[Sqrt[y$46$re ^ 2 + y$46$im ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y$46$re / N[Sqrt[y$46$im ^ 2 + y$46$re ^ 2], $MachinePrecision]), $MachinePrecision] * N[(x$46$im / N[Sqrt[y$46$im ^ 2 + y$46$re ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x.re \leq -3 \cdot 10^{-64} \lor \neg \left(x.re \leq 7.2 \cdot 10^{-35}\right):\\
\;\;\;\;\frac{x.im \cdot \frac{y.re}{x.re} - y.im}{\mathsf{hypot}\left(y.re, y.im\right)} \cdot \frac{x.re}{\mathsf{hypot}\left(y.re, y.im\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{y.re}{\mathsf{hypot}\left(y.im, y.re\right)} \cdot \frac{x.im}{\mathsf{hypot}\left(y.im, y.re\right)}\\
\end{array}
\end{array}
if x.re < -3.0000000000000001e-64 or 7.20000000000000038e-35 < x.re Initial program 60.1%
Taylor expanded in x.re around inf 60.1%
*-commutative60.1%
+-commutative60.1%
add-sqr-sqrt60.1%
hypot-undefine60.1%
hypot-undefine60.1%
times-frac89.8%
associate-/l*93.4%
hypot-undefine62.1%
+-commutative62.1%
hypot-define93.4%
hypot-undefine62.1%
+-commutative62.1%
hypot-define93.4%
Applied egg-rr93.4%
if -3.0000000000000001e-64 < x.re < 7.20000000000000038e-35Initial program 73.6%
Taylor expanded in x.im around inf 64.9%
*-commutative64.9%
Simplified64.9%
add-sqr-sqrt64.9%
hypot-undefine64.9%
hypot-undefine64.9%
frac-times87.9%
hypot-undefine67.9%
+-commutative67.9%
hypot-undefine87.9%
hypot-undefine67.9%
+-commutative67.9%
hypot-undefine87.9%
Applied egg-rr87.9%
Final simplification90.8%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0 (- (* x.im y.re) (* x.re y.im))))
(if (<= y.im -8e+85)
(/ (- (* y.re (/ x.im y.im)) x.re) y.im)
(if (<= y.im -9e-160)
(/ t_0 (fma y.im y.im (* y.re y.re)))
(if (<= y.im 4.1e-47)
(/ (- x.im (* x.re (/ y.im y.re))) y.re)
(if (<= y.im 4.1e+148)
(/ t_0 (+ (* y.re y.re) (* y.im y.im)))
(/ (- (/ y.re (/ y.im x.im)) x.re) y.im)))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = (x_46_im * y_46_re) - (x_46_re * y_46_im);
double tmp;
if (y_46_im <= -8e+85) {
tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im;
} else if (y_46_im <= -9e-160) {
tmp = t_0 / fma(y_46_im, y_46_im, (y_46_re * y_46_re));
} else if (y_46_im <= 4.1e-47) {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
} else if (y_46_im <= 4.1e+148) {
tmp = t_0 / ((y_46_re * y_46_re) + (y_46_im * y_46_im));
} else {
tmp = ((y_46_re / (y_46_im / x_46_im)) - x_46_re) / y_46_im;
}
return tmp;
}
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = Float64(Float64(x_46_im * y_46_re) - Float64(x_46_re * y_46_im)) tmp = 0.0 if (y_46_im <= -8e+85) tmp = Float64(Float64(Float64(y_46_re * Float64(x_46_im / y_46_im)) - x_46_re) / y_46_im); elseif (y_46_im <= -9e-160) tmp = Float64(t_0 / fma(y_46_im, y_46_im, Float64(y_46_re * y_46_re))); elseif (y_46_im <= 4.1e-47) tmp = Float64(Float64(x_46_im - Float64(x_46_re * Float64(y_46_im / y_46_re))) / y_46_re); elseif (y_46_im <= 4.1e+148) tmp = Float64(t_0 / Float64(Float64(y_46_re * y_46_re) + Float64(y_46_im * y_46_im))); else tmp = Float64(Float64(Float64(y_46_re / Float64(y_46_im / x_46_im)) - x_46_re) / y_46_im); end return tmp end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[(x$46$im * y$46$re), $MachinePrecision] - N[(x$46$re * y$46$im), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$im, -8e+85], N[(N[(N[(y$46$re * N[(x$46$im / y$46$im), $MachinePrecision]), $MachinePrecision] - x$46$re), $MachinePrecision] / y$46$im), $MachinePrecision], If[LessEqual[y$46$im, -9e-160], N[(t$95$0 / N[(y$46$im * y$46$im + N[(y$46$re * y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$46$im, 4.1e-47], N[(N[(x$46$im - N[(x$46$re * N[(y$46$im / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y$46$re), $MachinePrecision], If[LessEqual[y$46$im, 4.1e+148], N[(t$95$0 / N[(N[(y$46$re * y$46$re), $MachinePrecision] + N[(y$46$im * y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(y$46$re / N[(y$46$im / x$46$im), $MachinePrecision]), $MachinePrecision] - x$46$re), $MachinePrecision] / y$46$im), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x.im \cdot y.re - x.re \cdot y.im\\
\mathbf{if}\;y.im \leq -8 \cdot 10^{+85}:\\
\;\;\;\;\frac{y.re \cdot \frac{x.im}{y.im} - x.re}{y.im}\\
\mathbf{elif}\;y.im \leq -9 \cdot 10^{-160}:\\
\;\;\;\;\frac{t\_0}{\mathsf{fma}\left(y.im, y.im, y.re \cdot y.re\right)}\\
\mathbf{elif}\;y.im \leq 4.1 \cdot 10^{-47}:\\
\;\;\;\;\frac{x.im - x.re \cdot \frac{y.im}{y.re}}{y.re}\\
\mathbf{elif}\;y.im \leq 4.1 \cdot 10^{+148}:\\
\;\;\;\;\frac{t\_0}{y.re \cdot y.re + y.im \cdot y.im}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{y.re}{\frac{y.im}{x.im}} - x.re}{y.im}\\
\end{array}
\end{array}
if y.im < -8.0000000000000001e85Initial program 43.7%
Taylor expanded in y.re around 0 72.4%
+-commutative72.4%
mul-1-neg72.4%
unsub-neg72.4%
unpow272.4%
associate-/r*78.3%
div-sub78.3%
*-commutative78.3%
associate-/l*88.3%
Simplified88.3%
if -8.0000000000000001e85 < y.im < -9.00000000000000053e-160Initial program 90.2%
fma-neg90.2%
distribute-rgt-neg-out90.2%
+-commutative90.2%
fma-define90.2%
Simplified90.2%
distribute-rgt-neg-out90.2%
fma-neg90.2%
Applied egg-rr90.2%
if -9.00000000000000053e-160 < y.im < 4.10000000000000002e-47Initial program 75.0%
Taylor expanded in y.re around inf 90.2%
mul-1-neg90.2%
unsub-neg90.2%
unsub-neg90.2%
remove-double-neg90.2%
mul-1-neg90.2%
neg-mul-190.2%
mul-1-neg90.2%
distribute-lft-in90.2%
distribute-lft-in90.2%
mul-1-neg90.2%
unsub-neg90.2%
neg-mul-190.2%
mul-1-neg90.2%
remove-double-neg90.2%
associate-/l*90.2%
Simplified90.2%
if 4.10000000000000002e-47 < y.im < 4.0999999999999998e148Initial program 75.4%
if 4.0999999999999998e148 < y.im Initial program 28.1%
Taylor expanded in y.re around 0 66.8%
+-commutative66.8%
mul-1-neg66.8%
unsub-neg66.8%
unpow266.8%
associate-/r*79.1%
div-sub79.1%
*-commutative79.1%
associate-/l*85.8%
Simplified85.8%
clear-num85.8%
un-div-inv85.8%
Applied egg-rr85.8%
Final simplification87.2%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(let* ((t_0
(/ (- (* x.im y.re) (* x.re y.im)) (+ (* y.re y.re) (* y.im y.im)))))
(if (<= y.im -8.8e+85)
(/ (- (* y.re (/ x.im y.im)) x.re) y.im)
(if (<= y.im -3.8e-160)
t_0
(if (<= y.im 3.75e-47)
(/ (- x.im (* x.re (/ y.im y.re))) y.re)
(if (<= y.im 9.5e+145)
t_0
(/ (- (/ y.re (/ y.im x.im)) x.re) y.im)))))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im));
double tmp;
if (y_46_im <= -8.8e+85) {
tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im;
} else if (y_46_im <= -3.8e-160) {
tmp = t_0;
} else if (y_46_im <= 3.75e-47) {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
} else if (y_46_im <= 9.5e+145) {
tmp = t_0;
} else {
tmp = ((y_46_re / (y_46_im / x_46_im)) - x_46_re) / y_46_im;
}
return tmp;
}
real(8) function code(x_46re, x_46im, y_46re, y_46im)
real(8), intent (in) :: x_46re
real(8), intent (in) :: x_46im
real(8), intent (in) :: y_46re
real(8), intent (in) :: y_46im
real(8) :: t_0
real(8) :: tmp
t_0 = ((x_46im * y_46re) - (x_46re * y_46im)) / ((y_46re * y_46re) + (y_46im * y_46im))
if (y_46im <= (-8.8d+85)) then
tmp = ((y_46re * (x_46im / y_46im)) - x_46re) / y_46im
else if (y_46im <= (-3.8d-160)) then
tmp = t_0
else if (y_46im <= 3.75d-47) then
tmp = (x_46im - (x_46re * (y_46im / y_46re))) / y_46re
else if (y_46im <= 9.5d+145) then
tmp = t_0
else
tmp = ((y_46re / (y_46im / x_46im)) - x_46re) / y_46im
end if
code = tmp
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double t_0 = ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im));
double tmp;
if (y_46_im <= -8.8e+85) {
tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im;
} else if (y_46_im <= -3.8e-160) {
tmp = t_0;
} else if (y_46_im <= 3.75e-47) {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
} else if (y_46_im <= 9.5e+145) {
tmp = t_0;
} else {
tmp = ((y_46_re / (y_46_im / x_46_im)) - x_46_re) / y_46_im;
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): t_0 = ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im)) tmp = 0 if y_46_im <= -8.8e+85: tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im elif y_46_im <= -3.8e-160: tmp = t_0 elif y_46_im <= 3.75e-47: tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re elif y_46_im <= 9.5e+145: tmp = t_0 else: tmp = ((y_46_re / (y_46_im / x_46_im)) - x_46_re) / y_46_im return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = Float64(Float64(Float64(x_46_im * y_46_re) - Float64(x_46_re * y_46_im)) / Float64(Float64(y_46_re * y_46_re) + Float64(y_46_im * y_46_im))) tmp = 0.0 if (y_46_im <= -8.8e+85) tmp = Float64(Float64(Float64(y_46_re * Float64(x_46_im / y_46_im)) - x_46_re) / y_46_im); elseif (y_46_im <= -3.8e-160) tmp = t_0; elseif (y_46_im <= 3.75e-47) tmp = Float64(Float64(x_46_im - Float64(x_46_re * Float64(y_46_im / y_46_re))) / y_46_re); elseif (y_46_im <= 9.5e+145) tmp = t_0; else tmp = Float64(Float64(Float64(y_46_re / Float64(y_46_im / x_46_im)) - x_46_re) / y_46_im); end return tmp end
function tmp_2 = code(x_46_re, x_46_im, y_46_re, y_46_im) t_0 = ((x_46_im * y_46_re) - (x_46_re * y_46_im)) / ((y_46_re * y_46_re) + (y_46_im * y_46_im)); tmp = 0.0; if (y_46_im <= -8.8e+85) tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im; elseif (y_46_im <= -3.8e-160) tmp = t_0; elseif (y_46_im <= 3.75e-47) tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re; elseif (y_46_im <= 9.5e+145) tmp = t_0; else tmp = ((y_46_re / (y_46_im / x_46_im)) - x_46_re) / y_46_im; end tmp_2 = tmp; end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := Block[{t$95$0 = N[(N[(N[(x$46$im * y$46$re), $MachinePrecision] - N[(x$46$re * y$46$im), $MachinePrecision]), $MachinePrecision] / N[(N[(y$46$re * y$46$re), $MachinePrecision] + N[(y$46$im * y$46$im), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$46$im, -8.8e+85], N[(N[(N[(y$46$re * N[(x$46$im / y$46$im), $MachinePrecision]), $MachinePrecision] - x$46$re), $MachinePrecision] / y$46$im), $MachinePrecision], If[LessEqual[y$46$im, -3.8e-160], t$95$0, If[LessEqual[y$46$im, 3.75e-47], N[(N[(x$46$im - N[(x$46$re * N[(y$46$im / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y$46$re), $MachinePrecision], If[LessEqual[y$46$im, 9.5e+145], t$95$0, N[(N[(N[(y$46$re / N[(y$46$im / x$46$im), $MachinePrecision]), $MachinePrecision] - x$46$re), $MachinePrecision] / y$46$im), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{x.im \cdot y.re - x.re \cdot y.im}{y.re \cdot y.re + y.im \cdot y.im}\\
\mathbf{if}\;y.im \leq -8.8 \cdot 10^{+85}:\\
\;\;\;\;\frac{y.re \cdot \frac{x.im}{y.im} - x.re}{y.im}\\
\mathbf{elif}\;y.im \leq -3.8 \cdot 10^{-160}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;y.im \leq 3.75 \cdot 10^{-47}:\\
\;\;\;\;\frac{x.im - x.re \cdot \frac{y.im}{y.re}}{y.re}\\
\mathbf{elif}\;y.im \leq 9.5 \cdot 10^{+145}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{y.re}{\frac{y.im}{x.im}} - x.re}{y.im}\\
\end{array}
\end{array}
if y.im < -8.8000000000000007e85Initial program 43.7%
Taylor expanded in y.re around 0 72.4%
+-commutative72.4%
mul-1-neg72.4%
unsub-neg72.4%
unpow272.4%
associate-/r*78.3%
div-sub78.3%
*-commutative78.3%
associate-/l*88.3%
Simplified88.3%
if -8.8000000000000007e85 < y.im < -3.7999999999999998e-160 or 3.74999999999999984e-47 < y.im < 9.49999999999999948e145Initial program 84.1%
if -3.7999999999999998e-160 < y.im < 3.74999999999999984e-47Initial program 75.0%
Taylor expanded in y.re around inf 90.2%
mul-1-neg90.2%
unsub-neg90.2%
unsub-neg90.2%
remove-double-neg90.2%
mul-1-neg90.2%
neg-mul-190.2%
mul-1-neg90.2%
distribute-lft-in90.2%
distribute-lft-in90.2%
mul-1-neg90.2%
unsub-neg90.2%
neg-mul-190.2%
mul-1-neg90.2%
remove-double-neg90.2%
associate-/l*90.2%
Simplified90.2%
if 9.49999999999999948e145 < y.im Initial program 28.1%
Taylor expanded in y.re around 0 66.8%
+-commutative66.8%
mul-1-neg66.8%
unsub-neg66.8%
unpow266.8%
associate-/r*79.1%
div-sub79.1%
*-commutative79.1%
associate-/l*85.8%
Simplified85.8%
clear-num85.8%
un-div-inv85.8%
Applied egg-rr85.8%
Final simplification87.2%
(FPCore (x.re x.im y.re y.im) :precision binary64 (if (or (<= y.im -4.2e-20) (not (<= y.im 3.2e+14))) (/ x.re (- y.im)) (/ (- x.im (* x.re (/ y.im y.re))) y.re)))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if ((y_46_im <= -4.2e-20) || !(y_46_im <= 3.2e+14)) {
tmp = x_46_re / -y_46_im;
} else {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
}
return tmp;
}
real(8) function code(x_46re, x_46im, y_46re, y_46im)
real(8), intent (in) :: x_46re
real(8), intent (in) :: x_46im
real(8), intent (in) :: y_46re
real(8), intent (in) :: y_46im
real(8) :: tmp
if ((y_46im <= (-4.2d-20)) .or. (.not. (y_46im <= 3.2d+14))) then
tmp = x_46re / -y_46im
else
tmp = (x_46im - (x_46re * (y_46im / y_46re))) / y_46re
end if
code = tmp
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if ((y_46_im <= -4.2e-20) || !(y_46_im <= 3.2e+14)) {
tmp = x_46_re / -y_46_im;
} else {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): tmp = 0 if (y_46_im <= -4.2e-20) or not (y_46_im <= 3.2e+14): tmp = x_46_re / -y_46_im else: tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = 0.0 if ((y_46_im <= -4.2e-20) || !(y_46_im <= 3.2e+14)) tmp = Float64(x_46_re / Float64(-y_46_im)); else tmp = Float64(Float64(x_46_im - Float64(x_46_re * Float64(y_46_im / y_46_re))) / y_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_im <= -4.2e-20) || ~((y_46_im <= 3.2e+14))) tmp = x_46_re / -y_46_im; else tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_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$im, -4.2e-20], N[Not[LessEqual[y$46$im, 3.2e+14]], $MachinePrecision]], N[(x$46$re / (-y$46$im)), $MachinePrecision], N[(N[(x$46$im - N[(x$46$re * N[(y$46$im / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y$46$re), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y.im \leq -4.2 \cdot 10^{-20} \lor \neg \left(y.im \leq 3.2 \cdot 10^{+14}\right):\\
\;\;\;\;\frac{x.re}{-y.im}\\
\mathbf{else}:\\
\;\;\;\;\frac{x.im - x.re \cdot \frac{y.im}{y.re}}{y.re}\\
\end{array}
\end{array}
if y.im < -4.1999999999999998e-20 or 3.2e14 < y.im Initial program 53.6%
Taylor expanded in y.re around 0 65.8%
associate-*r/65.8%
neg-mul-165.8%
Simplified65.8%
if -4.1999999999999998e-20 < y.im < 3.2e14Initial program 79.5%
Taylor expanded in y.re around inf 83.1%
mul-1-neg83.1%
unsub-neg83.1%
unsub-neg83.1%
remove-double-neg83.1%
mul-1-neg83.1%
neg-mul-183.1%
mul-1-neg83.1%
distribute-lft-in83.1%
distribute-lft-in83.1%
mul-1-neg83.1%
unsub-neg83.1%
neg-mul-183.1%
mul-1-neg83.1%
remove-double-neg83.1%
associate-/l*83.1%
Simplified83.1%
Final simplification74.4%
(FPCore (x.re x.im y.re y.im) :precision binary64 (if (or (<= y.im -9.2e-24) (not (<= y.im 1.25e-30))) (/ (- (* y.re (/ x.im y.im)) x.re) y.im) (/ (- x.im (* x.re (/ y.im y.re))) y.re)))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if ((y_46_im <= -9.2e-24) || !(y_46_im <= 1.25e-30)) {
tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im;
} else {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
}
return tmp;
}
real(8) function code(x_46re, x_46im, y_46re, y_46im)
real(8), intent (in) :: x_46re
real(8), intent (in) :: x_46im
real(8), intent (in) :: y_46re
real(8), intent (in) :: y_46im
real(8) :: tmp
if ((y_46im <= (-9.2d-24)) .or. (.not. (y_46im <= 1.25d-30))) then
tmp = ((y_46re * (x_46im / y_46im)) - x_46re) / y_46im
else
tmp = (x_46im - (x_46re * (y_46im / y_46re))) / y_46re
end if
code = tmp
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if ((y_46_im <= -9.2e-24) || !(y_46_im <= 1.25e-30)) {
tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im;
} else {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): tmp = 0 if (y_46_im <= -9.2e-24) or not (y_46_im <= 1.25e-30): tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im else: tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = 0.0 if ((y_46_im <= -9.2e-24) || !(y_46_im <= 1.25e-30)) tmp = Float64(Float64(Float64(y_46_re * Float64(x_46_im / y_46_im)) - x_46_re) / y_46_im); else tmp = Float64(Float64(x_46_im - Float64(x_46_re * Float64(y_46_im / y_46_re))) / y_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_im <= -9.2e-24) || ~((y_46_im <= 1.25e-30))) tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im; else tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_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$im, -9.2e-24], N[Not[LessEqual[y$46$im, 1.25e-30]], $MachinePrecision]], N[(N[(N[(y$46$re * N[(x$46$im / y$46$im), $MachinePrecision]), $MachinePrecision] - x$46$re), $MachinePrecision] / y$46$im), $MachinePrecision], N[(N[(x$46$im - N[(x$46$re * N[(y$46$im / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y$46$re), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y.im \leq -9.2 \cdot 10^{-24} \lor \neg \left(y.im \leq 1.25 \cdot 10^{-30}\right):\\
\;\;\;\;\frac{y.re \cdot \frac{x.im}{y.im} - x.re}{y.im}\\
\mathbf{else}:\\
\;\;\;\;\frac{x.im - x.re \cdot \frac{y.im}{y.re}}{y.re}\\
\end{array}
\end{array}
if y.im < -9.2000000000000004e-24 or 1.24999999999999993e-30 < y.im Initial program 56.5%
Taylor expanded in y.re around 0 65.4%
+-commutative65.4%
mul-1-neg65.4%
unsub-neg65.4%
unpow265.4%
associate-/r*70.1%
div-sub70.1%
*-commutative70.1%
associate-/l*75.0%
Simplified75.0%
if -9.2000000000000004e-24 < y.im < 1.24999999999999993e-30Initial program 78.8%
Taylor expanded in y.re around inf 87.0%
mul-1-neg87.0%
unsub-neg87.0%
unsub-neg87.0%
remove-double-neg87.0%
mul-1-neg87.0%
neg-mul-187.0%
mul-1-neg87.0%
distribute-lft-in87.0%
distribute-lft-in87.0%
mul-1-neg87.0%
unsub-neg87.0%
neg-mul-187.0%
mul-1-neg87.0%
remove-double-neg87.0%
associate-/l*87.0%
Simplified87.0%
Final simplification80.4%
(FPCore (x.re x.im y.re y.im)
:precision binary64
(if (<= y.im -5.4e-25)
(/ (- (* y.re (/ x.im y.im)) x.re) y.im)
(if (<= y.im 7.8e-31)
(/ (- x.im (* x.re (/ y.im y.re))) y.re)
(/ (- (/ y.re (/ y.im x.im)) x.re) y.im))))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if (y_46_im <= -5.4e-25) {
tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im;
} else if (y_46_im <= 7.8e-31) {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
} else {
tmp = ((y_46_re / (y_46_im / x_46_im)) - x_46_re) / y_46_im;
}
return tmp;
}
real(8) function code(x_46re, x_46im, y_46re, y_46im)
real(8), intent (in) :: x_46re
real(8), intent (in) :: x_46im
real(8), intent (in) :: y_46re
real(8), intent (in) :: y_46im
real(8) :: tmp
if (y_46im <= (-5.4d-25)) then
tmp = ((y_46re * (x_46im / y_46im)) - x_46re) / y_46im
else if (y_46im <= 7.8d-31) then
tmp = (x_46im - (x_46re * (y_46im / y_46re))) / y_46re
else
tmp = ((y_46re / (y_46im / x_46im)) - x_46re) / y_46im
end if
code = tmp
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if (y_46_im <= -5.4e-25) {
tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im;
} else if (y_46_im <= 7.8e-31) {
tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re;
} else {
tmp = ((y_46_re / (y_46_im / x_46_im)) - x_46_re) / y_46_im;
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): tmp = 0 if y_46_im <= -5.4e-25: tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im elif y_46_im <= 7.8e-31: tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re else: tmp = ((y_46_re / (y_46_im / x_46_im)) - x_46_re) / y_46_im return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = 0.0 if (y_46_im <= -5.4e-25) tmp = Float64(Float64(Float64(y_46_re * Float64(x_46_im / y_46_im)) - x_46_re) / y_46_im); elseif (y_46_im <= 7.8e-31) tmp = Float64(Float64(x_46_im - Float64(x_46_re * Float64(y_46_im / y_46_re))) / y_46_re); else tmp = Float64(Float64(Float64(y_46_re / Float64(y_46_im / x_46_im)) - x_46_re) / y_46_im); 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_im <= -5.4e-25) tmp = ((y_46_re * (x_46_im / y_46_im)) - x_46_re) / y_46_im; elseif (y_46_im <= 7.8e-31) tmp = (x_46_im - (x_46_re * (y_46_im / y_46_re))) / y_46_re; else tmp = ((y_46_re / (y_46_im / x_46_im)) - x_46_re) / y_46_im; end tmp_2 = tmp; end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := If[LessEqual[y$46$im, -5.4e-25], N[(N[(N[(y$46$re * N[(x$46$im / y$46$im), $MachinePrecision]), $MachinePrecision] - x$46$re), $MachinePrecision] / y$46$im), $MachinePrecision], If[LessEqual[y$46$im, 7.8e-31], N[(N[(x$46$im - N[(x$46$re * N[(y$46$im / y$46$re), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y$46$re), $MachinePrecision], N[(N[(N[(y$46$re / N[(y$46$im / x$46$im), $MachinePrecision]), $MachinePrecision] - x$46$re), $MachinePrecision] / y$46$im), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y.im \leq -5.4 \cdot 10^{-25}:\\
\;\;\;\;\frac{y.re \cdot \frac{x.im}{y.im} - x.re}{y.im}\\
\mathbf{elif}\;y.im \leq 7.8 \cdot 10^{-31}:\\
\;\;\;\;\frac{x.im - x.re \cdot \frac{y.im}{y.re}}{y.re}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{y.re}{\frac{y.im}{x.im}} - x.re}{y.im}\\
\end{array}
\end{array}
if y.im < -5.40000000000000032e-25Initial program 60.7%
Taylor expanded in y.re around 0 68.6%
+-commutative68.6%
mul-1-neg68.6%
unsub-neg68.6%
unpow268.6%
associate-/r*72.3%
div-sub72.3%
*-commutative72.3%
associate-/l*78.6%
Simplified78.6%
if -5.40000000000000032e-25 < y.im < 7.8000000000000003e-31Initial program 78.8%
Taylor expanded in y.re around inf 87.0%
mul-1-neg87.0%
unsub-neg87.0%
unsub-neg87.0%
remove-double-neg87.0%
mul-1-neg87.0%
neg-mul-187.0%
mul-1-neg87.0%
distribute-lft-in87.0%
distribute-lft-in87.0%
mul-1-neg87.0%
unsub-neg87.0%
neg-mul-187.0%
mul-1-neg87.0%
remove-double-neg87.0%
associate-/l*87.0%
Simplified87.0%
if 7.8000000000000003e-31 < y.im Initial program 51.3%
Taylor expanded in y.re around 0 61.5%
+-commutative61.5%
mul-1-neg61.5%
unsub-neg61.5%
unpow261.5%
associate-/r*67.5%
div-sub67.5%
*-commutative67.5%
associate-/l*70.7%
Simplified70.7%
clear-num70.7%
un-div-inv70.8%
Applied egg-rr70.8%
Final simplification80.4%
(FPCore (x.re x.im y.re y.im) :precision binary64 (if (or (<= y.im -2.8e-32) (not (<= y.im 3.8e-30))) (/ x.re (- y.im)) (/ x.im y.re)))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if ((y_46_im <= -2.8e-32) || !(y_46_im <= 3.8e-30)) {
tmp = x_46_re / -y_46_im;
} else {
tmp = x_46_im / y_46_re;
}
return tmp;
}
real(8) function code(x_46re, x_46im, y_46re, y_46im)
real(8), intent (in) :: x_46re
real(8), intent (in) :: x_46im
real(8), intent (in) :: y_46re
real(8), intent (in) :: y_46im
real(8) :: tmp
if ((y_46im <= (-2.8d-32)) .or. (.not. (y_46im <= 3.8d-30))) then
tmp = x_46re / -y_46im
else
tmp = x_46im / y_46re
end if
code = tmp
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if ((y_46_im <= -2.8e-32) || !(y_46_im <= 3.8e-30)) {
tmp = x_46_re / -y_46_im;
} else {
tmp = x_46_im / y_46_re;
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): tmp = 0 if (y_46_im <= -2.8e-32) or not (y_46_im <= 3.8e-30): tmp = x_46_re / -y_46_im else: tmp = x_46_im / y_46_re return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = 0.0 if ((y_46_im <= -2.8e-32) || !(y_46_im <= 3.8e-30)) tmp = Float64(x_46_re / Float64(-y_46_im)); else tmp = Float64(x_46_im / y_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_im <= -2.8e-32) || ~((y_46_im <= 3.8e-30))) tmp = x_46_re / -y_46_im; else tmp = x_46_im / y_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$im, -2.8e-32], N[Not[LessEqual[y$46$im, 3.8e-30]], $MachinePrecision]], N[(x$46$re / (-y$46$im)), $MachinePrecision], N[(x$46$im / y$46$re), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y.im \leq -2.8 \cdot 10^{-32} \lor \neg \left(y.im \leq 3.8 \cdot 10^{-30}\right):\\
\;\;\;\;\frac{x.re}{-y.im}\\
\mathbf{else}:\\
\;\;\;\;\frac{x.im}{y.re}\\
\end{array}
\end{array}
if y.im < -2.7999999999999999e-32 or 3.8000000000000003e-30 < y.im Initial program 57.2%
Taylor expanded in y.re around 0 62.9%
associate-*r/62.9%
neg-mul-162.9%
Simplified62.9%
if -2.7999999999999999e-32 < y.im < 3.8000000000000003e-30Initial program 78.5%
Taylor expanded in y.re around inf 70.2%
Final simplification66.1%
(FPCore (x.re x.im y.re y.im) :precision binary64 (if (<= y.im -4e+192) (/ x.im (- y.im)) (/ x.im y.re)))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if (y_46_im <= -4e+192) {
tmp = x_46_im / -y_46_im;
} else {
tmp = x_46_im / y_46_re;
}
return tmp;
}
real(8) function code(x_46re, x_46im, y_46re, y_46im)
real(8), intent (in) :: x_46re
real(8), intent (in) :: x_46im
real(8), intent (in) :: y_46re
real(8), intent (in) :: y_46im
real(8) :: tmp
if (y_46im <= (-4d+192)) then
tmp = x_46im / -y_46im
else
tmp = x_46im / y_46re
end if
code = tmp
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if (y_46_im <= -4e+192) {
tmp = x_46_im / -y_46_im;
} else {
tmp = x_46_im / y_46_re;
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): tmp = 0 if y_46_im <= -4e+192: tmp = x_46_im / -y_46_im else: tmp = x_46_im / y_46_re return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = 0.0 if (y_46_im <= -4e+192) tmp = Float64(x_46_im / Float64(-y_46_im)); else tmp = Float64(x_46_im / y_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_im <= -4e+192) tmp = x_46_im / -y_46_im; else tmp = x_46_im / y_46_re; end tmp_2 = tmp; end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := If[LessEqual[y$46$im, -4e+192], N[(x$46$im / (-y$46$im)), $MachinePrecision], N[(x$46$im / y$46$re), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y.im \leq -4 \cdot 10^{+192}:\\
\;\;\;\;\frac{x.im}{-y.im}\\
\mathbf{else}:\\
\;\;\;\;\frac{x.im}{y.re}\\
\end{array}
\end{array}
if y.im < -4.00000000000000016e192Initial program 48.6%
Taylor expanded in y.im around inf 48.6%
*-commutative48.6%
associate-/l*48.6%
Simplified48.6%
*-commutative48.6%
add-sqr-sqrt48.6%
hypot-undefine48.6%
hypot-undefine48.6%
times-frac99.9%
fma-neg99.9%
hypot-undefine49.9%
+-commutative49.9%
hypot-undefine99.9%
hypot-undefine49.9%
+-commutative49.9%
hypot-undefine99.9%
Applied egg-rr99.9%
Taylor expanded in y.re around inf 29.7%
Taylor expanded in y.im around -inf 29.7%
neg-mul-129.7%
distribute-neg-frac229.7%
Simplified29.7%
if -4.00000000000000016e192 < y.im Initial program 68.5%
Taylor expanded in y.re around inf 48.4%
Final simplification46.4%
(FPCore (x.re x.im y.re y.im) :precision binary64 (if (<= y.im -1.6e+188) (/ x.im y.im) (/ x.im y.re)))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if (y_46_im <= -1.6e+188) {
tmp = x_46_im / y_46_im;
} else {
tmp = x_46_im / y_46_re;
}
return tmp;
}
real(8) function code(x_46re, x_46im, y_46re, y_46im)
real(8), intent (in) :: x_46re
real(8), intent (in) :: x_46im
real(8), intent (in) :: y_46re
real(8), intent (in) :: y_46im
real(8) :: tmp
if (y_46im <= (-1.6d+188)) then
tmp = x_46im / y_46im
else
tmp = x_46im / y_46re
end if
code = tmp
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
double tmp;
if (y_46_im <= -1.6e+188) {
tmp = x_46_im / y_46_im;
} else {
tmp = x_46_im / y_46_re;
}
return tmp;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): tmp = 0 if y_46_im <= -1.6e+188: tmp = x_46_im / y_46_im else: tmp = x_46_im / y_46_re return tmp
function code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = 0.0 if (y_46_im <= -1.6e+188) tmp = Float64(x_46_im / y_46_im); else tmp = Float64(x_46_im / y_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_im <= -1.6e+188) tmp = x_46_im / y_46_im; else tmp = x_46_im / y_46_re; end tmp_2 = tmp; end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := If[LessEqual[y$46$im, -1.6e+188], N[(x$46$im / y$46$im), $MachinePrecision], N[(x$46$im / y$46$re), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y.im \leq -1.6 \cdot 10^{+188}:\\
\;\;\;\;\frac{x.im}{y.im}\\
\mathbf{else}:\\
\;\;\;\;\frac{x.im}{y.re}\\
\end{array}
\end{array}
if y.im < -1.59999999999999985e188Initial program 48.6%
Taylor expanded in y.im around inf 48.6%
*-commutative48.6%
associate-/l*48.6%
Simplified48.6%
*-commutative48.6%
add-sqr-sqrt48.6%
hypot-undefine48.6%
hypot-undefine48.6%
times-frac99.9%
fma-neg99.9%
hypot-undefine49.9%
+-commutative49.9%
hypot-undefine99.9%
hypot-undefine49.9%
+-commutative49.9%
hypot-undefine99.9%
Applied egg-rr99.9%
Taylor expanded in y.re around inf 29.7%
Taylor expanded in y.im around inf 29.1%
if -1.59999999999999985e188 < y.im Initial program 68.5%
Taylor expanded in y.re around inf 48.4%
Final simplification46.4%
(FPCore (x.re x.im y.re y.im) :precision binary64 (/ x.im y.im))
double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
return x_46_im / y_46_im;
}
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 = x_46im / y_46im
end function
public static double code(double x_46_re, double x_46_im, double y_46_re, double y_46_im) {
return x_46_im / y_46_im;
}
def code(x_46_re, x_46_im, y_46_re, y_46_im): return x_46_im / y_46_im
function code(x_46_re, x_46_im, y_46_re, y_46_im) return Float64(x_46_im / y_46_im) end
function tmp = code(x_46_re, x_46_im, y_46_re, y_46_im) tmp = x_46_im / y_46_im; end
code[x$46$re_, x$46$im_, y$46$re_, y$46$im_] := N[(x$46$im / y$46$im), $MachinePrecision]
\begin{array}{l}
\\
\frac{x.im}{y.im}
\end{array}
Initial program 66.4%
Taylor expanded in y.im around inf 60.6%
*-commutative60.6%
associate-/l*59.1%
Simplified59.1%
*-commutative59.1%
add-sqr-sqrt59.1%
hypot-undefine59.1%
hypot-undefine59.1%
times-frac82.4%
fma-neg82.4%
hypot-undefine60.1%
+-commutative60.1%
hypot-undefine82.4%
hypot-undefine60.1%
+-commutative60.1%
hypot-undefine82.4%
Applied egg-rr82.4%
Taylor expanded in y.re around inf 27.5%
Taylor expanded in y.im around inf 10.4%
Final simplification10.4%
herbie shell --seed 2024055
(FPCore (x.re x.im y.re y.im)
:name "_divideComplex, imaginary part"
:precision binary64
(/ (- (* x.im y.re) (* x.re y.im)) (+ (* y.re y.re) (* y.im y.im))))