summation from i = 0 to n-1 of (summation of j = i to n-1 of (j-i+1))