OFFSET
1,2
COMMENTS
All terms are even.
It appears that f(n)=(n!)^(2k+1) modulo n(n+1)/2 is n if n is one less than an odd prime, else f(n) is 0, for any integer k. See A175567 for related results involving an even power of n!. - John W. Layman, Jul 12 2010
FORMULA
a(n) = n if n+1 is an odd prime, a(n) = 0 otherwise.
MAPLE
P:=proc(n) local i, j, k; j:=1; k:=0; for i from 1 by 1 to n do j:=j*i; k:=k+i; print(j mod k); od; end: P(100);
PROG
(Magma) [ Factorial(n) mod (n*(n+1) div 2): n in [1..100] ];
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Paolo P. Lava and Giorgio Balzarotti, Jun 09 2006
STATUS
approved