JavaScript Math.atanh()
Definition and Usage
The Math.atanh() method returns the hyperbolic arctangent of a number.
Note: If the parameter x is greater than 1, or less than -1, the method will return NaN.
Note: If the parameter x is 1, the method will return Infinity.
Note: If the parameter x is -1, the method will return -Infinity.
Browser Support
Math.atanh()
is an ECMAScript6 (ES6) feature.
ES6 (JavaScript 2015) is supported in all modern browsers:
Chrome | Edge | Firefox | Safari | Opera |
Yes | Yes | Yes | Yes | Yes |
Math.atanh()
is not supported in Internet Explorer 11 (or earlier).
Syntax
Math.atanh(x)
Parameter Values
Parameter | Description |
---|---|
x | Required. A number. |
Return Value
A number, or NaN, or Infinity, or -Infinity. |