# How to evaluate $\int_{-\infty}^\infty {e^{ax} \over 1 +e^x } \; dx$ [duplicate]

Given that $0 < a < 1$ how to evaluate by the method of residues $$\int_{-\infty}^\infty {e^{ax} \over 1 +e^x } \; dx$$

-

## marked as duplicate by Pedro Tamaroff♦, William, Did, Noah Snyder, J. M.Oct 5 '12 at 12:58

In particular, see Argon's answer to that question. – Pedro Tamaroff Sep 5 '12 at 19:30
@PeterTamaroff how did you change the sum into integral? – hasExams Sep 6 '12 at 4:23
I explain it in detail in the question. – Pedro Tamaroff Sep 6 '12 at 13:11

Substituting $u=e^x$, so that $dx = \dfrac{du}{u}$, the integral becomes

$$\int_0^{\infty} \dfrac{u^{a-1}}{1+u}du$$

How might you solve this? You've tagged the question as homework, so I'll leave it here for now, but if you're still stuck, post in the comments.

-
does this method work when $0<a<1$ ? this needs a little editing and picture of contour is missing – hasExams Sep 5 '12 at 16:18
@testuser: Yes. – Clive Newstead Sep 5 '12 at 16:19
I must be an idiot :((( – hasExams Sep 5 '12 at 16:20
@testuser: Possible, but unlikely! Just follow through that solution with $b=1$ all the way through. [Or work it out yourself $-$ it's not too hard using fairly standard complex methods.] – Clive Newstead Sep 5 '12 at 16:22
yeah the answer is $\pi \over \sin (a \pi )$ – hasExams Sep 5 '12 at 16:24

Recalling the $\beta$ function,

$$\beta( n,m ) = \int_{0}^{1} u^{n-1}\,(1-u)^{m-1}\, du = \frac{\Gamma(n)\Gamma(m)}{\Gamma(m+n)} \,.$$

Using the substitution $1+u=\frac{1}{t}$ casts $\int_0^{\infty} \dfrac{u^{a-1}}{1+u}du$ in terms of the $\beta$ function,

$$\int_0^{\infty} \frac{u^{a-1}}{1+u}du = \int _{0}^{1}\!{t}^{-a} \left( 1-t \right) ^{a-1}{dt} =\Gamma(a)\Gamma(1-a) = \frac{\pi}{\sin (a \pi )} \,.$$

-
@Downvoter:I do not know what you are downvoting for. I gave a way to evaluate the integral in a way different from the complex techniques. – Mhenni Benghorbal Sep 5 '12 at 21:04