# Unable to integrate a function

In the below integral, given that $a$, $\sigma$, $\epsilon$ are constants, how do I pull them outside the integration sign? $$E =\int_{0}^{\pi}{\frac{a^2\sigma \sin\theta}{2\epsilon\sqrt{a^2-x^2-2ax\cos\theta}}d\theta}$$

In fact i need to show that $$E = \frac{a^2\sigma}{\epsilon x}$$

-
Is $x$ supposed to be $\theta$? –  Jean-Sébastien Sep 10 '12 at 15:21
The formula for E is false. Try x=0. –  Did Sep 10 '12 at 15:28

I suppose you have an error on $-x^2$.
If you set $t=\sqrt{a^2+x^2-2ax\cos\theta}$, you have
$$dt=\frac{ax\sin\theta}{\sqrt{a^2+x^2-2ax\cos\theta}}d\theta$$
so that the integral becomes (supposing $x+a>0$ and $x-a>0$)
$$E=\int_{x-a}^{x+a}\frac{a\sigma}{2\epsilon x}dt=\frac{a^2\sigma}{\epsilon x}$$