An identity involving binomial coefficients Prove the following identity
$$\displaystyle \sum_{i+j=m}\frac{(n-1) \binom{ai+n-1}{i} \binom{aj+1}{j}}{(ai+n-1)(aj+1)} =  \frac{n\binom{am+n}{m}}{am+n}$$
where $i = 0,1,\cdots,m$ and $m, n$ are positive integers and $a$ is a positive integer or even a fraction.
One complete proof can be found in that famous book "Concrete Mathematics" by
Ronald L. Graham, Donald E. Knuth, and Oren Patashnik  which is widely used as a textbook in many computer science departments.
Another complete proof can be found in the book written by Egorychev which is directly using the inversion rule of residue, see page 49 in the book "Integral representation and the computation of combinatorial sums". If you are reading that book, keep in mind that the index under $\sum$ can be extended to infinity because the contour integral has no pole when $k>n$.  
 A: This is a nice example to apply the inversion rule of formal power series stated as rule 4 in G.P. Egorychevs Integral Representations  and the Computation of Combinatorial Sums section 1.2.2.
I think it's worthwhile to present a complete proof. Here we use the coefficient of operator $[z^n]$ to denote the coefficient of $z^n$ in a formal power series. We show

The following is valid for $m,n\geq 1$ and $a\in\mathbb{R}$ appropriate
  \begin{align*}
\sum_{{i+j=m}\atop{i,j\geq 0}}&\frac{n-1}{ai+n-1}\binom{ai+n-1}{i}\frac{1}{aj+1}\binom{aj+1}{j}
=\frac{n}{am+n}\binom{am+n}{m}
\end{align*}

$$ $$

We obtain
  \begin{align*}
\sum_{{i+j=m}\atop{i,j\geq 0}}&\frac{n-1}{ai+n-1}\binom{ai+n-1}{i}\frac{1}{aj+1}\binom{aj+1}{j}\\
&=\sum_{i=0}^m\frac{n-1}{ai+n-1}\binom{ai+n-1}{i}\frac{1}{am-ai+1}\binom{am-ai+1}{m-i}\\
&=\sum_{i=0}^\infty\left\{\binom{ai+n-1}{i}-a\binom{ai+n-2}{i-1}\right\}\\
&\qquad\qquad\cdot\left\{\binom{am-ai+1}{m-i}-a\binom{am-ai}{m-i-1}\right\}\tag{1}\\
&=\sum_{i=0}^{\infty}\left([z^i](1+z)^{ai+n-1}-a[z^{i-1}](1+z)^{ai+n-2}\right)\\
&\qquad\qquad\cdot\left([w^{m-i}](1+w)^{a(m-i)+1}-a[w^{m-i-1}](1+w)^{a(m-i)}\right)\\
&=[w^m](1+w)^{am}(1+w-aw)\\
&\qquad\qquad\cdot\sum_{i=0}^{\infty}\left(\frac{w}{(1+w)^a}\right)^i[z^i](1+z)^{n-2}(1+z-az)(1+z)^{ai}\tag{2}\\
&=[w^m](1+w)^{am}(1+w-aw)\left.\left((1+z)^{n-1}\right)\right|_{z=w}\tag{3}\\
&=[w^m](1+w)^{am+n}-a[w^{m-1}](1+w)^{am+n-1}\\
&=\binom{am+n}{m}-a\binom{am+n-1}{m-1}\\
&=\frac{n}{am+n}\binom{am+n}{m}
\end{align*}
  and the claim follows.

Comment:


*

*In (1) we use the identity $$\frac{q}{pk+q}\binom{pk+q}{k}=\binom{pk+q}{k}-p\binom{pk+q-1}{k-1}$$ We also set the upper limit of the sum to $\infty$ without changing anything since we are only adding zero.

*In (2) we rearrange the sum, use the linearity of the coefficient of operator and the rule $[z^{n-k}]A(z)=[z^n]z^kA(z)$.

