# q-analog of a combinatorial identity involving binomial coefficients

Using, e.g., properties of iterated finite differences it is easy to show that for any pair of integers $n$ and $m$ with $n>\!>m$ one has the identity $$\sum_{k=0}^m(-1)^{k-m} {n-k\choose m}{m\choose k}=(-1)^{m}.$$ Motivated by Colored sl(N) link homology via matrix factorizations, by Hao Wu, I am interested in a certain $q$-analog of the above formula. Defining the $q$-integer $[n]_q$ as $$[n]_q=\frac{q^{n}-q^{-n}}{q-q^{-1}}$$ and consequently the $q$-factorial as $$[n]_q!=[n]_q[n-1]_q\cdots [1]_q$$ and the $q$-binomial $${n \brack m}_q=\frac{[n]_q!}{[m]_q![n-m]_q!}$$ (notice that this convention, which seems to be the standard one among quantum group theorists differ by a power of $q$ and by a change of variable $q\leftrightarrow q^2$ from the maybe more standard convention $[n]_q=(1-q^n)/(1-q)$) An extensive Sage computation shows that the following combinatorial identity holds: $$\sum_{k=0}^m(-q)^{k-m} {n-k\brack m}_q{m\brack k}_q=(-1)^{m} q^{-(n+1-m)m}.$$ in perfect agreement with the "shifting factor" one finds on page 9 of Hao Wu's paper.

My problem is that I have not been able to work out a formal proof of the above identity involving $q$-binomials: any suggestion would be appreciated.

(it must also be said that combinatorics is "Here be dragons" to me, and that even working out the above identity involving ordinary binomials, although quite simple in the end, took me some time; so I see the question I am asking can possibly be actually trivial, and if this is the case I apologize for this)

You can see this as an instance of the q-Vandermonde identity. The q-binomial theorem tells us that the coefficient of $t^k$ in $\prod_{i=0}^{m-1}(1+q^{-2i}t)$ is $q^{-k(m-1)}{m \brack k}_q$ and the coefficient of $t^{n-m-k}$ in $\prod_{i=0}^{m}\frac{1}{1+q^{-2i}t}$ is $(-1)^{n-m-k}q^{-m(n-k-m)}{n-k \brack m}_q$. By taking the product and finding the coefficient of $t^{n-m}$ in two ways, we see that $$\sum_{k=0}^m (-1)^{n-m-k}q^{k-m(n-m)}{n-k\brack m}_q{m\brack k}_q=(-1)^{n-m}q^{2m(m-n)}.$$ From here, just multiply both sides by $(-1)^n q^{m(n-m-1)}$ and obtain your identity.