login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A116891
a(n) = gcd(n! + 1, n^n + 1).
4
2, 1, 7, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 47, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 79, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 103, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 127, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 191, 1, 1, 1, 199, 1, 1
OFFSET
1,1
COMMENTS
Apparently all the values greater than 1 (cf. A116892) are prime numbers and are equal to 2n+1 with only 4 exceptions for n<82000 (cf. A116894).
From Antti Karttunen, Jul 22 2018: (Start)
The first duplicated value > 1 is 157519 = a(43755) = a(78759). Note that 43755 = 15*2917, while 78759 = 27*2917.
It seems that for the long time after a(1) = 2, all other terms > 1 occur only at such positions k that k+1 is not squarefree. However, this turns out to be false as a(208161) = 555097, and 208162 is a squarefree number.
(End)
LINKS
EXAMPLE
a(3) = gcd(3! + 1, 3^3 + 1) = gcd(7,28) = 7.
MATHEMATICA
Table[GCD[n! + 1, n^n + 1], {n, 101}] (* Robert G. Wilson v, Mar 09 2006 *)
PROG
(PARI) A116891(n) = gcd(n!+1, (n^n)+1); \\ Antti Karttunen, Jul 22 2018
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Giovanni Resta, Mar 01 2006
STATUS
approved