Simplify a summation with indicator function I have this double summation that I want to simplify:

$$\sum^{q} _{j=-q} \sum^{q} _{i=-q} \mathbb{1}_{ \{h+j-i=0 \}}$$

A given solution says the answer is $2q+1-h$ for $|h| \leq 2q$ and $0$ otherwise. 
I don't see this. For example, when I take $q=1$ and $h = 2*q = 2$ the summation sums up to $0$ which is unequal to $2q+1-h = 1$.
Anyone can help me out?

We have
$$\sum_{a=-q}^q \sum_{b=-q}^q \mathrm{1}_{h+a-b=0}
= \sum_{a=-q}^q \sum_{b=-q}^q \mathrm{Res}_{z=0} \frac{1}{z^{h+1+a-b}}
\\ = \mathrm{Res}_{z=0} \frac{1}{z^{h+1}}
 \sum_{a=-q}^q \frac{1}{z^a} \sum_{b=-q}^q z^b
= \mathrm{Res}_{z=0} \frac{1}{z^{h+1}}
\left(\sum_{b=-q}^q z^b\right)^2
\\ = \mathrm{Res}_{z=0} \frac{1}{z^{h+1}}
\left(\frac{1}{z^q} \sum_{b=0}^{2q} z^b\right)^2
= \mathrm{Res}_{z=0} \frac{1}{z^{h+2q+1}}
\frac{(1-z^{2q+1})^2}{(1-z)^2}
\\ = \mathrm{Res}_{z=0} \frac{1}{z^{h+2q+1}}
\frac{1-2z^{2q+1}+z^{4q+2}}{(1-z)^2}.$$
The three pieces here are: first,
$$[z^{h+2q}] \frac{1}{(1-z)^2} = h+2q+1$$
for $h+2q\ge 0$ or $h\ge -2q,$ second
$$-2 [z^{h+2q}] \frac{z^{2q+1}}{(1-z)^2}
= -2 [z^{h-1}] \frac{1}{(1-z)^2}
= -2h$$
for $h+2q\ge 2q+1$ or $h\ge 1,$ third
$$[z^{h+2q}] \frac{z^{4q+2}}{(1-z)^2}
= [z^{h-2q-2}] \frac{1}{(1-z)^2}
= h-2q-1$$
for $h+2q\ge  4q+2$ or  $h\ge 2q+2.$ 
Collecting  everything  we  have  that  when  $q=0$  the  sum  becomes
$\mathrm{1}_{h=0}$ so  we may  suppose that $q\ge  1.$ We  then obtain
zero when $h\lt -2q.$ We get  when $-2q\le h\lt 1$ the value $h+2q+1.$
Next  for $1\le  h\lt 2q+1$  we find  $-h+2q+1.$ For  $h=2q+1$ we  get
$h+2q+1-2h = 0.$ Finally for $h\ge 2q+2$ we get zero, adding all three
pieces. We conclude with the closed form
$$\bbox[5px,border:2px solid #00A000]{
[[\; |h| \le 2q \;]] \times (2q+1-|h|).}$$
