login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A280999 Numbers with a prime number of 0's in their binary reflected Gray code representation. 4
7, 8, 12, 14, 15, 16, 17, 19, 23, 24, 25, 27, 28, 29, 30, 33, 34, 35, 36, 38, 39, 40, 44, 46, 47, 49, 50, 51, 52, 54, 55, 57, 58, 59, 61, 63, 64, 66, 68, 69, 70, 72, 73, 75, 76, 77, 78, 80, 81, 83, 87, 88, 89, 91, 92, 93, 94, 96, 98, 100, 101, 102, 104, 105, 107 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
Wikipedia, Gray code.
EXAMPLE
27 is in the sequence because the binary reflected Gray Code representation of 27 is 10110 which has 2 0's and 2 is prime.
MATHEMATICA
Select[Range[100], PrimeQ[DigitCount[BitXor[#, Floor[#/2]], 2, 0]] &] (* Amiram Eldar, May 01 2021 *)
PROG
(PARI) is(n)=isprime(logint(n, 2)-hammingweight(bitxor(n, n>>1))+1) \\ Charles R Greathouse IV, Jan 13 2017
CROSSREFS
Sequence in context: A106630 A050798 A260628 * A024706 A050901 A105832
KEYWORD
nonn,base,easy
AUTHOR
Indranil Ghosh, Jan 12 2017
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 04:42 EDT 2024. Contains 371964 sequences. (Running on oeis4.)