Pré. | Proc. |
clog
Complex natural logarithm.SYNOPSIS:
void clog();
cmplx z, w;
clog(&z, &w);
DESCRIPTION:
Returns a complex logarithm to the base e (2.718...) of the complex argument x.
If z = x + iy, r = sqrt(x**2 + y**2),
then
w = log(r) + i arctan(y/x).
The arctangent ranges from -PI to +PI.
ACCURACY:
Relative error:
arithmetic domain # trials peak rms
DEC -10,+10 7000 8.5e-17 1.9e-17
IEEE -10,+10 30000 5.0e-15 1.1e-16
Larger relative errors can be observed for z near 1 +i0. In IEEE arithmetic the peak absolute error is 5.2e-16, rms absolute error 1.0e-16.