# Disagreement on Convergence of Integral between Mathematica and WolframAlpha

I am trying to do the integral $$\int_{-\infty}^{\infty} (1+\cos(t))\cosh(t)dt$$. Doing this on Mathematica gives me that the integral is equal to 0. However, doing this on WolframAlpha gives me that the integral does not converge. Why are the results different?

• I get it doesn't converge in Mathematica. Feb 23 at 17:37
• Me too in 13 on Windows 10. Feb 23 at 17:43
• I see, I'm doing this in 11.3. I will try updating and seeing what happens. Thanks! Feb 23 at 17:44
• It is obviously divergent Feb 23 at 18:40
• $\lim_{\delta \to \infty} \int_{-\delta}^{\delta}(1+\cos(t))\cosh(t) dt =0$ i.e. this is convergent in a very special sense. Feb 23 at 19:26

This is a bug specific to version 11.3 of Mathematica. The correct answer is non-convergence. Indeed since the integrand is even, we can compute the integral as

Limit[2 Integrate[(1 + Cos[t]) Cosh[t], {t, 0, b}], b -> \[Infinity]]
(* \[Infinity] *)


which evaluates correctly even in version 11.3. BTW, this disproves the comment that the limit of the integral over symmetric domains is zero. That could only happen for an odd function such as the following one

Limit[Integrate[(1 + Cos[t]) Sinh[t], {t, -b, b}], b -> \[Infinity]]
(* 0 *)

Limit[Integrate[(1 + Cos[t]) Sinh[t], {t, a, b}], {a, b} -> {-\[Infinity], \[Infinity]}]
(* Indeterminate *)

Integrate[(1 + Cos[t]) Sinh[t], {t, -\[Infinity], \[Infinity]}]
(* returns unevaluated with non-convergence message *)