[Main]
Name=csqrt
Type=Function
Subtype=ROM Call
Header Files=math.h, timath.h
Definition=void csqrt (float z_re, float z_im, float *w_re, float *w_im);

[ROM Call]
Index=$146

[Description]
Complex square root.

[Explanation]
csqrt calculates the square root w&nbsp;=&nbsp;sqrt(z) of the complex number which real and
imaginary parts are <I>z_re</I> and <I>z_im</I>, and stores real and
imaginary part of the result in floating point destinations pointed to by
<I>w_re</I> and <I>w_im</I>. The complex square root is defined by
<BR><BR>
sqrt(z)&nbsp;=&nbsp;sqrt(abs(z))&nbsp;(cos(arg(z)/2)&nbsp;+&nbsp;<I>i</I>&nbsp;sin(arg(z)/2))
<BR><BR>
where abs(z)&nbsp;=&nbsp;sqrt(z_re^2+z_im^2) and arg(z)&nbsp;=&nbsp;atan2(z_im, z_re).
See <A HREF="$$LINK(sqrt)">sqrt</A>, <A HREF="$$LINK(atan2)">atan2</A>,
<A HREF="$$LINK(sin)">sin</A> and <A HREF="$$LINK(cos)">cos</A>.

[References]
Out=unknown.h/_bcd_math
In=basfunc.h/push_sqrt
