# Improper integrals: singularity on REAL axis (complex variab

Hello everyone! I'm having some troubles when I try to solve improper integrals exercises that have singularities on the real axis. I have made a lot of exercises where singularities are inside a semicircle in the upper half side, but I don't know how to solve them when the singularities are on the real axis.
I read some books but I think they are not very good explained (at least, I can't understood them).

This is the exercise:
$$\int_{-\infty}^{\infty} \frac{cos(2\pi x)}{x^2-1} dx$$

Using complex variable, I have:
$$f(z) =\frac{exp(i2\pi z)}{z^2-1}$$
so there are 2 singularities:
$$z_1 = -1$$ and $$z_2 = 1$$
I use a curve $$C$$ that is holomorphic inside it, because both singularities are out of it. Of course, I can divide $$C$$ in 6 curves: $$C_R$$ that is the "roof" of the curve and, using Jordan's Lemma, I can prove that
$$\int_{C_R}^{ } \frac{exp(i2\pi z)}{z^2-1} dx = 0$$
but I don't know what do I have to do now. I saw in some places they said that the Residue Theorem over the semicircle around the singularities was something like $$-i\pi\sum{}{}Res[f(z), z_k]$$ but I didn't understand why.

I hope you can help me, because I don't know what can I do.
Thanks!!

Let $C$ be the curve consisting of a half circle in the upper half plane with center in 0 (radius R) and the real axis - except for two half circles in the lower half plane around -1 and +1 with radius ε. Now let us consider what happens around z = 1 (the case around z = -1 is handled the same way).
For ε<0.1 we can write $f(z)=\frac{e^{2\pi i z}}{z^{2}-1}=\frac{0.5}{z-1}+A(z)$, where $A(z)$ is analytic at z = 1. Now we have $\int_{0}^{R}f(z)dz =\int_{0}^{1-\epsilon}f(z)dz + \int_{-\pi}^{0}0.5\cdot id\phi + \int_{1+\epsilon}^{R}f(z)dz$. Let ε→0, and we end up with $\int_{0}^{R}f(z)dz +i \frac{\pi}{2}$. Do the same with z = -1, and you end up with the formula you "didn't understand".