2 /* @(#)z_cosh.c 1.0 98/08/13 */
7 <<cosh>>, <<coshf>>---hyperbolic cosine
11 double cosh(double <[x]>);
12 float coshf(float <[x]>);
16 <<cosh>> computes the hyperbolic cosine of the argument <[x]>.
17 <<cosh(<[x]>)>> is defined as
19 . (exp(x) + exp(-x))/2
22 $${(e^x + e^{-x})} \over 2$$
25 Angles are specified in radians.
27 <<coshf>> is identical, save that it takes and returns <<float>>.
30 The computed value is returned. When the correct value would create
31 an overflow, <<cosh>> returns the value <<HUGE_VAL>> with the
32 appropriate sign, and the global value <<errno>> is set to <<ERANGE>>.
36 <<coshf>> is an extension.
43 /******************************************************************
47 * x - floating point value
50 * hyperbolic cosine of x
53 * This routine returns the hyperbolic cosine of x.
55 *****************************************************************/
60 #ifndef _DOUBLE_IS_32BITS
65 return (sineh (x
, 1));
68 #endif /* _DOUBLE_IS_32BITS */