A result similar to Schwarz lemma 
Suppose $f$ is a holomorphic map on the unit disc. Let $d$ be the diameter of the image of $f$. If $ 2|f'(0)|=d $, please show that $f$ is a linear function.

I think maybe I can prove it by using Schwarz lemma, but I failed.
 A: Historical note: this was proved by Landau and Toeplitz in 1907. A modern source, with many generalizations, is the paper Area, capacity and diameter versions of Schwarz's Lemma by Robert B. Burckel, Donald E. Marshall, David Minda, Pietro Poggi-Corradini, Thomas J. Ransford. 
I divided the proof into several parts, so you can decide to stop before reading further. 

 Opening scene

Let's normalize things so that $f'(0)=1$ and $d=2$. The first thing that comes to mind is to introduce $g(z)=(f(z)-f(-z))/2$, apply the equality case of the Schwarz lemma, and conclude that $g(z)\equiv z$. So, $f$ contains no odd powers above linear. But we know nothing about even powers.   

 Commercial break

A healthy reaction is to try to find a counterexample of the form $f(z)=z+\epsilon z^2$. Nope, does not work. For this function the differences  $|f(z)-f(-z)|$ do not realize the diameter of the image: they are not even stationary points. We get  more from $|f(z')-f(-z)|$ with $z'$ is close to $z$. 
This suggests a variational argument,   differentiating with respect to $z$ lying on the unit circle (so far, illegally):
$$\begin{align}|f(z+dz)-f(-z)| &= |f(z)+f'(z)\,dz-f(-z)| = |2z+f'(z)\,dz|\\
&= 2|1+f'(z)\, dz/z| = 2+ 2\operatorname{Re}( f'(z)\, dz/z) +o(|dz|)\end{align}$$
Since $|f(z+dz)-f(-z)|$ is not to exceed $2$, it follows that $\operatorname{Re}( f'(z)\, dz/z)=0$. Here $dz/z$ is imaginary because $dz$ is tangent to the unit circle at $z$. Hence, $\operatorname{Im} f'(z)=0$. Since $\operatorname{Im} f'$ vanishes on the unit circle, it vanishes identically, and $f$ is indeed linear.   

 Your ad could be here

Now we try to legalize the above in the usual way, taking $0<r<1$ and considering $f_r(z)=r^{-1}f(rz)$, which is smooth on the unit circle. Of course  $f_r'(0)=1$, but what can we say about the image of the unit disk $\mathbb D$ under $f_r$? If it also has diameter $2$, then the  variational argument applies to $f_r$ and we are done. Let's see how the function $D(r):=\operatorname{diam} f_r(\mathbb D)$ depends on $r$: 
$$
 D(r) = 
\sup_{\theta \in [0,2\pi]} \sup_{|z|=1}\, |f_r(e^{i\theta}z) - f_r(z)|  
= \sup_{\theta \in [0,2\pi]} \sup_{|z|=r}\, \left|\frac{f( e^{i\theta}z) - f (z)}{z}\right| 
 $$ 
For any fixed $\theta$, the function $\dfrac{f( e^{i\theta}z) - f (z)}{z}$ is holomorphic in the unit disk. By the maximum principle, the supremum of its modulus over $|z|=r$ is a nondecreasing function of $r$. Taking the supremum over $\theta$, we conclude that $D$ is a nondecreasing function of $r$. 

 Exit music 

Since $D(0+)=2=D(1)$, it follows that $D(r)\equiv 2$, and this is the final piece of the puzzle. 
