OFFSET
1,1
COMMENTS
2 together with Lucasian primes (A002515).
Primes p such that p^(p + 1) == p + 1 (mod 2*p + 1).
FORMULA
a(n) >> n log^2 n. - Charles R Greathouse IV, Jul 25 2024
EXAMPLE
2 is in this sequence because 2^(2 + 1) = 8 and 8 = 3 (mod 2*2 + 1) where 2 prime.
MATHEMATICA
Select[Prime[Range[490]], Mod[#^(#+1), 2#+1]==#+1 &] (* Stefano Spezia, Jul 23 2024 *)
PROG
(PARI) list(lim)=my(v=List([2])); forprimestep(p=3, lim\1, 4, if(isprime(2*p+1), listput(v, p))); Vec(v) \\ Charles R Greathouse IV, Jul 25 2024
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Juri-Stepan Gerasimov, Jul 23 2024
STATUS
approved