A question on $\int \prod_{j=1}^u \frac{x+j}{j-x}~dx.$ Let $I_{n,k} = \frac{(n+k)!}{k!(k-1)!(n-k)!}$. Consider:
$$f_u(x)=\int \prod_{j=1}^u \frac{x+j}{j-x}~dx.$$
I would like to show that
$$\tag{1}f_u(x) = C+ (-1)^ux-\sum_{w=1}^{u}(-1)^w \log(x-w)I_{u,w}.$$
I have shown that
$$\prod_{j=1}^u \frac{x+j}{j-x}=(-1)^j+\sum_{j=1}^k(-1)^j\frac{I_{k,j}}{x-j}$$
From which $(1)$ follows. I obtained the above through polynomial long division. I am wondering if there is a way to avoid this step and obtain $(1)$ without the use of polynomial long division (ie. by residues).
 A: Consider the function, and its partial fraction decomposition
$$f\left( x \right)=\prod\limits_{j=1}^{n}{\frac{j+x}{j-x}=\frac{\left( 1+x \right)\left( 2+x \right)...\left( n+x \right)}{\left( 1-x \right)\left( 2-x \right)...\left( n-x \right)}}={{a}_{0}}+\sum\limits_{j=1}^{n}{\frac{{{a}_{j}}}{\left( j-x \right)}}$$ 
The ${{a}_{0}}$ is needed to account for the value of the function at $x=0$.  The coefficients are easily determined by calculating the residues at each pole.  Doing so we have
$${{a}_{j}}=res\left( f\left( x \right),x=j \right)=-\frac{\prod\limits_{k=1}^{n}{k+j}}{\prod\limits_{k\ne j}^{n}{k-j}}$$ 
so
$$f\left( x \right)={{a}_{0}}-\sum\limits_{j=1}^{n}{\frac{{{\left( 1+j \right)}_{n}}}{\prod\limits_{k\ne j}^{n}{k-j}}\frac{1}{\left( j-x \right)}}={{a}_{0}}+\sum\limits_{j=1}^{n}{\frac{{{\left( -1 \right)}^{j-1}}\left( n+j \right)!}{\left( j-1 \right)!\left( n-j \right)!j!}\frac{1}{\left( j-x \right)}}$$
We know $f\left( 0 \right)=1\Rightarrow {{a}_{0}}={{\left( -1 \right)}^{n}}$. To see this observe
$$\sum\limits_{j=1}^{n}{\frac{{{z}^{j-1}}\left( n+j \right)!}{\left( n-j \right)!j{{!}^{2}}}}=\frac{1}{z}\sum\limits_{j=1}^{\infty }{\frac{\left( n+j \right)!}{\left( n-j \right)!j!}}\frac{{{z}^{j}}}{j!}=-\frac{1}{z}+\frac{1}{z}\sum\limits_{j=0}^{\infty }{\frac{\left( n+j \right)!}{\left( n-j \right)!j!}\frac{{{z}^{j}}}{j!}}=-\frac{1}{z}+\frac{1}{z}{}_{2}{{F}_{1}}\left( -n,1+n;1;-z \right)$$
So
$$\sum\limits_{j=1}^{n}{\frac{{{\left( -1 \right)}^{j-1}}\left( n+j \right)!}{\left( n-j \right)!j{{!}^{2}}}}=1-{}_{2}{{F}_{1}}\left( -n,1+n;1;1 \right)=1-{{P}_{n}}\left( -1 \right)=1+{{\left( -1 \right)}^{n+1}}$$
Where P are Legendre polynomials.  Therefore
$$f\left( x \right)={{\left( -1 \right)}^{n}}+\sum\limits_{j=1}^{n}{\frac{{{\left( -1 \right)}^{j}}\left( n+j \right)!}{\left( j-1 \right)!\left( n-j \right)!j!}\frac{1}{\left( x-j \right)}}$$
Integrating 
$$\int\limits_{{}}^{{}}{f\left( x \right)dx}={{\left( -1 \right)}^{n}}x+\sum\limits_{j=1}^{n}{\frac{{{\left( -1 \right)}^{j}}\left( n+j \right)!}{\left( j-1 \right)!\left( n-j \right)!j!}\log \left( x-j \right)+C}$$
and this works for all n.  I can't see why this could be written as one summation given the nature of the decomposition (i.e. what we had to do to obtain it in this form).
