OFFSET
1,1
COMMENTS
Related to hyperperfect numbers of a certain form.
Since x^k-x+1 is divisible by x^2-x+1 for k==2 (mod 6), none of k=8,14,20,... occur. - Robert Israel, Mar 20 2018
LINKS
Robert Israel, Table of n, a(n) for n = 1..4960
J. S. McCranie, A study of hyperperfect numbers, J. Int. Seqs. Vol. 3 (2000) #P00.1.3.
EXAMPLE
11^3 - 11 + 1 = 1321 is prime, so 1321 is a term.
MAPLE
N:= 10^6: # to get all terms <= N
Res:= NULL;
p:= 1:
do
p:= nextprime(p);
if p^2-p+1>N then break fi;
for i from 2 to floor(log[p](N+p-1)) do
if isprime(p^i-p+1) then Res:= Res, p^i-p+1 fi
od
od:
sort(convert({Res}, list)); # Robert Israel, Mar 20 2018
CROSSREFS
KEYWORD
nonn
AUTHOR
STATUS
approved