# Why does the Cauchy-Goursat theorem not apply here?

Let $C$ denote the positively oriented boundary of the half disk $0 \le r \le 1, 0 \le \theta \le \pi$, and let $f(z)$ be a continuous function defined on that half disk by writing $f(0) = 0$ and using the branch \begin{align} f(z) = \sqrt{r} e^{\frac{i \theta}{2}} \end{align} Show that \begin{align} \int_C f(z) \, dz = 0 \end{align} by evaulating separately the integrals of $f(z)$ over the semicircle and the two radii which make up $C$. Why does the Cauchy-Goursat theorem not apply here?

Note: My only question is the last part of the problem statement, where I made the text boldface. (I have figured out everything else in this problem!)

I believe the CG Theorem does not apply because the function is not analytic at some point in the half-circle.

The answer depends on the exact formulation of Cauchy-Goursats's theorem in your textbook. The theorem is probably only formulated for functions that are holomorphic (analytic if you prefer) on an open neighbourhood of the closed domain bounded by your curve. In that case, $f(z) = \sqrt{z}$ (for a suitable choice of branch) is holomorphic on the open half-disc but not on any neighbourhood of the closed half-disc, due to the branch point at $z=0$.
On the other hand, it is possible to formulate Cauchy-Goursat for functions that are continuous on $\bar\Omega$ and holomorphic on $\Omega$ (where $\Omega$ is the domain bounded by the curve $C$) and in that case Cauchy-Goursat would be applicable.