I have been self-studying CA and find it very interesting. So, working through problems in a book I have, I ran across
$$\int_{0}^{\infty}\frac{\sin(ax)}{e^{2\pi x}-1}dx=\frac{1}{4}\coth(a/2)-\frac{1}{2a}$$
and $$\int_{0}^{\infty}\frac{\sin(ax)}{e^{x}+1}dx=\frac{1}{2a}-\frac{\pi}{2\sinh(\pi a)}$$
For the former, I wrote it as $\frac{e^{aiz}}{e^{2\pi z}-1}$ and used a rectangular contour with vertices $0, \;\ R. \;\ R+i, \;\ i$
$e^{2\pi z}-1$ has poles at $ni$. Of these, I think $i$ only lies within the contour.
Unless I am in error, I then calculated the residue at $i$ to be $\frac{e^{-a}}{2\pi}$
So, $2\pi i(\frac{e^{-a}}{2\pi})=ie^{-a}$
Now, where I get hung up is setting up the integrals around the contour. Two of which should tend to 0 as $R\to \infty$.
Here is what I done.
$$\int_{0}^{R}\frac{e^{iax}}{e^{2\pi x}-1}dx+\int_{0}^{\infty}\frac{e^{ai(R+iy)}}{e^{2\pi (R+iy)}-1}idy+\int_{R}^{0}\frac{e^{ai(x+i)}}{e^{2\pi (x+i)}-1}dx+\int_{\infty}^{0}\frac{e^{ai(iy)}}{e^{2\pi iy}-1}dy=-\sinh(a)$$
I am unsure of the limits on the second and fourth integrals.
I am not so sure this is correct. The second and fourth ones, which represent the vertical sides, should tend to 0 as $R\to\infty$. I hope :).
This than gave me $(1-e^{-a})\int\frac{e^{iax}}{e^{2\pi x}-1}dx=-\sinh(a)$.
Which does not look correct. I did manage to solve this using series and $\pi csc(\pi z)$, but the contour I am unsure of.
Can someone lend a hand here?. Any advice on either would be appreciated.
For the other one, I only posted it because it looks similar, but I believe is actually more involved and 'tougher' if you will. If I can get one, perhaps I can manage to evaluate the other.
With that one, I think the same rectangle with the same vertices can be used, but $\pi i$ would have to be avoided. Perhaps a Principal Value in there somewhere. But, I was told to use vertices $0, \;\ R, \;\ R+2\pi i, \;\ 2\pi i$
Since I am relatively new to CA, setting up those integrals is the confusing part.
I can do easier types of contour integrals, but want to learn more about these more challenging ones.
Thanks for any assistance.