# Using Residue Theorem to evaluate integral

As an exercise, I tried to evaluate $\int_C\frac{1}{z^{2017}-1}dz$ using the formula$\int_Cf(z)dz=2πiRes(\frac{1}{z^2}f(\frac{1}{z});0)$ where $C$ is the contour $|z|=2$ traversed in counterclockwise direction. So my approach is as such: Let $f(z)$ be $\frac{1}{z^{2017}-1}$. Then $\frac{1}{z^2}f(\frac{1}{z}) = \frac{z^{2015}}{1-z^{2017}}=z^{2015}(1+z^{2017}+..)$. The coefficient of $\frac{1}{z}$ is zero so the residue is zero. Thus, $\int_C\frac{1}{z^{2017}-1}dz=2πi.0=0.$ It looks deceptively simple to solve so just wondering if my steps/answer is correct~

*Edit: It has been pointed out this approach may be wrong (even though here I have tried to apply a standard complex analysis technique, I think, to solve in the simplest manner, seemingly complex questions like this one) but with no convincing explanation as to why :O so I seek clarification~

**And for the latest update, the point has just been clarified below.

• Your approach is wrong because your function has multiple singularities enclosed by the curve, none of which are at zero. You have to sum over the residues of each pole enclosed by the curve. There are 2017 of them, and as far as I know they are not trivial to compute, so this approach might not be so easy. – Vik78 Apr 3 '17 at 6:50
• However, the integral actually is zero, because the integral is the same even if the radius of the circle is arbitrarily large, and you can show that the integral goes to zero as the radius increases. – Vik78 Apr 3 '17 at 6:53
• @Vik78 The variable change $1/z$ moves all poles outside (the circle of radius $1/2$), so formally what you say is exactly what the OP does, i.e. calculates the residue at infinity. – A.Γ. Apr 3 '17 at 7:04
• The residue theorem (at infinity) will hold as long as we have f analytic everywhere in the finite plane except for a finite number of singular points interior to positively oriented simple closed contour C, so I am not sure what's wrong exactly @Vik78.. – Homaniac Apr 3 '17 at 7:05
• The residue is not at $z=0$ which you seem to try to calculate, it is at the 2017 roots of unity. – mathreadler Apr 3 '17 at 8:11

Your method is correct. The only confusing part is the change of variables that you call the new variable again the same name $z$, which makes people to mix it up with the old one. It is better to use another name $$w=\frac{1}{z},$$ so you'll get $$-\int_{|w|=0.5}\frac{w^{2015}}{1-w^{2017}}\,dw=0$$ since the integrand is analytic function in the disc of radius $0.5$. The power expansion will work as well as $|w|<1$.

• AHH of course you have a point there, thank you so much for clearing the air! – Homaniac Apr 3 '17 at 8:04

Hint :

• $\displaystyle \int_C f(z)\,dz=2\pi i\times \text{sum of the residues at the singularities within }C$
• Sum of residues at all finite singularities in $C$ $+\text{ Res}(f,\infty)=0$
• If $\displaystyle \lim_{z\to \infty}f(z)=0$ then $\displaystyle \text{Res}(f, \infty)=\lim_{z\to \infty}zf(z)$
• I am not actually looking for an alternative approach but okay at first sight, I never seemed to have come across the last point. Is this a standard result or some kind of corollary of the residue theorem just wondering? – Homaniac Apr 3 '17 at 7:28
• @Homaniac Yes. It is like a corollary of that result which you have used in your first line. – Empty Apr 3 '17 at 7:30
• @Homaniac BTW if you will not look for an alternative approach you will never get your answer , because your process is definitely wrong..!! It is NOT applicable here. – Empty Apr 3 '17 at 7:32
• Ahh but could you care to explain why exactly my process is wrong? – Homaniac Apr 3 '17 at 7:34
• First of all tell me how you expand $\frac{1}{1-z^{2017}}=1+z^{2017}+\cdots$ like this ? It can be expand only if $|z|<1$. – Empty Apr 3 '17 at 7:36