Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

integrate(x/(exp(2*pi*x)-1), (x, 0, oo)) can not be calculated #14066

Open
ghost opened this issue Feb 2, 2018 · 7 comments
Open

integrate(x/(exp(2*pi*x)-1), (x, 0, oo)) can not be calculated #14066

ghost opened this issue Feb 2, 2018 · 7 comments

Comments

@ghost
Copy link

ghost commented Feb 2, 2018

The result is 1/24

>>> integrate(x/(exp(2*pi*x)-1), (x, 0, oo))
Integral(x/((exp(pi*x) - 1)*(exp(pi*x) + 1)), (x, 0, oo))

Wolfram alpha can't do it either

@ghost
Copy link
Author

ghost commented Feb 2, 2018

Closely related to #8169

@tverticalis
Copy link

My Wolfram Mathematica 11.2 calculated it in 0.1 sec. If "-1" is replaced with "+1", Mathematica gives 1/48. I posted a similar issue a few days ago (#14035). My feeling is SymPy's integration is not yet ready for prime time.

@ghost
Copy link
Author

ghost commented Feb 2, 2018

@tverticalis, if SymPy was successful with integrate(x/(exp(2*pi*x)-1), (x, 0, oo)) then I was going to test it with integrate(sin(a*x)/(exp(2*pi*x)-1), (x, 0, oo))
And if SymPy was successful with integrate(x**2/cosh(x), (x, 0, oo)), then I was going to test it with integrate(x**(2*n)/cosh(x), (x, 0, oo))

@tverticalis
Copy link

The first integral yields ConditionalExpression[(-2 + a Coth[a/2])/(4 a), Abs[Im[a]] < 2 Pi].
The second one ConditionalExpression[
2^(-4 n) n Gamma[2 n] (Zeta[1 + 2 n, 1/4] - Zeta[1 + 2 n, 3/4]),
Re[n] > -(1/2)].

@ghost
Copy link
Author

ghost commented Feb 3, 2018

The 2nd integral can be expressed more cleanly, it is a rational multiple of pi**(2n+1), and the rational number can be written explicitly in terms of Euler's numbers (I was implicitly assuming that n is a nonnegative integer)
A similar, but perhaps more attractive integral is integrate(cosh(a*x)/cosh(x), (x, 0, oo)), which evaluates to pi/(2*cos((pi*a)/2))

@tverticalis
Copy link

This level of analytical depth/elegance may be too much for automated systems.
Assuming[n > 0 && n [Element] Integers, Integrate[x^(2*n)/Cosh[x], {x, 0, Infinity}]] // FullSimplify
2^(-1 - 4 n) (-PolyGamma[2 n, 1/4] + PolyGamma[2 n, 3/4])

@ghost
Copy link
Author

ghost commented Feb 4, 2018

I'm amazed that symbolic algebra systems can compute so many sums and integrals in terms of polylogs and polygammas, completely different to the way I do it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants