Namespaces
Variants
Views
Actions

asinh, asinhf, asinhl

From cppreference.com
< c‎ | numeric‎ | math
Revision as of 20:18, 29 May 2014 by Cubbi (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
 
 
 
Common mathematical functions
Functions
Basic operations
(C99)
(C99)
(C99)
(C99)
(C99)
(C99)(C99)(C99)
Exponential functions
(C99)
(C99)
(C99)
(C99)
Power functions
(C99)
(C99)
Trigonometric and hyperbolic functions
asinh
(C99)
(C99)
(C99)
Error and gamma functions
(C99)
(C99)
(C99)
(C99)
Nearest integer floating point operations
(C99)(C99)(C99)
(C99)
(C99)(C99)(C99)
Floating point manipulation functions
(C99)(C99)
(C99)
(C99)
Classification
(C99)
(C99)
(C99)
Macro constants
 
Defined in header <math.h>
float       asinhf( float arg );
(1) (since C99)
double      asinh( double arg );
(2) (since C99)
long double asinhl( long double arg );
(3) (since C99)
Defined in header <tgmath.h>
#define asinh( arg )
(4) (since C99)
1-3) Computes the inverse hyperbolic sine of arg
4) Type-generic macro: If the argument has type long double, asinhl is called. Otherwise, if the argument has integer type or the type double, asinh is called. Otherwise, asinhf is called. If the argument is complex, then the macro invokes the corresponding complex function (casinhf, casinh, casinhl)

Contents

[edit] Parameters

arg - floating point value representing the area of a hyperbolic sector

[edit] Return value

If no errors occur, the inverse hyperbolic sine of arg (sinh-1
(arg)
, or arsinh(arg)), is returned.

If a range error occurs due to underflow, the correct result (after rounding) is returned.

[edit] Error handling

Errors are reported as specified in math_errhandling

If the implementation supports IEEE floating-point arithmetic (IEC 60559),

  • if the argument is ±0 or ±∞, it is returned unmodified
  • if the argument is NaN, NaN is returned

[edit] Notes

Although the C standard names this function "arc hyperbolic sine", the inverse functions of the hyperbolic functions are the area functions. Their argument is the area of a hyperbolic sector, not an arc. The correct name is "inverse hyperbolic sine" (used by POSIX) or "area hyperbolic sine".

[edit] Example

#include <stdio.h>
#include <math.h>
 
int main(void)
{
    printf("asinh(1) = %f\nasinh(-1) = %f\n", asinh(1), asinh(-1));
    // special values
    printf("asinh(+0) = %f\nasinh(-0) = %f\n", asinh(0.0), asinh(-0.0));
}

Output:

asinh(1) = 0.881374
asinh(-1) = -0.881374
asinh(+0) = 0.000000
asinh(-0) = -0.000000

[edit] See also

(C99)(C99)(C99)
computes inverse hyperbolic cosine (arcosh(x))
(function) [edit]
(C99)(C99)(C99)
computes inverse hyperbolic tangent (artanh(x))
(function) [edit]
(C99)(C99)
computes hyperbolic sine (sh(x))
(function) [edit]
(C99)(C99)(C99)
computes the complex arc hyperbolic sine
(function) [edit]

[edit] External links

Weisstein, Eric W. "Inverse Hyperbolic Sine." From MathWorld--A Wolfram Web Resource.