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-7 of 7 results.

A293529 Smallest number of iterations of f(x)=A000720(n*x) at x=1 to reach the limit (=A038626(n)).

Original entry on oeis.org

0, 8, 12, 18, 26, 39, 48, 53, 63, 76, 117, 136, 126, 186, 179, 217, 251, 274, 321, 357, 355, 391, 469, 506, 515, 620, 623, 713, 722, 771, 898
Offset: 2

Views

Author

Max Alekseyev, Oct 11 2017

Keywords

Crossrefs

Formula

a(n) = smallest k such that f^(k)(1)=A038626(n).

A038625 a(n) is smallest number m such that m = n*pi(m), where pi(k) = number of primes <= k (A000720).

Original entry on oeis.org

2, 27, 96, 330, 1008, 3059, 8408, 23526, 64540, 175197, 480852, 1304498, 3523884, 9557955, 25874752, 70115412, 189961182, 514272411, 1394193580, 3779849598, 10246935644, 27788566029, 75370121160, 204475052375, 554805820452, 1505578023621, 4086199301996, 11091501630949
Offset: 2

Views

Author

Keywords

Comments

Golomb shows that solutions exist for each n>1.
Equivalently, for n > 1, least m such that m >= n*pi(m). - Eric M. Schmidt, Aug 05 2014
The values a(26),...,a(50) were calculated with the Eratosthenes sieve making use of strong bounds for pi(x), which follow from partial knowledge of the Riemann hypothesis, and the analytic method for calculating initial values of pi(x). - Jan Büthe, Jan 16 2015

Examples

			pi(3059) = 437 and 3059/437 = 7, so a(7)=3059.
		

Crossrefs

Programs

  • Maple
    with(numtheory); f:=proc(n) local i; for i from 2 to 10000 do if i mod pi(i) = 0 and i/pi(i) = n then RETURN(i); fi; od: RETURN(-1); end; # N. J. A. Sloane, Sep 01 2008
  • Mathematica
    t = {}; k = 2; Do[While[n*PrimePi[k] != k, k++]; AppendTo[t, k], {n, 2, 15}]; t (* Jayanta Basu, Jul 10 2013 *)
  • PARI
    a(n)=my(k=1); while(k!=n*primepi(k),k++); k;
    for (n=2, 20, print1(a(n), ", ")); \\ Derek Orr, Aug 13 2014
    
  • Python
    from math import exp
    from sympy import primepi
    def a(n):
      m = 2 if n == 2 else int(exp(n)) # pi(m) > m/log(m) for m >= 17
      while m != n*primepi(m): m += 1
      return m
    print([a(n) for n in range(2, 10)]) # Michael S. Branicky, Feb 27 2021

Formula

It appears that a(n) is asymptotic to e^2*exp(n). - Chris K. Caldwell, Apr 02 2008
a(n) = A038626(n) * n. - Max Alekseyev, Oct 13 2023

Extensions

Three more terms from Labos Elemer, Sep 12 2003
Edited by N. J. A. Sloane at the suggestion of Chris K. Caldwell, Apr 08 2008
24 terms added and entry a(26) corrected by Jan Büthe, Jan 07 2015

A038627 Number of solutions x to n * pi(x) = x, where pi(x) = number of primes <= x.

Original entry on oeis.org

0, 4, 3, 3, 6, 7, 6, 6, 3, 9, 1, 18, 11, 12, 21, 3, 10, 33, 31, 32, 24, 8, 13, 32, 35, 4, 15, 9, 15, 26, 22, 24, 9, 3, 14, 55, 36, 3, 65, 52, 33, 139, 42, 2, 85, 25, 7, 96, 16, 33
Offset: 1

Views

Author

Keywords

Comments

Equivalently, a(n) is number of solutions x to the equation pi(n*x) = x. - Farideh Firoozbakht, Jan 09 2005 [For example, a(2) = 4 because 1, 2, 3 & 4 are all solutions of pi(2*x) = x and a(11) = 1 because 15927 is the only solution of the equation pi(11*x) = x.]
S. W. Golomb proved that a(n) > 0 for each integer n > 1. - Carlo Sanna, Nov 09 2015

