Closed form of $\mathcal Z$-transform : decomposition signal $x(n)$ The text of my exercise ask : 


  Determine the closed form of the $\mathcal{Z}$-transform for this $x(n)$  $$ x(n) = \begin{cases} |n-N|  &amp; \text{if 0&lt;$n$&lt;2N} \\ 0 &amp; \text{elsewhere} \end{cases} $$


I see $x(n)$ like a composition of two signals

$$ x(n)= x'(n)+x''(n) $$
I use for greater semplicity $x_1(n)$
$$x_1(n)= (u(n)-(u-(N+1))$$
whence
$$x'(n)= (n-N) x_1(n) $$
$$x''(n)= x'(n-N)$$

Determination $X(Z)$ it easy, but if 
the above equations are correct, for this reason i need post this question here.

$$X_1(Z)= \frac{z^{-(N+1)}-1}{Z^{-1} -1}$$
$$X'(Z)= z^{-1} \frac{{d}}{dz^{-1}} X_1(Z)- N X_1(Z)$$ 
$$X''(Z)= X_1 (\frac{1}{Z})z^{-N}$$

This is my solution. 

$$X(Z)= X'(Z)+X''(Z)$$
Or you can proceed this way: \begin{align}\mathcal Z\left\{x(n)\right\}= X(z) &amp;= \sum_{n=-\infty}^\infty x(n)z^{-n}\\
&amp; = 0 + \sum_{n=0}^{2N} \left|n - N\right|z^{-n} + 0\\
&amp; = \sum_{n=0}^{N} \left(-n + N\right)z^{-n} + \sum_{n=N}^{2N} \left(n - N\right)z^{-n}\\
&amp; = N\sum_{n=0}^{N}z^{-n} - N\sum_{n=N}^{2N}z^{-n} - \sum_{n=0}^{N} nz^{-n} + \sum_{n=N}^{2N} nz^{-n} 
\end{align}

And changing the boundaries for the second and fourth term, putting $k = n - N$, you get :

$$X(z) = N\sum_{n=0}^{N}z^{-n} - Nz^{-N}\sum_{k=0}^{N}z^{-k} - \sum_{n=0}^{N} nz^{-n} + z^{-N}\sum_{k=0}^{N} kz^{-k} $$

You can continue from there.