function
<cmath> <ctgmath>
acosh
double acosh (double x);
float acoshf (float x);
long double acoshl (long double x);
double acosh (double x);
float acosh (float x);
long double acosh (long double x);
double acosh (T x); // additional overloads for integral types
Compute area hyperbolic cosine
Returns the nonnegative area hyperbolic cosine of x.
The area hyperbolic cosine is the inverse operation of the hyperbolic cosine.
Header
<tgmath.h> provides a type-generic macro version of this function.
Parameters
- x
- Value whose area hyperbolic cosine is computed.
If the argument is less than 1
, a domain error occurs.
Example
1 2 3 4 5 6 7 8 9 10 11 12
|
/* acosh example */
#include <stdio.h> /* printf */
#include <math.h> /* acosh, exp, sinh */
int main ()
{
double param, result;
param = exp(2) - sinh(2);
result = acosh(param) ;
printf ("The area hyperbolic cosine of %f is %f radians.\n", param, result);
return 0;
}
| |
Output:
The area hyperbolic cosine of 3.762196 is 2.000000 radians.
|
See also
- cosh
- Compute hyperbolic cosine (function
)
- asinh
- Compute area hyperbolic sine (function
)