Simple contour integration question?

66 Views Asked by At

If you are trying to evaluate a real integral using contour integration, are you meant to find the poles first and then draw the contour around these poles?

So for example with this integral:

$$ \int_{-\infty}^{\infty} \, \frac{1}{z^2+1} dz$$

I know that there are poles at $ z = i, -i $. But for some reason they (a youtube video i was watching) drew a semi circle on the upper half plan before working out the poles and then said "we can see that we only need to worry about $ z = i$ ." i.e. they completely left $ z = -i$ out.

Is there a reason for this? Or did they get it wrong?