login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A326782 Numbers whose binary indices are prime numbers. 2
0, 2, 4, 6, 16, 18, 20, 22, 64, 66, 68, 70, 80, 82, 84, 86, 1024, 1026, 1028, 1030, 1040, 1042, 1044, 1046, 1088, 1090, 1092, 1094, 1104, 1106, 1108, 1110, 4096, 4098, 4100, 4102, 4112, 4114, 4116, 4118, 4160, 4162, 4164, 4166, 4176, 4178, 4180, 4182, 5120 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

A binary index of n is any position of a 1 in its reversed binary expansion. The binary indices of n are row n of A048793.

Write n = 2^e_1 + 2^e_2 + 2^e_3 + ..., with e_1>e_2>e_3>... We require that all the numbers e_i + 1 are primes. So 6 = 2^2+2^1 is OK because 2+1 and 1+1 are primes. 0 is OK because there are no e_i. - N. J. A. Sloane, Jul 27 2019

LINKS

Robert Israel, Table of n, a(n) for n = 1..10000

EXAMPLE

The sequence of terms together with their binary indices begins:

     0: {}

     2: {2}

     4: {3}

     6: {2,3}

    16: {5}

    18: {2,5}

    20: {3,5}

    22: {2,3,5}

    64: {7}

    66: {2,7}

    68: {3,7}

    70: {2,3,7}

    80: {5,7}

    82: {2,5,7}

    84: {3,5,7}

    86: {2,3,5,7}

  1024: {11}

  1026: {2,11}

  1028: {3,11}

  1030: {2,3,11}

MAPLE

f:= proc(n) local L, i;

  L:= convert(n, base, 2);

  add(L[i]*2^(ithprime(i)-1), i=1..nops(L))

end proc:

map(f, [$0..100]); # Robert Israel, Jul 26 2019

MATHEMATICA

bpe[n_]:=Join@@Position[Reverse[IntegerDigits[n, 2]], 1];

Select[Range[0, 100], And@@PrimeQ/@bpe[#]&]

CROSSREFS

Cf. A000120, A029931, A048793, A070939, A326031, A326701, A326781, A326788.

Sequence in context: A005179 A037019 A341668 * A096174 A096173 A287681

Adjacent sequences:  A326779 A326780 A326781 * A326783 A326784 A326785

KEYWORD

nonn

AUTHOR

Gus Wiseman, Jul 25 2019

STATUS

approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 2 12:26 EST 2021. Contains 341750 sequences. (Running on oeis4.)