A181569 Greatest common divisor of n! and n+1.
1, 1, 2, 1, 6, 1, 8, 9, 10, 1, 12, 1, 14, 15, 16, 1, 18, 1, 20, 21, 22, 1, 24, 25, 26, 27, 28, 1, 30, 1, 32, 33, 34, 35, 36, 1, 38, 39, 40, 1, 42, 1, 44, 45, 46, 1, 48, 49, 50, 51, 52, 1, 54, 55, 56, 57, 58, 1, 60, 1, 62, 63, 64, 65, 66, 1, 68, 69, 70, 1, 72, 1, 74, 75, 76, 77, 78, 1
Offset: 1
Examples
a(6) = 1 because 6! and 7 are coprime. a(7) = 8 because 7! = 5040 and gcd(5040, 8) = 8. a(8) = 9 because 8! = 40320 and gcd(40320, 9) = 9.
Links
- Vincenzo Librandi, Table of n, a(n) for n = 1..1000
Programs
-
Magma
[GCD(Factorial(n), n+1): n in [1..80]]; // Vincenzo Librandi, Mar 03 2014
-
Maple
A181569:=n->gcd(n!,n+1): seq(A181569(n), n=1..100); # Wesley Ivan Hurt, Aug 13 2015
-
Mathematica
Table[GCD[n!, n + 1], {n, 80}] (* Alonso del Arte, Feb 25 2014 *)
-
PARI
a(n)= n!/denominator(polcoeff((x+1)*exp(x+x*O(x^n)), n)); \\ Gerry Martens, Aug 12 2015
-
PARI
A181569(n)=gcd(n!,n+1) \\ M. F. Hasler, Aug 16 2015
Comments