function asinh( x ) {
	var sgn;
	var xx;
	var t;
	if ( isnan( x ) || isinfinite( x ) ) {
		return x;
	}
	if ( x < 0.0 ) {
		x = -x;
		sgn = true;
	}
	// Case: |x| < 2**-28
	if ( x < NEAR_ZERO ) {
		t = x;
	}
	// Case: |x| > 2**28
	else if ( x > HUGE ) {
		t = ln( x ) + LN2;
	}
	// Case: 2**28 > |x| > 2.0
	else if ( x > 2.0 ) {
		t = ln( (2.0*x) + ( 1.0 / (sqrt( (x*x) + 1.0 ) + x) ) );
	}
	// Case: 2.0 > |x| > 2**-28
	else {
		xx = x * x;
		t = log1p( x + ( xx/(1.0 + sqrt(1.0 + xx)) ) );
	}
	return ( sgn ) ? -t : t;
}
Computes the hyperbolic arcsine of a double-precision floating-point number.

## Method

Based on

```tex
\operatorname{asinh}(x) = \operatorname{sgn}(x) \cdot \log \left( |x| + \sqrt{x^2 + 1} \right)
```

we have

```tex
\operatorname{asinh}(x) = \begin{cases}
x  & \text{ if }  1+x^2 =1, \\
\operatorname{sgn}(x) \cdot \left( \log(x) + \tfrac{\ln}{2} \right) & \text{ if large } |x| \\
\operatorname{sgn}(x) \cdot \log\left( 2 |x| + 1 / ( |x|+ \sqrt{x^2+1} ) \right) & \text{ if } |x| > 2 \\
\operatorname{sgn}(x) \cdot \operatorname{log1p}\left( |x| + \tfrac{x^2}{1 + \sqrt{1+x^2}} \right) & \text{otherwise}
\end{cases}
```

@param {number} x - input value
@returns {number} hyperbolic arcsine

@example
var v = asinh( 0.0 );
// returns 0.0

@example
var v = asinh( 2.0 );
// returns ~1.444

@example
var v = asinh( -2.0 );
// returns ~-1.444

@example
var v = asinh( NaN );
// returns NaN