# evaluate an expression which is the arithmetic mean of first $N$ partial sums of a geometric progression

I am trying to evaluate an expression which is the arithmetic mean of first $N$ partial sums of a geometric progression.It is given as below.

$\frac{1}{N}\sum\limits_{k=0}^{N-1}(N-k)z^k$

Please suggest me some hints or ideas to proceed.

-

More generally, you can evaluate

$$\sum_{k=0}^{N-1}P(k)z^k$$

for any polynomial $P$ by using

$$(z\frac{\mathrm d}{\mathrm d z}) z^k=kz^k\;.$$

Thus, you can replace $k$ by $D:=z\frac{\mathrm d}{\mathrm d z}$ in $P\,$:

$$\begin{eqnarray} \frac{1}{N}\sum_{k=0}^{N-1}(N-k)z^k &=& \sum_{k=0}^{N-1}\left(1-\frac{k}{N}\right)z^k \\ &=& \sum_{k=0}^{N-1}\left(1-\frac{D}{N}\right)z^k \\ &=& \left(1-\frac{D}{N}\right)\sum_{k=0}^{N-1}z^k \\ &=& \left(1-\frac{D}{N}\right)\frac{z^N-1}{z-1}\;. \end{eqnarray}$$

-