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.

A145281 a(n) is the least prime such that (ceiling(sqrt(a(n)*p_n)))^2 - a(n)*p_n is a perfect square, where p_n is the n-th prime.

Original entry on oeis.org

2, 3, 3, 3, 5, 5, 11, 11, 13, 17, 19, 23, 29, 29, 31, 37, 41, 41, 47, 53, 53, 59, 61, 67, 73, 79, 79, 83, 83, 89, 101, 101, 107, 109, 127, 127, 127, 131, 137, 139, 149, 149, 157, 157, 163, 163, 173, 191, 191, 191, 193, 199, 211, 211, 223, 223, 227, 227, 233, 239
Offset: 1

Views

Author

Vladimir Shevelev, Oct 06 2008, Oct 07 2008

Keywords

Comments

Theorem. p_n - 2*sqrt(2p_n) + 2= A145236(n).
Or a(n) is the least prime q_n <= p_n such that sqrt(p_n) - sqrt(q_n) < sqrt(2) [or (p_n + q_n)/2 < sqrt(p_n*q_n) + 1]. See also our comment to A145300. - Vladimir Shevelev, Oct 09 2008
The above conjecture is true. This means that a(n) is the nearest prime p > p_n - 2*floor(sqrt(2*p_n)) + 2. A considerably more important and deep question is whether p < p_n. The answer does not follow even from the Riemann conjecture about zeros of the zeta function. - Vladimir Shevelev, Oct 17 2008

Crossrefs

Programs

  • PARI
    a(n) = {my(p = prime(n)); my(q = 2); while (! issquare(ceil(sqrt(q*p))^2 - q*p), q = nextprime(q+1)); q;} \\ Michel Marcus, Jul 06 2015

Extensions

More terms from Michel Marcus, Jul 06 2015