Let $D$ be the open unit disk centered at $0$ in the complex plane. Let $f:D\longrightarrow D$ be holomorphic such that $f(0)=0$. Use the Schwarz lemma to prove that $|f(z)+f(-z)|\leq 2|z|^2$ for any $z\in D$. If the equality holds for some $z_0\in D\{0\}$, then there exists $\theta\in \mathbb{R}$ such that $f(z)=e^{i\theta} z^2$.
I let $g(z)=(f(z)+f(-z))/2$. Applying Schwarz lemma on $g$, I obtain $|g(z)|\leq |z|$. i.e., $|f(z)+f(-z)|\leq 2|z|^2$. If the equality holds, then $g(z)=e^{i\theta}z$. Thus $f(z)+f(-z)=2e^{i\theta}z^2$ for all $z\in D(0,1)$. But I do not know how to obtain $f(z)=e^{i\theta} z^2$... How to continue?
Thank you a lot.