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.

A077510 Numbers k such that k + pi(k) is a prime.

Original entry on oeis.org

2, 3, 7, 9, 12, 13, 21, 28, 32, 36, 45, 52, 55, 57, 61, 65, 70, 76, 79, 81, 84, 86, 89, 101, 104, 110, 119, 121, 131, 135, 139, 145, 147, 155, 160, 162, 172, 181, 185, 187, 195, 205, 216, 222, 223, 228, 231, 253, 258, 262, 273, 278, 286, 288, 292, 297, 305, 310
Offset: 1

Views

Author

Amarnath Murthy, Nov 08 2002

Keywords

Comments

Conjecture: for k > 5, prime(n) <= k < prime(n+1) <= k + pi(k), i.e., the smallest prime greater than k is <= k + pi(k). Equality holds for k = 7.

Examples

			21 is a member as 21 + pi(21) = 21 + 8 = 29 is a prime.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[350],PrimeQ[#+PrimePi[#]]&] (* Harvey P. Dale, Nov 19 2011 *)
  • PARI
    for(n=1,200,if(isprime(n+primepi(n)),print1(n,", "))) \\ Derek Orr, Jun 22 2015
    
  • PARI
    pi=0; p=2; forprime(q=3,1e3, pi++; for(n=p,q-1, if(isprime(n+pi), print1(n", "))); p=q) \\ Charles R Greathouse IV, Jun 23 2015

Extensions

More terms from David Garber, Nov 10 2002