atanh

Inverse hyperbolic tangent of each element.

Category: Mathematics > Elementary Math

Syntax

Y = atanh(X)

Returns the inverse hyperbolic tangent of each element of X.

Description

atanh(X) equals 0.5 * log((1 + X) ./ (1 - X)). It is odd, nearly linear for small X, and diverges as X approaches 1 or -1. Real input beyond that range gives a complex result with imaginary part pi/2.

Input arguments

X
Numeric array of any size. Complex values are allowed.

Output arguments

Y
Array of the same size as X. Real for abs(X) < 1, Inf at 1, complex for abs(X) > 1.

Example

Inverse hyperbolic tangent

atanh([0 0.5 -0.5 1])
atanh(2)
Output
ans = 1×4

         0    0.5493   -0.5493       Inf
ans = 0.5493 + 1.5708i

See also

tanh atan acoth asinh