OFFSET
1,1
COMMENTS
In the notation of A139370, a prime p is in the sequence iff e(p)>o(p) and e(p)-o(p)== 4 or 5 (mod 6). [Vladimir Shevelev, Dec 12 2008]
MATHEMATICA
aQ[n_] := PrimeQ[n] && EvenQ[Count[IntegerDigits[n, 2], 1]] == OddQ[Mod[n, 3]] && Module[{d = Reverse[IntegerDigits[n, 2]]}, Total@d[[1;; -1;; 2]] >= Total@d[[2;; -1;; 2]]]; Select[Range[5300], aQ] (* Amiram Eldar, Dec 15 2018 *)
PROG
(PARI) isokp(p) = (p>2) && isprime(p) && ((hammingweight(p) % 2) != ((p % 3) % 2)); \\ A065049
isok0(n) = {my(irb = Vec(select(x->(x%2), Vecrev(binary(n)), 1))); #select(x->(x%2), irb) < #irb/2; } \\ A139370
isok(p) = isokp(p) && !isok0(p); \\ Michel Marcus, Dec 15 2018
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Shevelev, Dec 11 2008, Dec 12 2008
EXTENSIONS
Missing 853 and more terms from Michel Marcus, Dec 15 2018
STATUS
approved