A173392 Product of nonzero remainders of n mod k, for k = 1,2,3,...,n.
1, 1, 1, 1, 2, 2, 6, 12, 24, 48, 720, 240, 2160, 23040, 45360, 40320, 2419200, 1935360, 65318400, 69672960, 163296000, 2786918400, 754427520000, 22992076800, 201180672000, 14714929152000, 211843247616000, 114776447385600, 32953394073600000, 2410305395097600
Offset: 1
Keywords
Examples
For n = 7; 7 mod k, for k = 1,2,3,...,7: (0,1,1,3,2,1,0). Product of nonzero remainders = 6. a(7) = 6.
Crossrefs
Cf. A004125 (sum of remainders of n mod k).
Programs
-
Mathematica
Table[Times@@DeleteCases[Mod[n, Range[n]], 0], {n, 30}]
-
PARI
a(n) = prod(k=1, n, if (m = n % k, m, 1)); \\ Michel Marcus, May 23 2018
Extensions
Extended by T. D. Noe, Nov 22 2010