login
A332029
a(n) is the least number k > 0 such that n^k - (n mod 2) - 1 is prime, or 0 if no such number exists.
0
0, 2, 2, 1, 1, 1, 1, 1, 1, 0, 4, 1, 1, 1, 1, 0, 6, 1, 1, 1, 1, 0, 24, 1, 1, 0, 2, 0, 2, 1, 1, 1, 1, 0, 2, 0, 2, 1, 1, 0, 4, 1, 1, 1, 1, 0, 2, 1, 1, 0, 8, 0, 4, 1, 1, 0, 12, 0, 4, 1, 1, 1, 1, 0, 8, 0, 3, 1, 1, 0, 2, 1, 1, 1, 1, 0, 2, 0, 38, 1, 1, 0, 4, 1, 1, 0, 4
OFFSET
1,2
FORMULA
For k >= 1, a(2*k+2) = A101264(k), a(2*k-1) = A255707(k). - Jinyuan Wang, Feb 07 2020
a(n) = 0 for n in A238204. - Michel Marcus, Feb 08 2020 [Proof: a(n) = 1 iff n - 1 is a prime because n^k - 1 is divisible by n - 1, where k > 1 and n is an even number greater than 2. But if n is a term in A238204, n - m is prime only for some m >= 3. Therefore, a(n) = 0 for n in A238204. - Jinyuan Wang, Feb 08 2020]
CROSSREFS
Sequence in context: A102552 A131341 A124034 * A211312 A085978 A141044
KEYWORD
nonn
AUTHOR
Todor Szimeonov, Feb 05 2020
EXTENSIONS
More terms from Jinyuan Wang, Feb 07 2020
STATUS
approved