Proving the following integral formula In proving $$f^{(n)}(w) = \frac{n!}{\rho^n \pi} \int_{0}^{2\pi}  \Re ( f(w+\rho e^{i\theta})) e^{-in\theta} d\theta$$ where $f$ is analytic in $D(0;R)$, $0<r<R$, and let $w$ be an arbitary point in $D(0;r)$, I have some confusion.
The first idea is the Cauchy Integral Formula for derivatives, where we have $$f^{(n)}(w) = \frac{n!}{2\pi i} \int_{\partial  D(w;\rho)}  \frac{f(z)}{(z-w)^{n+1}} dz.$$
Plug in $ z = w + \rho e^{i\theta}$ we have $$f^{(n)}(w) = \frac{n!}{2\pi i} \int_{0}^{2\pi}  \frac{f(w+\rho e^{i\theta})}{\rho^n e^{in\theta}} d\theta = \frac{n!}{2 \rho^n \pi i} \int_{0}^{2\pi}  \frac{\Re(f(w+\rho e^{i\theta}))e^{i\theta}}{e^{in\theta}} d\theta,$$ and that's where I can go no further. I didn't know how to cancel the $2i$ in the denominator, or did the integrand has wrong power?
What is the trick?
 A: With $ z = w + \rho e^{i\theta}$ we  have $f^{n}(w) = \frac{n!}{2\pi i} \int_{0}^{2\pi}  \frac{f(w+\rho e^{i\theta})}{\rho^{n+1} e^{i(n+1)\theta}} i\rho e^{i\theta} d\theta$ = $ \frac{n!}{2 \rho^n \pi } \int_{0}^{2\pi}  {\{f(w+\rho e^{i\theta})\}e^{-in\theta}} d\theta$.
A: There are two problems in your calculation. First, as Kavi said, with the parametrization $\gamma(t) = w+ \rho e^{i\theta}$ we have $\gamma'(t) = i\rho  e^{i\theta}$, and therefore
$$\tag{1}
f^{(n)}(w) = \frac{n!}{2\pi i} \int_\gamma \frac{f(z)}{(z-w)^{n+1}} \, dz = 
\frac{n!}{2 \pi \rho^n} \int_0^{2 \pi} f( w+ \rho e^{i\theta}) e^{-in\theta} \, d\theta \, .
$$
The second problem is that you cannot simply replace $f( w+ \rho e^{i\theta})$ by its real part in the integral. Instead we use Cauchy's integral theorem
$$ \tag{2}
 0 = \frac{n!}{2\pi i} \int_\gamma f(z)(z-w)^{n-1} \, dz = 
\frac{n!\rho^n}{2 \pi } \int_0^{2 \pi} f( w+ \rho e^{i\theta}) e^{in\theta} \, d\theta
$$
for $n \ge 1$. Dividing this by $\rho^{2n}$ and taking the complex conjugate gives
$$\tag{3}
 0 = 
\frac{n!}{2 \pi \rho^n} \int_0^{2 \pi} \overline{f( w+ \rho e^{i\theta})} e^{-in\theta} \, d\theta \, .
$$
Now we add $(1)$ and $(3)$ and note that
$$
f( w+ \rho e^{i\theta}) +  \overline{f( w+ \rho e^{i\theta})}  = 2 \operatorname{Re}\left(f( w+ \rho e^{i\theta}) \right) \, ,
$$
so that the factor $2$ cancels in the result:
$$
f^{(n)}(w) = \frac{n!}{ \pi \rho^n} \int_0^{2 \pi} \operatorname{Re}\left(f( w+ \rho e^{i\theta}) \right)  e^{-in\theta} \, d\theta \, .
$$
Remark: We have assumed that $n \ge 1$. The formula does not hold for $n=0$.
