# Inequalities with Schwarz lemma

Suppose $f$ is holomorphic in $B(0,1)$, $f(0)=0$, and $|Re f(z)|<1$, I need to prove

(1) $|Ref(z)|\leq \frac{4}{\pi}\arctan|z|$

(2) $|Imf(z)|\leq \frac{2}{\pi}\ln \frac{1+|z|}{1-|z|}$

I think I should use Schwarz lemma for the function $i \tan \frac{\pi f(z)}{4}$ (composite a map the stripe region to unit disk). But I don't know how to estimate the real and imaginary part respectively.

Any help will be appreciated.

Hint. By Schwarz lemma, $$\left|i \tan\left( \frac{\pi f(z)}{4}\right)\right|\leq |z|.$$ Moreover, we have that $$\tan(x+iy)=\frac{\sin(x+iy)}{\cos(x+iy)} =i\frac{e^{y-ix}-e^{ix-y}}{e^{y-ix}+e^{ix-y}}\\ =i\frac{e^{2y}-e^{-2y}+e^{-2ix}-e^{2ix}}{e^{2y}+e^{-2ix}+e^{2ix}+e^{-2y}} =\frac{\sin(2x)+i\sinh(2y)}{\cosh(2y)+\cos(2x)}.$$ Try to show that,
i) if $|x|<\pi/4$ then $|\tan (x)|\leq |\tan(x+iy)|$;
ii) $|\tanh (y)|\leq |\tan(x+iy)|$.
Note that $\tanh^{-1}(t)=\frac{1}{2}\ln\frac{1+t}{1-t}$ for $t\in(-1,1)$.