cacos.c 266 B

1234567891011
  1. #include "libm.h"
  2. // FIXME: Hull et al. "Implementing the complex arcsine and arccosine functions using exception handling" 1997
  3. /* acos(z) = pi/2 - asin(z) */
  4. double complex cacos(double complex z)
  5. {
  6. z = casin(z);
  7. return CMPLX(M_PI_2 - creal(z), -cimag(z));
  8. }