OFFSET
0,3
COMMENTS
a(n) = Sum {1<=k,l,m<=n; k+l+m divisible by n} klm.
LINKS
Index entries for linear recurrences with constant coefficients, signature (6,-15,20,-15,6,-1).
FORMULA
G.f.: x*(x^4+2*x^3+3*x^2+8*x+1) / (x-1)^6. - Colin Barker, Jul 16 2013
PROG
(PARI) a(n)=if(n<1, 0, sum(k=1, n, sum(l=1, n, sum(m=1, n, if((k+l+m)%n==0, k*l*m))))) /* Michael Somos, May 16 2005 */
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Ralf Stephan, May 06 2005
EXTENSIONS
More terms from Colin Barker, Jul 16 2013
STATUS
approved