Examples

			11*pi(x) = x has only 1 solution, so a(11) = 1.
		

Crossrefs

Programs

  • Mathematica
    (* Assumes upper and lower bounds are as defined in A038626. *)
    xmin = .5; xmax = 2;
    Join[{0},Table[c = 0; x = Floor[2.4*xmin]; x1 = 2.7*xmax + 7;
      xmin = Infinity; xmax = 0; While[x <= x1,
       If[x == PrimePi[n x], c++; xmin = Min[x, xmin];
    xmax = Max[x, xmax]]; x++]; c, {n, 2, 15}]] (* Robert Price, Mar 28 2020 *)

Extensions

One more term from Labos Elemer, Sep 05 2003
a(24)-a(26) from Labos Elemer, Sep 12 2003
Edited by N. J. A. Sloane, Sep 06 2008 at the suggestion of R. J. Mathar
a(27)-a(29) from David Radcliffe, Sep 10 2014
a(29) corrected and a(30)-a(50) obtained from the A038625 values computed by Jan Büthe. - Giovanni Resta, Aug 31 2018

A087235 a(n) is the largest number in the set of solutions to n=x/pi(x), where pi(x)=A000720(x).

Original entry on oeis.org

8, 33, 120, 360, 1134, 3094, 8472, 24300, 64720, 175197, 481452, 1304719, 3524654, 9560100, 25874784, 70119985, 189969354, 514278263, 1394199300, 3779856633, 10246936436, 27788573803, 75370126416, 204475055200, 554805820556, 1505578026105, 4086199303004, 11091501633037
Offset: 2

Views

Author

Labos Elemer, Sep 04 2003

Keywords

Examples

			n=22: list of solutions = {10246935644, 10246935842, 10246935864, 10246935974, 10246936106, 10246936128, 10246936370, 10246936436}, so a(22)=10246936436.
		

Crossrefs

Formula

a(n) = Max{x; n*pi(x)=x}.

Extensions

More terms from David Radcliffe, Sep 10 2014
a(29) corrected and a(30)-a(50) obtained from the values of A038625 computed by Jan Büthe. - Giovanni Resta, Sep 01 2018

A102281 a(n) is the largest number m such that m = pi(n*m).

Original entry on oeis.org

4, 11, 30, 72, 189, 442, 1059, 2700, 6472, 15927, 40121, 100363, 251761, 637340, 1617174, 4124705, 10553853, 27067277, 69709965, 179993173, 465769838, 1208198861, 3140421934, 8179002208, 21338685406, 55762149115, 145935689393
Offset: 2

Views

Author

Farideh Firoozbakht, Jan 09 2005; extended Sep 13 2005

Keywords

Comments

All known terms of this sequence satisfy the relation 2.4*a(n) - 12 < a(n+1) < 2.7*a(n) + 1 is true.
a(n) is the largest number m such that floor(prime(m)/m)=n-1. - Farideh Firoozbakht, Sep 13 2005

Examples

			3140421934 = pi(24*3140421934) and 3140421934 is the largest number with this property, so a(24) = 3140421934.
		

Crossrefs

Extensions

a(24) corrected by Max Alekseyev, Jul 18 2011
a(29)-a(50) obtained from the A038625 values computed by Jan Büthe. - Giovanni Resta, Aug 31 2018

A087237 a(n) = (Max{x : n*pi(x) = x} - Min{x : n*pi(x) = x})/n = A087236(n)/n.

Original entry on oeis.org

3, 2, 6, 6, 21, 5, 8, 86, 18, 0, 50, 17, 55, 143, 2, 269, 454, 308, 286, 335, 36, 338, 219, 113, 4, 92, 36, 72, 296, 296, 327, 23, 2, 168, 658, 770, 90, 1274, 1454, 1514, 3259, 612, 6, 2896, 367, 15, 2011, 287, 1915
Offset: 2