*In (3) we use the inversion rule
\begin{align*}
\sum_{i=0}^\infty w^i [z^i]A(z)f^i(z)=\left.\left(A(z)\frac{f(z)}{f(z)-zf^{\prime}(z)}\right)\right|_{z=g(w)}
\end{align*}
with $g(w)$ the inverse of $w=\frac{z}{g(z)}$. We get from (2)
\begin{align*}
A(z)&=(1+z)^{n-2}(1+z-az)\\
f(z)&=(1+z)^a
\end{align*}
and obtain
\begin{align*}
A(z)\frac{f(z)}{f(z)-zf^{\prime}(z)}&=(1+z)^{n-2}(1+z-az)\frac{(1+z)^a}{(1+z)^a-az(a+z)^{a-1}}\\
&=(1+z)^{n-1}
\end{align*}
Since $w=\frac{z}{f(z)}=\frac{z}{(1+z)^a}$ we apply in (3) the substitution $z=w$.
A: Here is an answer to the second sum that was posted which does indeed use exactly the same method as the first and being more compact is easier to read and understand. 
Suppose we seek to verify that
$$\sum_{k=0}^m \frac{q}{pk+q}
{pk+q\choose k} {pm-pk\choose m-k} = {mp+q\choose m}.$$
Observe that
$${pk+q\choose k} = \frac{pk+q}{k} {pk+q-1\choose k-1}$$
so that
$${pk+q\choose k} - p {pk+q-1\choose k-1}
= \frac{q}{k} {pk+q-1\choose k-1}
= \frac{q}{pk+q} {pk+q\choose k}.$$
This yields two pieces for the sum, call them $S_1$
$$\sum_{k=0}^m {pk+q\choose k} {pm-pk\choose m-k}$$
and $S_2$
$$- p \sum_{k=0}^m {pk+q-1\choose k-1} {pm-pk\choose m-k}.$$
For $S_1$ introduce the integrals
$${pk+q\choose k} =
\frac{1}{2\pi i}
\int_{|z|=\gamma} 
\frac{(1+z)^{pk+q}}{z^{k+1}} 
\; dz$$
and
$${pm-pk\choose m-k} =
\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm-pk}}{w^{m-k+1}} 
\; dw.$$
The second  one controls the range of the sum because the pole at  zero vanishes when $k\gt m$ so we may extend  $k$ to infinity,
getting for the sum
$$\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm}}{w^{m+1}} 
\frac{1}{2\pi i}
\int_{|z|=\gamma} 
\frac{(1+z)^{q}}{z}
\sum_{k\ge 0} \frac{w^k}{z^k} \frac{(1+z)^{pk}}{(1+w)^{pk}}
\; dz\; dw
\\ =
\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm}}{w^{m+1}} 
\frac{1}{2\pi i}
\int_{|z|=\gamma} 
\frac{(1+z)^{q}}{z}
\frac{1}{1-w(1+z)^p/z/(1+w)^p}
\; dz\; dw 
\\ =
\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm+p}}{w^{m+1}} 
\frac{1}{2\pi i}
\int_{|z|=\gamma} 
(1+z)^{q}
\frac{1}{z(1+w)^p-w(1+z)^p}
\; dz\; dw.$$
Suppose $|\epsilon| < |\gamma|$ which makes 
$\left|\frac{w(1+z)^p}{z(1+w)^p}\right| < 1$ so that we have convergence of the geometric series and suppose we  can prove that $z=w$  is the only pole  inside the contour
and it is simple. We have
$$\left((1+w)^p z - w(1+z)^p\right)'
= (1+w)^p - pw(1+z)^{p-1} = (1+w)^{p-1}(1+w-wp).$$
We can choose $|\epsilon|$ small enough such that $|1+w-wp| >0$, so the pole is order 1, which yields
$$\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm+p}}{w^{m+1}} 
(1+w)^q \frac{1}{(1+w)^{p-1}} \frac{1}{1+w-pw}
\; dw
\\ = 
\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm+q+1}}{w^{m+1}} 
\frac{1}{1+w-pw}
\; dw.$$
Following exactly the same procedure we obtain for $S_2$
$$-p \frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm+q}}{w^{m}} 
\frac{1}{1+w-pw}
\; dw.$$
Adding these two pieces now yields
$$\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm+q}}{w^{m}} 
\left(\frac{1+w}{w} - p\right)
\frac{1}{1+w-pw}
\; dw
\\ = \frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm+q}}{w^{m+1}} 
\; dw
\\ = {pm+q\choose m}.$$
Remark Mon Jan 25 2016. 
An alternate proof which is completely rigorous and does not depend on
assumptions about  the poles of a bivariate  complex function proceeds
from the integral
$$\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm}}{w^{m+1}} 
\sum_{k\ge 0} \frac{w^k}{(1+w)^{pk}}
\frac{1}{2\pi i}
\int_{|z|=\gamma} 
\frac{(1+z)^{q}}{z^{k+1}}
(1+z)^{pk}
\; dz\; dw$$
Now put
$$u = \frac{z}{(1+z)^p}
\quad\text{and introduce}\quad
g(u) = z.$$
We then have
$$du = 
\left(\frac{1}{(1+z)^p} - p\frac{z}{(1+z)^{p+1}}\right) \; dz
= \left(\frac{u}{g(u)} - \frac{pu}{1+g(u)}\right) \; dz$$
and
$$dz  = \frac{1}{u}\frac{g(u) (1+g(u))}{1 + g(u) - p g(u)} \; du.$$
This yields
$$\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm}}{w^{m+1}} 
\sum_{k\ge 0} \frac{w^k}{(1+w)^{pk}}
\\ \times \frac{1}{2\pi i}
\int_{|u|=\gamma} 
\frac{1}{g(u) u^{k}} (1+g(u))^q 
\frac{1}{u}\frac{g(u) (1+g(u))}{1 + g(u) - p g(u)}
\; du\; dw$$
or
$$\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm}}{w^{m+1}} 
\left.(1+g(u))^q 
\frac{1+g(u)}{1 + g(u) - p g(u)}
\right|_{u=w/(1+w)^p} \; dw.$$
Now observe that $g(w/(1+w)^p) = w$ by definition so we get
$$\frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm}}{w^{m+1}} 
(1+w)^q 
\frac{1+w}{1 + w - p w} \; dw
\\ = \frac{1}{2\pi i}
\int_{|w|=\epsilon} 
\frac{(1+w)^{pm+q+1}}{w^{m+1}} 
\frac{1}{1 + w - p w} \; dw.$$
This is exactly the same as before and the rest of the proof continues
unchanged.
What we have used here is the technique of annihilated coefficient
extractors of which there are several more examples at this MSE link
I  and at  this MSE
link  II  and  also
here             at             this             MSE             link
III.
A: Follow the same reasoning when proving this identity, 
$$\displaystyle \sum_{i=0}^m\frac{q }{pi+q}\binom{pi+q}{i} \binom{pm-pi}{m-i} = \binom{mp+q}{m}$$
You can just read the book yourself. Too difficult to post the book here!
it can be proved using the inversion rule of residue, see page 49 Integral representation and the computation of combinatorial sums
