Sign in
cobalt
/
cobalt
/
286dd7840608e9cf78bc4a603ff2ec2ee39750c5
/
.
/
src
/
third_party
/
musl
/
src
/
complex
/
ctan.c
blob: c09263744b869b92e03fc5c956a18178b089d655 [
file
] [
log
] [
blame
]
#include
"libm.h"
/* tan(z) = -i tanh(i z) */
double
complex ctan
(
double
complex z
)
{
z
=
ctanh
(
CMPLX
(-
cimag
(
z
),
creal
(
z
)));
return
CMPLX
(
cimag
(
z
),
-
creal
(
z
));
}