Finding local max of analytic function Given a function $f=z^2+iz+3-i$.
I need to find the the maximum of $|f(z)|$ in the domain $|z|\leq 1$
I know that the maximimum should be on $|z|=1$ but when I tried to put $z=e^{i\theta} $ in the function I got lost in the calculations.
Thanks
 A: One (not elegant solution) is to substitute $z=a+bi$ with $a^2+b^2=1$, than use Lagrange's multipliers to find $|f|^2$ extremum (as function of $a$ and $b$) on unit circle. 
A: $|f|^2$ for the value $e^{it}$ is 
$$6 - 2 \sin t - \sin 2t - \cos t + 3 \cos 2 t$$
Some plotting suggests that the maximum is achieved at for $t= \pi$, value 10. Checking: 
\begin{eqnarray}
10 -(6 - 2 \sin t - \sin 2t - \cos t + 3 \cos 2 t) = 4 + 2 \sin t + \sin 2t + \cos t - 3 \cos 2 t = \\
= 2 \cos^2 (t/2)\cdot ( \cos^2 (t/2) + 13 \sin^2 (t/2)\, ) \ge 0
\end{eqnarray}
A: Putting $z=x+iy$ I get $$|f|^2=(x^2-y^2-y+3)^2+(2xy+x-1)^2$$
Now differentiating, and applying the condition $x^2+y^2=1$ I get the critical $x$ values to be roots of the equation $$2x^3-17x+3=0$$
The roots are $-3$ and $\frac 32 \pm \frac {\sqrt7}{2}$  and of these only $\frac 32-\frac {\sqrt7}{2}$ satisfies the constraint.
It is then a matter of number-crunching to obtain $|f|$.
Does this sound like a valid approach? Maybe there is a much more elegant way.