Views

Author

Labos Elemer, Sep 04 2003

Keywords

Comments

a(n) is the difference between the largest and smallest solutions to n = x/pi(x), divided by n, where pi(x) = A000720(x).
Equivalently, a(n) is the difference between largest solution and smallest natural solution of the equation pi(n*x) = x. - Farideh Firoozbakht, Jan 09 2005 [Max Alekseyev observes that this is trivially equivalent to the first definition.]

Examples

			n=22: a(22) = (10246936436-10246935644)/22 = 792/22 = 36.
a(2) = 3 because 1, 2, 3 & 4 are all solutions of pi(2*x) = x and 4 - 1 = 3; a(11) = 0 because 15927 is the only solution of the equation pi(11*x) = x and 15927 - 15927 = 0. - _Farideh Firoozbakht_, Jan 09 2005
		

Crossrefs

Programs

  • Mathematica
    MapIndexed[(Last@ #1 - First@ #1)/(First@ #2 + 1) &, Values@ Rest@ KeySort@ PositionIndex@ Table[n/PrimePi[n] /. k_ /; Not@ IntegerQ@ k -> 0, {n, 2, 10^6}]] (* Michael De Vlieger, Mar 25 2017, Version 10 *)

Formula

a(n) = A102281(n) - A038626(n). - Farideh Firoozbakht, Jan 09 2005

Extensions

Edited by N. J. A. Sloane, Oct 28 2008 at the suggestion of R. J. Mathar
24 additional terms from Jan Büthe, Jan 16 2015

A086511 a(n) is the smallest integer k > 1 such that k > n * pi(k), where pi() denotes the prime counting function.

Original entry on oeis.org

2, 9, 28, 121, 336, 1081, 3060, 8409, 23527, 64541, 175198, 480865, 1304499, 3523885, 9557956, 25874753, 70115413, 189961183, 514272412, 1394193581, 3779849620, 10246935645, 27788566030, 75370121161, 204475052376, 554805820453, 1505578023622, 4086199301997
Offset: 1

Views

Author

Tim Paulden (timmy(AT)cantab.net), Sep 09 2003

Keywords

Comments

a(n) is bounded above by the sequence A038623, in which k is required to be prime. In addition, the sequence pi(a(n)) = {1, 4, 9, 30, 67, 180, 437, 1051, ...} closely resembles the sequence A038624, in which the n-th term is the minimal t such that k >= n * pi(k) for every k satisfying pi(k) = t. If we were to make the inequality in A038624 strict, the resulting sequence would provide an upper bound for pi(a(n)). Sequences A038625, A038626 and A038627 focus on the equality k = n * pi(k): as we would expect, a(n) follows A038625 very closely for large n.

Examples

			Consider the pairs (k, pi(k)) for k > 1. The inequality k > 1 * pi(k) is first satisfied at k = 2 and so a(1) = 2. Similarly, the inequality k > 2 * pi(k) is first satisfied at k = 9 and so a(2) = 9.
		

Crossrefs

Programs

  • PARI
    a(n) = { k = 2; while (k <= n*primepi(k), k++); return (k);} \\ Michel Marcus, Jun 19 2013

Formula

Heuristically, for large n, a(n) ~= 3.0787*(2.70888^n) [error < 0.05% for 15 <= n <= 20].
From Nathaniel Johnston, Apr 10 2011: (Start)
a(n) >= exp(n/2 + sqrt(n^2 + 4n)/2), n >= 6.
a(n) = A038625(n) + m(n)*n + 1 for some m(n) >= 0. For n = 2, 3, 4, ..., m(n) = 3, 0, 6, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, ...
(End)

Extensions

a(21)-a(26) from Nathaniel Johnston, Apr 10 2011
Corrected a(26) and a(27)-a(28) from Giovanni Resta, Sep 01 2018
a(29)-a(50) obtained from the values of A038625 computed by Jan Büthe. - Giovanni Resta, Sep 01 2018
Showing 1-7 of 7 results.