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!)
A341889 a(n) is the smallest positive integer k > 1 such that n + k divides n^n + k, or 0 if no such k exists. 5
2, 0, 3, 2, 3, 4, 2, 6, 3, 5, 4, 10, 2, 12, 5, 2, 3, 16, 2, 18, 3, 4, 10, 22, 3, 24, 9, 8, 6, 28, 2, 30, 7, 17, 5, 6, 2, 36, 9, 5, 3, 40, 6, 42, 3, 4, 22, 46, 2, 20, 4, 16, 7, 52, 2, 14, 3, 5, 28, 58, 2, 60, 9, 8, 3, 9, 2, 66, 11, 20, 4, 70, 3, 72, 20, 14, 3, 8, 5, 78, 4, 32, 40, 82, 2, 24, 29, 11, 3, 88, 2, 6, 7, 23 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
k > 1 is needed in the definition as n+1 divides n^n+1 for all odd n. - Chai Wah Wu, Jun 04 2021
LINKS
MATHEMATICA
a[n_] := Module[{k = 2}, While[! Divisible[n^n + k, n + k], k++]; k]; Array[a, 100, 3] (* Amiram Eldar, Jun 04 2021 *)
PROG
(PARI) a(n) = if(n==2, 0, my(k=2); while((n^n+k)%(n+k)!=0, k++); k);
CROSSREFS
Sequence in context: A243403 A051613 A173291 * A078031 A077961 A077962
KEYWORD
nonn
AUTHOR
Seiichi Manyama, Jun 04 2021
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 April 25 11:34 EDT 2024. Contains 371967 sequences. (Running on oeis4.)