\def\Re{\mathop{\rm Re}\nolimits}
\def\Im{\mathop{\rm Im}\nolimits}
\def\Log{\mathop{\rm Log}\nolimits}
\let\rule\hrule
\def\hrule{\medskip\rule\medskip}

% page 147
\noindent{\bf 2.}

\noindent{\it (a)}

The antiderivative of $z^2$ is $z^3/3$ (because the derivative of that
function is $z^2$)

$$\int_0^{1+i} z^2 dz = \left[ {z^3\over3} \right]_0^{1+i} = (2/3)(1-i).$$

\noindent{\it (b)}

$2\sin(z/2)$ differentiates to $\cos(z/2),$ so it is the antiderivative.
The integral, then, evaluates to:

$$2(\sin(\pi+2i) - \sin 0) = $$

\noindent{\it (c)}

The antiderivative of the integrand is $(z-2)^4/4,$ so the integral
evaluates to
$$\left[ (z-2)^4/4 \right]_1^3 = ( (3-2)^4 - (1-2)^4 )/4 = 0.$$

\hrule
%page 159
\noindent{\bf 2.}

The corollary tells us that these two integrals will be the same if the
functions are analytic on $C_1,$ $C_2,$ and the region between them.

\noindent{\it (a)}

With $$f(z) = {1\over 3z^2 + 1},$$
$f = (3z^2 + 1)^{-1} = f_1(f_2)$ can be differentiated with the chain
rule if $f_1'$ and $f_2'$ are defined. $z^{-1} = f_1$ is analytic where
$f_2 \neq 0,$ and $3z^2 + 1$ is a polynomial, so it is entire.
Because $3z^2 + 1 = 0 \to |3z^2| = 1 \to |z| = \sqrt{1/3}$ is not within
the described region (it is excluded by the square of radius 1), the
equality holds.

\noindent{\it (b)}

Similarly, $$f(z) = {z+2\over \sin(z/2)}$$
implies the equality holds if $z+2$ and $\sin(z/2)$ are analytic and
$\sin(z/2) \neq 0.$ These are both entire functions, so the first
criterion is trivial.
From an earlier theorem, we know that the only zeroes of $\sin z$ are $z
= n\pi$ with $n\in\{0,\pm 1,\pm 2,\ldots\}$ Therefore, $\sin(z/2) = 0$
requires $z = 2n\pi.$
However, none of these points are included in the given region because,
where $n\neq0,$ $|z| > 4,$ so they are outside of the bounding circle,
and when $n=0,$ $z=0$ is excluded by the square.

% i would like to remember this theorem better
% and state the proof more nicely

\noindent{\it (c)}

Again, $$f(z) = {z\over 1-e^z}$$
requires $1 - e^z = 0 \to e^z = 1 \to z = \log 1 = 2n\pi i$ (with $n$
constrained to the integers).
These points are not contained within the circle $|z|=4,$ except $z=0,$
which is excluded by the square of radius 1.

\noindent{\bf 6.}

The Cauchy-Goursat theorem doesn't apply here because this requires a
branch cut at $\theta = -{\pi\over2},$ so $f(z) = \sqrt{r}e^{i\theta/2}$
isn't continuously defined on the region.
On the semicircle, $r = 1,$ $\pi \in (0, \pi),$ and $z' = ie^{i\theta},$
so $$\int_0^\pi (\sqrt{1}e^{i\theta/2})(ie^{i\theta}) d\theta
= \int_0^\pi ie^{3i\theta/2} d\theta
= \left[ (2/3)e^{3i\theta/2} \right]_0^\pi
= (2/3)(e^{3\pi i/2} - 1) = (2/3)(-i-1).$$

On the two radii $\theta = 0,\pi,$ $r\in (0,1),$ the integral is
evaluated as
$$\int_0^1 \sqrt{r}e^{i\theta/2}(ie^{i\theta}) dr
= e^{3i\theta/2} \int_0^1 \sqrt{r} dr
= e^{3i\theta/2}(2/3).$$
This is $-(2/3)i$ where $\theta = \pi,$ (evaluated in the negative
direction, so it is $(2/3)i$ in the positive direction) and $2/3$ where
$\theta = 0.$
Summing these results, we get $0.$

\bye
