atanh

atanh(x)

Try it yourself:

See also:

atanh(): the inverse hyperbolic tangent

atanh(x) returns the inverse hyperbolic tangent of x. It answers the question: which value y has tanh(y) = x? It is useful when rearranging models involving hyperbolic curves, logarithms, or transformed correlation-like values.

Formula and valid inputs

For real numbers, atanh(x) = 0.5 · ln((1 + x)/(1 − x)). Its real domain is strictly between −1 and 1. For example, atanh(0) is 0 and atanh(0.5) is about 0.5493. As x approaches 1 or −1, the result grows without bound; inputs at or beyond those endpoints need complex-number handling or are not real-valued.

Working with hyperbolic functions

The natural companion is tanh(): applying it to a valid atanh result recovers the original input. The related asinh() and acosh() functions invert the other hyperbolic functions. When you need the logarithmic form explicitly, use log(); do not confuse atanh with the ordinary inverse tangent atan().

Practical care

Keep full precision until the end of a calculation, particularly near ±1. Check that a measurement or normalized value is in range before calling atanh, and remember that rounding can accidentally turn 0.999999999 into 1. Use abs() to test distance from the boundary when validating data.

All functions