The tanh() method returns a number that represents the hyperbolic tangent of a number.
The tanh() method returns a number that represents the hyperbolic tangent of a number.
Math.tanh(x)
Parameter | Require | Description |
---|---|---|
x | Required. | A number |
A Number
Return the hyperbolic tangent of a number:
//display the hyperbolic tangent of the number 1.
console.log(Math.tanh(1));