login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A077510 Numbers n such that n + pi(n) is a prime. 5

%I #13 Mar 04 2024 11:02:06

%S 2,3,7,9,12,13,21,28,32,36,45,52,55,57,61,65,70,76,79,81,84,86,89,101,

%T 104,110,119,121,131,135,139,145,147,155,160,162,172,181,185,187,195,

%U 205,216,222,223,228,231,253,258,262,273,278,286,288,292,297,305,310

%N Numbers n such that n + pi(n) is a prime.

%C 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.

%H Charles R Greathouse IV, <a href="/A077510/b077510.txt">Table of n, a(n) for n = 1..10000</a>

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

%t Select[Range[350],PrimeQ[#+PrimePi[#]]&] (* _Harvey P. Dale_, Nov 19 2011 *)

%o (PARI) for(n=1,200,if(isprime(n+primepi(n)),print1(n,", "))) \\ _Derek Orr_, Jun 22 2015

%o (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

%Y Cf. A000040, A000720, A061067, A076757.

%K nonn

%O 1,1

%A _Amarnath Murthy_, Nov 08 2002

%E More terms from _David Garber_, Nov 10 2002

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 13:51 EDT 2024. Contains 371914 sequences. (Running on oeis4.)