Integrals of the form $\int \frac{f(x)}{x^p \pm 1}$ or $\int \frac{f(x)}{e^x\pm 1}$ I have been recently running into integrals of the form $$\int\frac{f(x)}{x^p \pm 1}dx$$ and $$\int \frac{f(x)}{e^x \pm 1} dx$$
where $f(x)$ is ususally $x^q$ or $\sin x$. For example, $f(x) = x^3$ occurs in context of Stefan's Law and Wien's Law.
I have no idea how to proceed in such cases. Wolfram is also no help. Help with non-trivial special cases or in case of definite integration from $0$ to $\infty$ will also be much appreciated. 
 A: The definite integral of the second type may be treated by Mellin transforms.
Let $$ I(q) = \int_0^\infty \frac{x^q}{e^x-1} dx =
\int_0^\infty x^q e^{-x} \sum_{k\ge 0} e^{-kx} dx =
\sum_{k\ge 0} \int_0^\infty x^q e^{-(k+1)x} dx$$
with $q>1.$ The inner intgral is the Mellin transform of $e^{-(k+1)x}$ evaluated at $q+1$, so that $$ I(q) = \sum_{k\ge 0} \Gamma(q+1) \sum_{k\ge 0} \frac{1}{(k+1)^{q+1}} = \Gamma(q+1) \zeta(q+1).$$
Now suppose $q$ were an odd integer $q = 2m+1$ and recall that
$$\zeta(2n) = (-1)^{n+1} \frac{B_{2n} (2\pi)^{2n}}{2 (2n)!}$$ 
with $B_{2n}$ the Bernoulli numbers.
It follows that
$$I(2m+1) = (2m+1)! (-1)^m \frac{B_{2m+2} (2\pi)^{2m+2}}{2 (2m+2)!} =
\frac{(-1)^m  B_{2m+2} }{2(2m+2)} (2\pi)^{2m+2}.$$
A: Applying the technique from the previous post to the definite integral of the second type we obtain
Let $$ J(q) = \int_0^\infty \frac{x^q}{e^x+1} dx =
\int_0^\infty x^q e^{-x} \sum_{k\ge 0} (-1)^{k+1} e^{-kx} dx =
\sum_{k\ge 0}  (-1)^{k+1} \int_0^\infty x^q e^{-(k+1)x} dx$$
with $q>1.$ Once again the inner integral is the Mellin transform of $e^{-(k+1)x}$ evaluated at $q+1$, so that $$ J(q) = \sum_{k\ge 0} \Gamma(q+1) \sum_{k\ge 0} \frac{(-1)^{k+1}}{(k+1)^{q+1}} = \Gamma(q+1) \zeta(q+1) \left(1 - \frac{1}{2^q}\right).$$
It follows that
$$J(2m+1) = \left(1 - \frac{1}{2^{2m+1}}\right)
\frac{(-1)^m  B_{2m+2} }{2(2m+2)} (2\pi)^{2m+2}.$$
