Residue integral: $\int_{- \infty}^{+ \infty} \frac{e^{ax}}{1+e^x} dx$ with $0 \lt a \lt 1$. I'm self studying complex analysis. I've encountered the following integral:
$$\int_{- \infty}^{+ \infty} \frac{e^{ax}}{1+e^x} dx \text{ with } a \in \mathbb{R},\  0 \lt a \lt 1. $$
I've done the substitution $e^x = y$. What kind of contour can I use in this case ?

there is a nice question related with this problem , and we can evaluate it by using Real analysis
$$I=\int_{-\infty }^{\infty }\frac{e^{ax}}{1-e^{x}}dx,\ \ \ \ \ \ \ \     (*)\ \ \ \ \ 0<a<1\\
\\
let \ x\rightarrow -x \ \ then\ \ I=\int_{-\infty }^{\infty }\frac{e^{-ax}}{1-e^{-x}}\ \ \ \ \ (**)\\
\\
adding\ (*)\ and\ (**)\ \ then\  2I=\int_{-\infty }^{\infty }[\frac{e^{ax}}{1-e^x}+\frac{e^{-ax}}{1-e^{-x}}]dx\\
\\
\therefore I=\frac{1}{2}\int_{-\infty }^{\infty }(\frac{e^{-ax}}{1-e^{-x}}-\frac{e^{-(1-a)x}}{1-e^{-x}})dx\\
\\
\therefore I==\frac{1}{2}\int_{-\infty }^{\infty }[(\frac{e^{-x}}{x}-\frac{e^{-(1-a)x}}{1-e^{-x}})-(\frac{e^{-x}}{x}-\frac{e^{-ax}}{1-e^{-x}})]dx\\
\\
\\
\therefore \therefore I=\int_{0}^{\infty }(\frac{e^{-x}}{x}-\frac{e^{-(1-a)x}}{1-e^{-x}})dx-\int_{0}^{\infty }(\frac{e^{-x}}{x}-\frac{e^{-ax}}{1-e^{-x}})dx\\
\\
\\
\therefore I=\Psi (1-a)-\Psi (a)=\frac{\pi }{tan(\pi a)}$$
this problem proposed by cornel loan, it is very easy to solve by complex analysis, but splendid to evaluate by"Real analysis"
