OFFSET
1,4
COMMENTS
Very similar to A076998.
For all n, a(A013929(n)) != 0, and a(A005117(n)) = 0. - Michel Marcus, Sep 03 2013 and Antti Karttunen, Nov 20 2017
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..16384
FORMULA
a(n) = A002110(n) mod n. - Michel Marcus, Sep 03 2013
EXAMPLE
a(9) = p(9)# mod 9 = 23# mod 9 = 2*3*5*7*11*13*17*19*23 mod 9 = 6.
MATHEMATICA
Array[Mod[Product[Prime@ i, {i, #}], #] &, 91] (* Michael De Vlieger, Nov 20 2017 *)
Module[{nn=100, prlm}, prlm=FoldList[Times, Prime[Range[nn]]]; Mod[ #[[1]], #[[2]]]&/@ Thread[{prlm, Range[nn]}]] (* Harvey P. Dale, May 14 2022 *)
PROG
(PARI) a(n) = prod(i=1, n, prime(i)) % n; \\ Michel Marcus, Sep 03 2013
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Carl R. White, Mar 03 2010
STATUS
approved