diff options
Diffstat (limited to 'lib/libm/ccoshf.c')
| -rw-r--r-- | lib/libm/ccoshf.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/libm/ccoshf.c b/lib/libm/ccoshf.c new file mode 100644 index 00000000..12fc7e6d --- /dev/null +++ b/lib/libm/ccoshf.c @@ -0,0 +1,12 @@ +#include <math.h> +#include <complex.h> + +float complex ccoshf(float complex z) +{ + float x, y; + + x = crealf(z); + y = cimagf(z); + + return coshf(x) * cosf(y) + (sinhf(x) * sinf(y)) * I; +} |
