tanH function

double tanH(
  1. double x
)

Implementation

double tanH(double x) {
  return (math.exp(2 * x) - 1) / (math.exp(2 * x) + 1);
}