1acosh(3M) Mathematical Library Functions acosh(3M)
2
3
4
6 acosh, acoshf, acoshl - inverse hyperbolic cosine functions
7
9 c99 [ flag... ] file... -lm [ library... ]
10 #include <math.h>
11
12 double acosh(double x);
13
14
15 float acoshf(float x);
16
17
18 long double acoshl(long double x);
19
20
22 These functions compute the inverse hyperbolic cosine of their argument
23 x.
24
26 Upon successful completion, these functions return the inverse hyper‐
27 bolic cosine of their argument.
28
29
30 For finite values of x < 1, a domain error occurs and NaN is returned.
31
32
33 If x is NaN, NaN is returned.
34
35
36 If x is +1, +0 is returned.
37
38
39 If x is +Inf, +Inf is returned.
40
41
42 If x is −Inf, a domain error occurs and NaN is returned.
43
44
45 For exceptional cases, matherr(3M) tabulates the values to be returned
46 by acosh() as specified by SVID3 and XPG3.
47
49 These functions will fail if:
50
51 Domain Error The x argument is finite and less than 1.0, or is −Inf.
52
53 If the integer expression (math_errhandling &
54 MATH_ERREXCEPT) is non-zero, the invalid floating-point
55 exception is raised.
56
57 The acosh() function sets errno to EDOM if x is less
58 than 1.0.
59
60
62 An application wanting to check for exceptions should call feclearex‐
63 cept(FE_ALL_EXCEPT) before calling these functions. On return, if
64 fetestexcept(FE_INVALID | FE_DIVBYZERO | FE_OVERFLOW | FE_UNDERFLOW) is
65 non-zero, an exception has been raised. An application should either
66 examine the return value or check the floating point exception flags to
67 detect exceptions.
68
69
70 An application can also set errno to 0 before calling acosh(). On
71 return, if errno is non-zero, an error has occurred. The acoshf() and
72 acoshl() functions do not set errno.
73
75 See attributes(5) for descriptions of the following attributes:
76
77
78
79
80 ┌─────────────────────────────┬─────────────────────────────┐
81 │ ATTRIBUTE TYPE │ ATTRIBUTE VALUE │
82 ├─────────────────────────────┼─────────────────────────────┤
83 │Interface Stability │Standard │
84 ├─────────────────────────────┼─────────────────────────────┤
85 │MT-Level │MT-Safe │
86 └─────────────────────────────┴─────────────────────────────┘
87
89 cosh(3M), feclearexcept(3M), fetestexcept(3M), math.h(3HEAD), math‐
90 err(3M), attributes(5), standards(5)
91
92
93
94SunOS 5.11 12 Jul 2006 acosh(3M)