Python - math.atanh() Function
The Python math.atanh() function returns inverse hyperbolic tangent of a value. The hyperbolic tangent of x is defined as:
Syntax
math.atanh(x)
Parameters
x |
Required. Specify the value. |
Return Value
Returns the hyperbolic tangent of a value.
Example:
In the below example, atanh() function is used to find out the hyperbolic tangent of a value.
import math print(math.atanh(0.1)) print(math.atanh(0.5)) print(math.atanh(2))
The output of the above code will be:
0.10033534773107558 0.5493061443340548 ValueError: math domain error
❮ Python Math Module