Let a triangular number T(n) = n*(n+1)/2 be factored into the product A*B with A less or equal to B.
Let gcd(x,y) be the greatest common divisor of x and y
For each of pair (A,B) define C,D,E,F as follows
C = (gcd(A,n+1))^2,
D = 2*(gcd(B,n))^2,
E = 2*(gcd(A,n))^2,
F = (gcd(B,n+1))^2...