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.

Showing 1-10 of 10 results.

A033844 a(n) = prime(2^n).

Original entry on oeis.org

2, 3, 7, 19, 53, 131, 311, 719, 1619, 3671, 8161, 17863, 38873, 84017, 180503, 386093, 821641, 1742537, 3681131, 7754077, 16290047, 34136029, 71378569, 148948139, 310248241, 645155197, 1339484197, 2777105129, 5750079047, 11891268401, 24563311309, 50685770167, 104484802057, 215187847711
Offset: 0

Views

Author

Vasiliy Danilov (danilovv(AT)usa.net), Jun 15 1998

Keywords

Comments

a(n) is the smallest number m such that pi(m)=d(m)^n, where d(m) is number of positive divisors of m (the proof is easy). - Farideh Firoozbakht, Jun 06 2005

Crossrefs

Programs

Extensions

More terms from Robert G. Wilson v, Jun 09 2000

A082862 Prime(2^j) where j are the positions at which (prime(2^k+1)-prime(2^k))/log(prime(2^k)) set low-value records.

Original entry on oeis.org

2, 19, 131, 311, 1619, 3671, 1742537, 148948139, 2777105129, 16149760533341, 10082409897709157
Offset: 1

Views

Author

Labos Elemer, Apr 14 2003

Keywords

Comments

Similar to but not identical to A074327.

Examples

			The values of quotients at primes of this sequence are as follows: 1.442695..., 1.358493..., 1.230719..., 0.348444..., 0.270651..., 0.243658..., 0.139170..., 0.106274..., 0.091976..., 0.065761..., 0.054274... .
		

Crossrefs

