Domain error at the integrand using QuadGK

tanh(x) tends to \pm 1 as x\rightarrow \pm \infty. So the integral you want to evaluate diverges.

3 Likes