I am trying to compute an integral in an example in my complex analysis textbook:
$$\int_{-\infty}^\infty {xsinx\over x^4+1}dx$$
The book gives some startup hints, but I don't quite follow, I set $f(z)={e^{iz}z\over z^4+1}$. Then the function has poles of order 1 at $\sqrt i$ and $-\sqrt i$, or $e^{i\pi/4}$ and $-e^{i\pi/4}$.
Next, I need to find the residue of $f$ at $e^{i\pi/4}, -e^{i\pi/4}$. After that I think I know what to do next. But the step of finding the residue is getting me.
You can calculate the residue by using $f/f'$.
$\displaystyle \lim_{z\to e^{\frac{\pi i}{4}}}\frac{ze^{iz}}{4z^{3}}$
Then do the case for $e^{3\pi i/4}$ the same way and add them.