OFFSET
1,1
COMMENTS
I conjecture that a number of the form p*2^k + 1 (with odd prime p and odd k) belongs to this sequence if and only if p*2^k + 1 divides (p + 2)^(p*2^k) - 1.
This conjecture has been verified for n up to 10^10.
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
MAPLE
filter:= proc(n) local k; if not isprime(n) then return false fi; k:= padic:-ordp(n-1, 2); k::odd and isprime((n-1)/2^k) end proc:
select(filter, [seq(n, n=3..2000, 2)]); # Robert Israel, Mar 13 2018
MATHEMATICA
lst = {}; Do[v = IntegerExponent[m - 1, 2]; If[OddQ[v], If[PrimeQ[(m - 1)/2^v] && PrimeQ[m], AppendTo[lst, m]]], {m, 3, 1697, 2}]; lst
PROG
(PARI) isok(p) = isprime(p) && (pp=p-1) && (v=valuation(pp, 2)) && (v%2) && isprime(pp/2^v); \\ Michel Marcus, Feb 09 2018
CROSSREFS
KEYWORD
nonn
AUTHOR
Arkadiusz Wesolowski, Feb 07 2018
STATUS
approved