Prove that $|f(z)|\leq \left|\frac{4z^2-1}{4-z^2}\right|$ Here is the question I was working on: Let $f$ be holomorphic in the open disk $\mathbb{D}$ and suppose $|f(z)|\leq 1$ for all $z\in \mathbb{D}$. If $f(\frac{1}{2})=f(-\frac{1}{2})=0$, prove that $|f(z)|\leq \left|\frac{4z^2-1}{4-z^2}\right|$ for all $z\in \mathbb{D}$.
I defined the maps $g(z)=\frac{z-\frac{1}{2}}{1-\frac{z}{2}}$ and $h(z)=\frac{z+\frac{1}{2}}{1+\frac{z}{2}}$. Both compositions $f\circ g$ and $f\circ h$ send $0$ to $0$, so using Schwarz lemma, I concluded that $|f(z)|\leq \left|\frac{z-\frac{1}{2}}{1-\frac{z}{2}}\right|$ and $|f(z)|\leq \left|\frac{z+\frac{1}{2}}{1+\frac{z}{2}}\right|$ separately. However, the statement given in the problem is stronger, and I couldn't get it. I would appreciate any kind of help. Thanks!
 A: It is too weak to treat one zero at a time. To get the strongest result you need to use both zeros simultaneously. 
Since $f(z)$ has zeros at $1/2$ and $-1/2$ then the function (with your notations for $g$ and $h$)
$$
\phi(z)=\frac{f(z)}{g(z)h(z)}
$$
is holomorphic in $\mathbb{D}$. Moreover, for any $z\in\mathbb{D}$ and $|z|<r<1$ we have by the Maximum Modulus Principle that
$$
|\phi(z)|\le\max_{|\zeta|=1}|\phi(r\zeta)|=\max_{|\zeta|=1}\frac{|f(r\zeta)|}{|g(r\zeta)||h(r\zeta)|}\le \max_{|\zeta|=1}\frac{1}{|g(r\zeta)||h(r\zeta)|}\to 1\text{ as }r\to 1^-.
$$
The last limit is due to the fact that $|g(z)|$ and $|h(z)|$ converge to $1$ uniformly as $|z|\to 1$. Thus, $|\phi(z)|\le 1$ in $\mathbb{D}$, i.e. 
$$
|f(z)|\le|g(z)h(z)|.
$$
This gives you the necessary estimate after a slight rewriting of the RHS.
A: You can also solve this problem step-by-step, but I think A.G.'s solution is a more elegant one.  It can be generalized in the same way as my solution.
By Schwarz's Lemma, $\big|f(z)\big|\leq \left|\frac{z-1/2}{1-z/2}\right|$ for all $z\in\mathbb{D}$.  Define $F(z)$ to be $\left(\frac{1-z/2}{z-1/2}\right)\,f(z)$ for all $z\in \mathbb{D} \setminus\left\{\frac12\right\}$, while $F\left(\frac12\right)$ is given by $\frac{3}{4}\,f'\left(\frac12\right)$.  Hence, $F:\mathbb{D}\to\mathbb{D}$ is holomorphic with $F\left(-\frac12\right)=0$, and satisfies the condition $\big|F(z)\big|\leq 1$ for all $z\in\mathbb{D}$.
By Schwarz's Lemma, $\left|F(z)\right|\leq \left|\frac{z+1/2}{1+z/2}\right|$ for all $z\in\mathbb{D}$.  Thus, $$\left|f(z)\right|=\left|\frac{z-1/2}{1-z/2}\right|\,\big|F(z)\big|\leq \left|\frac{z-1/2}{1-z/2}\right|\, \left|\frac{z+1/2}{1+z/2}\right|=\left|\frac{4z^2-1}{4-z^2}\right|$$
for all $z\in\mathbb{D}$.
In general, if $f:\mathbb{D}\to\mathbb{D}$ is holomorphic such that $\big|f(z)\big|\leq 1$ for all $z\in\mathbb{D}$ and $f\left(w_i\right)=0$ for $i=1,2,\ldots,n$, where $w_1,w_2,\ldots,w_n$ are pairwise distinct points in $\mathbb{D}$, then
$$\big|f(z)\big|\leq \prod_{i=1}^n\,\left|\frac{z-w_i}{1-\bar{w_i}z}\right|$$
for all $z\in\mathbb{D}$.
P.S.  I just found out that the generalized version has been posted here before.  See Showing that $|f(z)| \leq \prod \limits_{k=1}^n \left|\frac{z-z_k}{1-\overline{z_k}z} \right|$.
