numerically really stable tanh