The TANH function returns the hyperbolic tangent of X.

The value for which the hyperbolic tangent is desired, specified in radians. If *
X*
is double-precision floating-point, the result is also double-precision. Complex values are not allowed. All other types are converted to single-precision floating-point and yield floating-point results. TANH is defined as:

If *
X*
is an array, the result has the same structure, with each element containing the hyperbolic tangent of the corresponding element of *
X*
.