Help in understanding contour integration I would like help in understanding the process of contour integration. As an (hopefully straightforward) example, I have chosen the calculation of Bernoulli number $B_2$. 
I should be very grateful if someone could explain how to get from (and describe the steps between) here
$$
B_n=\dfrac{n!}{2\pi i}\oint\dfrac{z}{e^z-1}\dfrac{\text{d}z}{z^{n+1}}
$$
to here
$$
\dfrac{1}{\pi i}\oint\dfrac{z}{e^z-1}\dfrac{\text{d}z}{z^{3}}=\dfrac{1}{6}
$$
 A: So between $$B_n=\dfrac{n!}{2\pi i}\oint\dfrac{z}{e^z-1}\dfrac{\text{d}z}{z^{n+1}}$$ and $$\dfrac{1}{\pi i}\oint\dfrac{z}{e^z-1}\dfrac{\text{d}z}{z^{3}}$$ all they did was plug in $n=2$, so now all we need to do is find the residue at $z=0$ of $$\frac{1}{z^{2}(e^{z}-1)}=\frac{1}{z^{2}(1-1+z+\frac{z^{2}}{2!}+\frac{z^{3}}{3!}+...)}=\frac{1}{z^{3}(1+\frac{z}{2!}+\frac{z^{2}}{3!}+...)}$$
Now, let $x=\frac{z}{2!}+\frac{z^{2}}{3!}+...$ and use the binomial expansion on $(1+\frac{z}{2!}+\frac{z^{2}}{3!}+...)^{-1}$
$$(1+\frac{z}{2!}+\frac{z^{2}}{3!}+...)^{-1}=1-x+x^{2}+...$$
We only care about the $z^{2}$ and this only has a finite number of contributions, so we'll compute that.
$$a_{2}=(-1)\cdot\frac{1}{3!}+(1)\cdot\frac{1}{2^2}=\frac{1}{12}$$
Where the first term is from x in the expansion, and the second term is from the $\frac{z}{2}$ being squared in the $x^2$ term.
So, after multiplying by $z^{-3}$, we have the residue is $\frac{1}{12}$
Using the residue theorem, we have $$\dfrac{1}{\pi i}\oint\dfrac{z}{e^z-1}\dfrac{\text{d}z}{z^{3}}=\frac{2\pi i}{\pi i}\cdot \frac{1}{12}=\frac{1}{6}$$
