integral of a complex function let $f(z)$ be the analytic component of $\sqrt{z}$ such that $0\leq arg f(z)<\pi$. Let $F(z)=\frac{2}{3}z^{\frac{3}{2}}$. Then $F'(z)=f(z)$ and $F(z)$ is analytic in $0\leq arg z<2\pi$. Let $\gamma$ be the contour: square with vertices $1+i, -1+i, -1-i, 1-i$. Why $\int_{\gamma} f(z)dz = \lim_{\epsilon \to 0}(F(1-\epsilon i) - F(1+\epsilon i)$? Why $\lim_{\epsilon \to 0}F(1-\epsilon i)=-2/3$ but $\lim_{\epsilon \to 0}F(1+\epsilon i)=2/3$? Thank you very much.
 A: For all $\varepsilon>0$, let $\alpha_\varepsilon$ denote the vertical line segment path from $1-\varepsilon i$ to $1+\varepsilon i$, and let $\gamma_\varepsilon$ denote the path parametrizing the rest of the square counterclockwise, starting at $1+\varepsilon i$.  Then $\int_\gamma f = \int_{\gamma_\varepsilon}f + \int_{\alpha_\varepsilon}f$.  Because $f$ is bounded and the length of $\alpha_\varepsilon$ goes to $0$ as $\varepsilon$ goes to $0$, $\displaystyle{\int_\gamma f = \lim_{\varepsilon\to 0}\int_{\gamma_\varepsilon}f}$.  The integral in this limit can be computed directly by subtracting the values of $F$ at the endpoints, because $\gamma_\varepsilon$ lies in the domain of analyticity of $f$, and $F$ is an antiderivative there.  (You could also directly compute this from a parametrization.)
As for the values of $F$ at those points, note that $F(re^{i\theta})=\frac{2}{3}r^{3/2}e^{3i\theta/2}$, with $0<\theta<2\pi$.  As $z$ approaches $1$ from the upper half plane, $\theta$ approach $0$, but as $z$ approaches $1$ from the lower half plane, $\theta$ approaches $2\pi$.  Therefore the limit from below is $\frac{2}{3}\cdot 1\cdot e^{3\pi i}$, while the limit from above is $\frac{2}{3}\cdot 1\cdot e^0$.