Programs

  • Mathematica
    q=4; Do[s=(Prime[2^n+1]-Prime[2^n])/Log[Prime[2^n]]//N; If[sAmiram Eldar, Aug 10 2024 *)

Extensions

Data corrected and extended by Amiram Eldar, Aug 10 2024

A051438 a(n) = prime(2^n - 1).

Original entry on oeis.org

2, 5, 17, 47, 127, 307, 709, 1613, 3659, 8147, 17851, 38867, 84011, 180497, 386083, 821603, 1742527, 3681113, 7754017, 16290041, 34136021, 71378551, 148948133, 310248233, 645155191, 1339484149, 2777105117, 5750079043, 11891268397, 24563311217, 50685770143
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

Formula

a(n) = A181363(2^n - 1). - Reinhard Zumkeller, Oct 16 2010
a(n) = A000040(A000225(n)). - Michel Marcus, Nov 28 2017
a(n) = A151799(A033844(n)). - Amiram Eldar, Jun 30 2024

Extensions

More terms from Michael Lugo (mlugo(AT)thelabelguy.com), Dec 22 1999

A073798 pi(n) is a power of 2, where pi(n) = A000720(n) is the number of primes <= n.

Original entry on oeis.org

2, 3, 4, 7, 8, 9, 10, 19, 20, 21, 22, 53, 54, 55, 56, 57, 58, 131, 132, 133, 134, 135, 136, 311, 312, 719, 720, 721, 722, 723, 724, 725, 726, 1619, 1620, 3671, 3672, 8161, 8162, 8163, 8164, 8165, 8166, 17863, 17864, 17865, 17866, 17867, 17868, 17869, 17870
Offset: 1

Views

Author

Labos Elemer, Aug 14 2002

Keywords

Comments

The numbers occur in blocks of consecutive integers: 2, 3-4, 7-10, 19-22, ...; the n-th block starts at the 2^n-th prime (A033844) and ends just before the (2^n + 1)-th prime (A051439).

Examples

			10 is in the sequence since pi(10)=4=2^2.
		

Crossrefs

Programs

  • Mathematica
    pow2[n_] := n==1||(n>1&&IntegerQ[n/2]&&pow2[n/2]); Select[Range[20000], pow2[PrimePi[ # ]]&]
    Flatten@Table[Range[p = Prime[2^k], NextPrime[p] - 1], {k, 0, 11}] (* Ivan Neretin, Jan 21 2017 *)
  • PARI
    isok(n) = my(pi = primepi(n)); (pi==1) || (pi==2) || (ispower(primepi(n),,&k) && (k==2)); \\ Michel Marcus, Jan 23 2017

Extensions

Edited by Dean Hickerson, Aug 15 2002

A018249 a(n) = prime(2^n)-1.

Original entry on oeis.org

1, 2, 6, 18, 52, 130, 310, 718, 1618, 3670, 8160, 17862, 38872, 84016, 180502, 386092, 821640, 1742536, 3681130, 7754076, 16290046, 34136028, 71378568, 148948138, 310248240, 645155196, 1339484196, 2777105128, 5750079046, 11891268400, 24563311308, 50685770166, 104484802056
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

Formula

a(n) = A033844(n) - 1.
a(n) = A051440(n) - 2. - Amiram Eldar, Jul 11 2025

Extensions

More terms from Amiram Eldar, Jul 11 2025

A051440 a(n) = prime(2^n) + 1.

Original entry on oeis.org

3, 4, 8, 20, 54, 132, 312, 720, 1620, 3672, 8162, 17864, 38874, 84018, 180504, 386094, 821642, 1742538, 3681132, 7754078, 16290048, 34136030, 71378570, 148948140, 310248242, 645155198, 1339484198, 2777105130, 5750079048, 11891268402, 24563311310, 50685770168, 104484802058
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := Prime[2^n] + 1; Array[a, 33, 0] (* Amiram Eldar, Jul 11 2025 *)
  • PARI
    a(n) = prime(2^n) + 1; \\ Amiram Eldar, Jul 11 2025

Formula

a(n) = A033844(n) + 1.
a(n) = A018249(n) + 2. - Amiram Eldar, Jul 11 2025

Extensions

More terms from Amiram Eldar, Jul 11 2025

A074325 Difference between (1+2^n)-th and (2^n)-th primes. Also number of terms in blocks of A073798.

Original entry on oeis.org

1, 2, 4, 4, 6, 6, 2, 8, 2, 2, 6, 18, 18, 30, 8, 24, 6, 2, 18, 4, 26, 30, 34, 2, 10, 30, 10, 2, 30, 6, 70, 4, 12, 22, 6, 24, 26, 10, 88, 2, 50, 18, 6, 20, 14, 4, 12, 6, 2, 56, 4, 30, 42, 6, 70, 74, 14, 60, 170, 14, 44, 22, 52, 36, 96, 6, 86, 86, 72, 48, 42, 18, 20, 24, 10, 154, 54, 20, 12
Offset: 0

Views

Author

Labos Elemer, Aug 21 2002

Keywords

Examples

			For n = 39: 2^39 = 549755813888, prime(549755813889) = 16149760533343, prime(549755813888) =  16149760533341, difference = 2 (just twin primes), so a(39) = 2.
		

Crossrefs

Programs

  • Mathematica
    Table[Prime[1+2^n] - Prime[2^n], {n, 1, 39}]

Formula

a(n) = A051439(n) - A033844(n).
a(n) = A001223(A000079(n)). - Michel Marcus, May 10 2024

Extensions

More terms from Michel ten Voorde Jun 13 2003
a(42) from Max Alekseyev, May 08 2009
Offset corrected by Max Alekseyev, Oct 24 2013
a(43)-a(57) from Chai Wah Wu, Aug 30 2019
a(58)-a(78) calculated using the data at A033844 and A051439 and added by Amiram Eldar, May 10 2024

A073799 Numbers that begin a run of consecutive integers k such that PrimePi(k) divides 2^k.

Original entry on oeis.org

2, 7, 19, 53, 131, 311, 719, 1619, 3671, 8161, 17863, 38873, 84017, 180503, 386093, 821641, 1742537, 3681131, 7754077, 16290047, 34136029, 71378569, 148948139, 310248241, 645155197, 1339484197, 2777105129, 5750079047, 11891268401, 24563311309, 50685770167, 104484802057, 215187847711
Offset: 1

Views

Author

Labos Elemer, Aug 12 2002

Keywords

Comments

It seems that each term is a bit larger than twice the previous one.
Runs have lengths 3, 4, 4, 6, 6, 2, 8, 2, 2, 6, 18, 18, 30, 8, 24, 6, 2, 18, ..., respectively.
From Chai Wah Wu, Jan 27 2020: (Start)
Theorem: a(1) = 2 and a(n) = A033844(n) for n > 1. For n > 1, the length of the n-th run is prime(2^n+1)-prime(2^n) = A051439(n)-A033844(n) = A074325(n).
Proof: Let r > 1. If p = prime(2^r), then primepi(p) = 2^r.
primepi(p-1) = 2^r - 1. Since r > 1, 2^r - 1 > 2 and odd and thus does not divide any power of 2.
In addition 2^r < p and thus divides 2^p. This means that p is a term. Let q be such that p < q < prime(2^r+1). Then primepi(q) = 2^r and divides 2^q. Since primepi(q-1) = 2^r and divides 2^(q-1), this means that q does not start a run and thus is not a term.
Let w be such that prime(2^r+1) <= w < prime(2^(r+1)). Then 2^r + 1 <= primepi(w) < 2^(r+1) and does not divide any power of 2. This means that w is not a term.
(End)

Crossrefs

Programs

  • Mathematica
    aQ[k_] := Divisible[2^k, PrimePi[k]]; s = {}; len = {}; n = 2; While[Length[s] < 10, While[! aQ[n], n++]; n1 = n; While[aQ[n], n++]; If[n > n1, AppendTo[s, n1]; AppendTo[len, n - n1]]; n++]; s (* Amiram Eldar, Dec 11 2018 *)
  • PARI
    a(n) = if(n==1, 2, prime(2^n)); \\ Jinyuan Wang, Mar 01 2020
  • Python
    from sympy import prime
    def A073799(n):
        return 2 if n == 1 else prime(2**n) # Chai Wah Wu, Jan 27 2020
    

Formula

Solutions to 2^(x-1) mod PrimePi(x-1) > 0 but 2^x mod PrimePi(x) = 0.
a(n) = A033844(n) for n > 1. - Chai Wah Wu, Jan 27 2020

Extensions

Edited by Jon E. Schoenfield, Dec 10 2018
a(15)-a(18) from Amiram Eldar, Dec 11 2018
a(19)-a(33) from Chai Wah Wu, Jan 27 2020

A074326 Numbers n such that difference between (1+2^n)-th and (2^n)-th primes is 2.

Original entry on oeis.org

1, 6, 8, 9, 17, 23, 27, 39, 48
Offset: 1

Views

Author

Labos Elemer, Aug 21 2002

Keywords

Examples

			n=39: 2^39=549755813888, prime(549755813889) = 16149760533343, prime(549755813888) = 16149760533341, difference=2, just twin primes.
		

Crossrefs

Programs

  • Mathematica
    s=0; Do[s=Prime[1+2^n]-Prime[2^n]; If[s==2, Print[{n, Prime[2^n]}]], {n, 1, 40}]
    diffQ[n_]:=Module[{prn=Prime[2^n]},NextPrime[prn]-prn==2]; Select[ Range[ 40],diffQ] (* Harvey P. Dale, Aug 21 2014 *)

Formula

Solutions to A051439(x) - A033844(x) = 2,

Extensions

a(9) from Chai Wah Wu, Feb 28 2019

A074327 Smaller of twin primes arising in A074326.

Original entry on oeis.org

3, 311, 1619, 3671, 1742537, 148948139, 2777105129, 16149760533341, 10082409897709157
Offset: 1

Views

Author

Labos Elemer, Aug 21 2002

Keywords

Examples

			8th term in A074326 is 39, so prime[549755813888]=16149760533341=a(8) and 16149760533343 is the larger twin.
		

Crossrefs

Programs

  • Mathematica
    s=0; Do[s=Prime[1+2^n]-Prime[2^n]; If[s==2, Print[Prime[2^n]]], {n, 1, 40}]

Formula

a(n) = prime(m) where m=2^x and prime(m+1)-prime(m) = 2.
a(n) = A033844(A074326(n)). - Michel Marcus, Aug 28 2019

Extensions

Corrected and extended by Michel Marcus, Aug 28 2019
Showing 1-10 of 10 results.