# Trying to solve improper integral

I've been trying to solve this $$\int_{-\infty}^\infty {\sin(x)\over x+1-i }dx$$ using residue theorem. I've tried using a square contour pi, pi+pii, -pi+pii, pi and half a circle but with the former had trouble with the upper contour (pii+pi to pii-pi) and with the circle I couldn't prove the upper contour when integrated to be 0

• Put $$\sin(x)=\frac{\exp(ix) - \exp(-ix)}{2i}$$ split the integral in two parts, each with one term of the exponential and then close the contour in the first integral in the upper half plane while you close it in the lower half plane for the latter. – Count Iblis Jun 17 '16 at 19:50
• @b00nheT: Jordan's lemma does not apply to the sine function alone, since it has an exponential grow along the imaginary axis. – Jack D'Aurizio Jun 17 '16 at 19:56
• You're right. My fault – b00n heT Jun 17 '16 at 19:57
• You can try and show real part of $\sin(a+bi) + \sin(-a+bi) = 0$, then real part of each quadrant of the semicircular contour will annihilate each other so any contribution (if any) must be pure imaginary. – mathreadler Jun 17 '16 at 19:59

Assuming $\text{Im}(a)>0$, we have: $$\int_{-\infty}^{+\infty}\frac{\sin z}{z-a}\,dz = \color{red}{\pi e^{ia}} \tag{1}$$ by the residue theorem. Write $\sin z$ as $\text{Im}(e^{iz})$, consider a semicircular contour in the upper half-plane, prove the ML inequality, profit.
The term with $\ds{\sigma = 1}$ yields the whole contribution to the sum because the pole $\ds{\pars{-1 + \ic}}$ rests in the upper complex half-plane.
A different approach could be this one: First multiply top and bottom by $x+1+i$ to arrive at:$$\int_{-\infty}^\infty {(x+1+i)sin(x)\over (x+1)^2+1 }dx$$ Now let $x+1=t$ to get $$\int_{-\infty}^\infty {(t+i)sin(t-1)\over t^2+1 }dx$$ Applying Sum formula for sine, we get $$\int_{-\infty}^\infty {(t+i)(sintcos(-1)+costsin(-1))\over t^2+1 }dx$$ Now distribute the $(t+i)$ split the integral from the $+$ sign and realize that due to even-odd properties, some parts cancel, and that was the first reason of my post. Looks like there is a $tsint$ and a $icost$ that is EVEN in the numerator but these are all "standard" complex integrals evaluated elsewhere on this site (and that is the second reason of my post) and I am sure you must have seen those too. Of course there are those $cos1$ and $sin(-1)$ that are part of the answer. Can you work it out from here?