A345335 Primes p such that A014499(k) / A000120(k) is an integer, where k = A000720(p).
2, 3, 5, 7, 19, 23, 29, 41, 53, 67, 71, 73, 83, 89, 97, 113, 131, 139, 193, 197, 211, 269, 281, 283, 311, 317, 337, 347, 349, 353, 359, 373, 389, 479, 503, 521, 523, 547, 563, 587, 593, 601, 647, 661, 691, 719, 739, 839, 857, 863, 881, 887, 929, 937, 983, 1013
Offset: 1
Examples
prime(8) = 19, A014499(8)/A000120(8) = 3, thus 19 is a term.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
Programs
-
Maple
R:= NULL: p:= 1: count:= 0: for n from 1 while count < 100 do p:= nextprime(p); if convert(convert(p,base,2),`+`) mod convert(convert(n,base,2),`+`) = 0 then R:= R,p; count:= count+1 fi; od: R; # Robert Israel, Apr 21 2025
-
Mathematica
Select[Range[1000], PrimeQ[#] && Divisible @@ DigitCount[{#, PrimePi[#]}, 2, 1] &] (* Amiram Eldar, Jun 14 2021 *)
-
PARI
isok(p) = isprime(p) && ((hammingweight(p) % hammingweight(primepi(p))) == 0); \\ Michel Marcus, Jun 14 2021
Comments