How to chose the rectangle to solve $\int_{{\textstyle\ -\infty}}^{{\textstyle\infty} } \frac{\mathrm{cos(x)}}{e^{x}+e^{-x}} dx$ with residues?
I tried 2 options:
- Option 1: Rectangle lies on the x-axes
- Option 2: x-axes is in the rectangle
What is the correct option, and why it is? I become two different answers... It's logic, because I used a different parameterization...
See pictures:



