login
a(n) = (-1)^(p-1)*(p-1)! + 1 where p = prime(n).
0

%I #11 Jul 04 2021 08:42:59

%S 0,3,25,721,3628801,479001601,20922789888001,6402373705728001,

%T 1124000727777607680001,304888344611713860501504000001,

%U 265252859812191058636308480000001

%N a(n) = (-1)^(p-1)*(p-1)! + 1 where p = prime(n).

%C Apart from the first term, the same as A060371. - _R. J. Mathar_, Oct 02 2008

%D D. M. Burton, Elementary Number Theory, Allyn and Bacon, Inc. Boston, MA, 1976, p. 164.

%o (PARI) for(n=1,13,print((-1)^(prime(n)-1)*(prime(n)-1)!+1))

%K easy,nonn

%O 1,2

%A _Jason Earls_, Jul 09 2001