|
|
A168161
|
|
Primes p which are equal to the sum of the binary digits in all primes <= p.
|
|
6
|
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
|
|
LINKS
|
|
|
FORMULA
|
|
|
MATHEMATICA
|
sbdQ[n_]:=Total[Flatten[IntegerDigits[#, 2]&/@Prime[Range[PrimePi[ n]]]]] == n; Select[Prime[Range[20]], sbdQ] (* Harvey P. Dale, Feb 04 2015 *)
|
|
PROG
|
(PARI) s=0; forprime(p=1, 9999, if(p==s+=norml2(binary(p)), print1(p, ", ")))
|
|
CROSSREFS
|
|
|
KEYWORD
|
fini,full,nonn,base
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|