cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A081093 a(n) is the smallest prime such that the number of 1's in its binary expansion is equal to the n-th prime.

Original entry on oeis.org

3, 7, 31, 127, 3583, 8191, 131071, 524287, 14680063, 1073479679, 2147483647, 266287972351, 4260607557631, 17591112302591, 246290604621823, 17996806323437567, 1152917106560335871, 2305843009213693951
Offset: 1

Views

Author

Reinhard Zumkeller, Mar 05 2003

Keywords

Comments

a(n) = Min{p: A000120(p)=A000040(n), p prime}.
If 2^(Prime[n]) - 1 is a prime number, then a(n) = 2^(Prime[n]) - 1, where Prime[n] denotes the n-th prime number. This means that every Mersenne prime arises in this sequence. - Stefan Steinerberger, Jan 22 2006
For all n with prime(n) < 300, a(n) has either prime(n) or prime(n)+1 bits. - David Wasserman, Oct 25 2006

Examples

			n=4, p[4]=11, 3583=[11011111111] has 11 digits=1 and is prime;
2047=23.89=[11111111111] is not here because it is composite.
a(5)=3583=A081092(266)=A000040(502) having eleven 1's: '110111111111' and A000120(p)<11=prime(5) for primes p<3583.
Mersenne-primes are here, Mersenne composites not.
		

Crossrefs

Programs

  • Mathematica
    Do[k=1;While[Count[IntegerDigits[Prime[k], 2], 1] !=Prime[n], k++ ];Print[Prime[k]], {n, 1, 10}]

Formula

a(n) = A061712(A000040(n)). - Franklin T. Adams-Watters, Jun 06 2006

Extensions

More terms from Franklin T. Adams-Watters, Jun 06 2006
Further terms from David Wasserman, Oct 25 2006
Edited by N. J. A. Sloane, Sep 15 2008 at the suggestion of R. J. Mathar