login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A175624 a(n) = n! modulo n*(n+1)*(n+2)/3. 1
1, 2, 6, 24, 50, 48, 0, 0, 210, 120, 352, 168, 0, 0, 800, 288, 1122, 360, 0, 0, 2002, 528, 0, 0, 0, 0, 4032, 840, 4930, 960, 0, 0, 0, 0, 8400, 1368, 0, 0, 11440, 1680, 13202, 1848, 0, 0, 17250, 2208, 0, 0, 0, 0, 24752, 2808, 0, 0, 0, 0, 34162, 3480, 37760, 3720, 0, 0, 0, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
It appears that a(1)=1, a(2)=2, a(3)=6, and, for n>3, a(n) = n*(n+2) if n+1 is prime, else a(n) = n*(n+1)*(n+5)/6 if n+2 is prime, else a(n)=0. This has been verified for n up to 1000.
LINKS
MATHEMATICA
Table[Mod[(n!), (n^3 + 3 n^2 + 2 n)/3], {n, 100}] (* Vincenzo Librandi, Jul 10 2014 *)
PROG
(PARI) a(n) = n! % (n*(n+1)*(n+2)/3); \\ Michel Marcus, Jul 09 2014
(Magma)
[Factorial(n) mod (2*Binomial(n+2, 3)): n in [1..80]]; // G. C. Greubel, Apr 12 2024
(SageMath)
[factorial(n)%(2*binomial(n+2, 3)) for n in range(1, 81)] # G. C. Greubel, Apr 12 2024
CROSSREFS
Sequence in context: A189563 A321613 A104114 * A289161 A118038 A240428
KEYWORD
nonn
AUTHOR
John W. Layman, Jul 27 2010
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 10 02:54 EDT 2024. Contains 375770 sequences. (Running on oeis4.)