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

A079416 a(n) = round(prime(n)/n).

Original entry on oeis.org

2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5
Offset: 1

Views

Author

Reinhard Zumkeller, Jan 07 2003

Keywords

Comments

The sequence is not monotone, see example and A079417.

Examples

			a(20) = round(prime(20)/20) = round(71/20) = round(3.55) = 4;
a(21) = round(prime(21)/21) = round(73/21) = round(3.476190...) = 3;
a(22) = round(prime(22)/22) = round(79/22) = round(3.590909...) = 4.
		

Crossrefs

Programs

  • Magma
    [Round(NthPrime(n)/n): n in [1..100]]; // G. C. Greubel, Jan 18 2019
    
  • Mathematica
    f[n_] := Round[ Prime[n]/n]; Array[f, 105] (* Robert G. Wilson v, Oct 23 2015 *)
  • PARI
    vector(100, n, round(prime(n)/n)) \\ G. C. Greubel, Jan 18 2019
    
  • Sage
    [round(nth_prime(n)/n) for n in (1..100)] # G. C. Greubel, Jan 18 2019

A107610 Least number k such that round(k/pi(k)) = n.

Original entry on oeis.org

2, 16, 56, 190, 556, 1821, 4928, 14136, 39017, 107405, 291330, 791513, 2148323, 5797898, 15726486, 42605113, 115371428, 312629484, 847000031, 2295700537, 6223257066, 16874397811, 45764114391, 124142354193, 336811260666
Offset: 2

Views

Author

Keywords

Comments

a(n) is the index of the first occurrence of n in A107609.
Lim_{n->infinity} a(n+1)/a(n) ~ e.

Examples

			a(2) = 16 because round(16/pi(16)) = round(16/6) = 3 and for no number less than 16 does the quotient equal 3.
		

Crossrefs

Programs

  • Mathematica
    f[n_] := Round[ n / PrimePi[ n]]; g[2] = 2; g[n_] := g[n] = Block[{k = PrimePi[E g[n - 1]]}, While[ f[k] < n, k++ ]; k]; Do[ Print[ g[ n]], {n, 2, 26}]

Formula

a(n) = min { k >= 2 : round(k/pi(k)) = n }.

A107614 Consider the least number n such that n divided by pi(n) rounded is greater than any previous n; a(n) is the denominator of n/pi(n).

Original entry on oeis.org

1, 6, 16, 42, 101, 280, 657, 1663, 4107, 10229, 25333, 63321, 159135, 399855, 1014612, 2582128, 6592653, 16898891, 43435899, 111985392, 289453817, 749973236, 1947409123, 5067034865, 13208284732, 34487824962, 90192879037
Offset: 2

Views

Author

Keywords

Comments

Lim_{n->infinity} a(n+1)/a(n) ~ e.

Crossrefs

Programs

  • Mathematica
    f[n_] := Round[ n / PrimePi[ n]]; g[2] = 2; g[n_] := g[n] = Block[{k = PrimePi[E g[n - 1]]}, While[ f[k] < n, k++ ]; k]; Do[ Print[ g[ n]], {n, 2, 26}]; PrimePi[ g[ # ]] & /@ Range[2, 28]

Formula

a(n) = A000720(A107610(n)).

A272231 a(n) = round(n / pi(n)), where pi(n) is the prime-counting function.

Original entry on oeis.org

2, 2, 2, 2, 2, 2, 2, 2, 3, 2, 2, 2, 2, 3, 3, 2, 3, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 3, 4, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4
Offset: 2

Views

Author

Benjamin Przybocki, Apr 22 2016

Keywords

Comments

This sequence grows slowly; a(n) reaches 10 at n = 39017.

Crossrefs

Programs

Formula

a(n) = round(n / pi(n)).
a(n) ~ log(n). - Charles R Greathouse IV, Apr 30 2016
Showing 1-4 of 4 results.