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

A144832 Distance from nxtprm(n^2) to (n+1)^2 in A144831 is prime.

Original entry on oeis.org

2, 5, 7, 11, 17, 17, 23, 29, 31, 41, 47, 67, 71, 71, 89, 89, 97, 113, 109, 107, 127, 131, 137, 157, 167, 173, 173, 191, 197, 193, 197, 227, 233, 227, 251, 257, 271, 293, 271, 307, 313, 317, 331, 349, 353, 383, 383, 409, 419, 431, 449, 463, 467, 487, 503, 509
Offset: 1

Views

Author

Enoch Haga, Sep 22 2008

Keywords

Examples

			a(2)=5 because 3^2=9 and 4^2=16. Nxtprm(3^2)=11 and 16-11=5, a prime.
		

Crossrefs

Formula

Terms in this sequence are from A144831 iff the distance from nxtprm n^2 to (n+1)^2 is prime.

A007491 Smallest prime > n^2.

Original entry on oeis.org

2, 5, 11, 17, 29, 37, 53, 67, 83, 101, 127, 149, 173, 197, 227, 257, 293, 331, 367, 401, 443, 487, 541, 577, 631, 677, 733, 787, 853, 907, 967, 1031, 1091, 1163, 1229, 1297, 1373, 1447, 1523, 1601, 1693, 1777, 1861, 1949, 2027, 2129, 2213, 2309, 2411, 2503
Offset: 1

Views

Author

Keywords

Comments

Suggested by Legendre's conjecture (still open) that there is always a prime between n^2 and (n+1)^2.
Legendre's conjecture is equivalent to a(n) < (n+1)^2. - Jean-Christophe Hervé, Oct 26 2013
From Jaroslav Krizek, Apr 02 2016: (Start)
Conjectures:
1) There is always a prime p between n^2 and n^2+n (verified up to 13*10^6).
2) a(n) is the smallest prime p such that n^2 < p < n^2+n; a(n) < n^2+n.
3) For all numbers k >= 1 there is the smallest number m > 2*(k+1) such that for all numbers n >= m there is always a prime p between n^2 and n^2 + n - 2k. Sequence of numbers m for k >= 1: 6, 8, 12, 13, 14, 24, 24, 24, 30, 30, 30, 31, 33, 35, 43, ...; lim_{k->oo} m/2k = 1. Example: k=2; for all numbers n >= 8 there is always a prime p between n^2 and n^2 + n - 4. (End)

References

  • Archimedeans Problems Drive, Eureka, 24 (1961), 20.
  • J. R. Goldman, The Queen of Mathematics, 1998, p. 82.
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers. 3rd ed., Oxford Univ. Press, 1954, p. 19.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Haskell
    a007491 = a007918 . a000290  -- Reinhard Zumkeller, Jun 07 2015
    
  • Magma
    [NextPrime(n^2): n in [1..50]]; // Vincenzo Librandi, Apr 30 2015
    
  • Maple
    [seq(nextprime(i^2), i=1..100)];
  • Mathematica
    NextPrime[Range[60]^2]  (* Harvey P. Dale, Mar 24 2011 *)
  • PARI
    vector(100,i,nextprime(i^2))
    
  • Python
    from sympy import nextprime
    def a(n): return nextprime(n**2)
    print([a(n) for n in range(1, 51)]) # Michael S. Branicky, Jan 13 2023

Formula

a(n) = A007918(A000290(n)). - Reinhard Zumkeller, Jun 07 2015

Extensions

More terms from Labos Elemer, Nov 17 2000
Definition modified by Jean-Christophe Hervé, Oct 26 2013

A144256 a(n) = smallest prime in the range [n^K, (n+1)^K], where K = log(127)/log(16) = 1.74717117169304146332...

Original entry on oeis.org

2, 5, 7, 13, 17, 23, 31, 41, 47, 59, 67, 79, 89, 101, 127, 127, 149, 157, 173, 191, 211, 223, 241, 263, 277, 307, 317, 347, 359, 383, 409, 431, 457, 479, 499, 541, 557, 577, 607, 631, 659, 691, 719, 751, 787, 809, 839, 877, 907, 937, 967, 997, 1031, 1069
Offset: 1

Views

Author

Keywords

Comments

T. D. Noe submitted to primepuzzles.net the following conjecture #60, which is stronger than the Legendre's conjecture: For n>0 and k>=K, there is always a prime between n^k and (n+1)^k, where K = log(127)/log(16) = 1.74717117169304146332...
One could see that calculated terms for n=15 and n=16 yield the same value: 127, which make this conjecture (as originally defined) to be questionable. If this conjecture is modified to k>K, then there will be a distinct prime between 15^k and 16^k. It appears that the relatively large prime gap between 113 and 127 is the largest gap to overcome. Another way to correct/clarify the conjecture is to mention that both boundaries of the interval are included and that the same prime value may appear in two neighboring intervals. Of course the last version of the modified definition makes this conjecture to be different from the original Legendere conjecture (rather than to be an improvement of the original Legendere conjecture). [Alexander R. Povolotsky, Sep 26 2008]
The constant log(127)/log(16) is A194361. - John W. Nicholson, Dec 13 2013

Crossrefs

Programs

  • Mathematica
    k = Log[127]/Log[16]; Table[Select[Range[Ceiling[n^k], Floor[(n + 1)^k]], PrimeQ, 1][[1]], {n, 100}] (* T. D. Noe, Jan 30 2012 *)
  • PARI
    i=[];for(n=1, 500, for(j=ceil(n^(log(127)/log(16))), ceil((n+1)^(log(127)/log(16))), if(isprime(j), i=concat(i,j)); if(isprime(j), break)));i

Extensions

Extended by T. D. Noe, Jan 30 2012
Showing 1-3 of 3 results.