Computes the hyperbolic tangent function.