Is there some way to simplify $\sum_{i=1}^n \sum_{j\neq i}(\frac{j-1}{2})(\frac{i-1}{2}) $ To obtain a closed form.

99 Views Asked by At

Is there some way to simplify $\sum_{i=1}^n \sum_{j\neq i}(\frac{j-1}{2})(\frac{i-1}{2}) $?

Does it have a closed form? It's the last piece of a puzzle I need to solve a similar question Differentiate $P_{x_n}(z) = \prod_{i=1}^n\frac{1+z+z^2+...+z^{i-1}}{i}$ twice to calculate the variance of involutions.

Taking the example

$\sum_{i=1}^4 \sum_{j\neq i}(\frac{j-1}{2})(\frac{i-1}{2}) = (\frac{2-1}{2} + \frac{3-1}{2} + \frac{4-1}{2})(\frac{1-1}{2}) + (\frac{1-1}{2} + \frac{3-1}{2} + \frac{4-1}{2})(\frac{2-1}{2}) + (\frac{1-1}{2} + \frac{2-1}{2} + \frac{4-1}{2})(\frac{3-1}{2}) + (\frac{1-1}{2} + \frac{2-1}{2} + \frac{3-1}{2})(\frac{4-1}{2}) = 2(\frac{1-1}{2}\frac{2-1}{2})+ 2(\frac{1-1}{2}\frac{3-1}{2}) + 2(\frac{1-1}{2}\frac{4-1}{2}) + 2(\frac{2-1}{2}\frac{3-1}{2}) + 2(\frac{2-1}{2}\frac{4-1}{2}) + 2(\frac{3-1}{2}\frac{4-1}{2})$

I feel that since the sums are decreasing in number by one with regard to $\frac{i-1}{2}$ there should be a factorial term in the closed form, I'm just not sure how to obtain it. Any help would be appreciated.

1

There are 1 best solutions below

0
On

To answer my own question,

$\sum_{i=1}^n \sum_{j\neq i}(\frac{j-1}{2})(\frac{i-1}{2}) = \sum_{i=1}^n \sum_{j=1}^n(\frac{j-1}{2})(\frac{i-1}{2}) - \sum_{i=1}^n\frac{(i-1)^2}{4} $

Which simplifies to

$\frac{n(n-1)}{4}\frac{n(n-1)}{4} - \frac{1}{4}(\frac{(n-1)n(2(n-1)+1)}{6})$

or just $\frac{(n - 2) (n - 1) n (3 n - 1)}{48}$