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!)
A193598 Even numbers k such that r(k) < r(k/2), where r(n) is the distance from n to the nearest prime. 1

%I #11 May 13 2013 01:54:20

%S 2,18,30,42,52,54,66,68,70,78,90,98,100,102,110,112,114,126,128,130,

%T 138,150,152,162,172,174,182,190,198,210,222,230,232,234,236,238,240,

%U 242,244,250,258,268,270,282,284,286,290,292,294,306,308

%N Even numbers k such that r(k) < r(k/2), where r(n) is the distance from n to the nearest prime.

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

%e 18 is in the sequence, since r(18) = 1 < 2 = r(9); 22 is not in the sequence, since r(22) = 1 >= 0 = r(11).

%o (PARI) r(n)=min(nextprime(n)-n,n-precprime(n))

%o forstep(k=2,1e3,2,if(r(k)<r(k/2),print1(k", "))) \\ _Charles R Greathouse IV_, Jul 31 2011

%Y r(n) is A051699.

%K nonn

%O 1,1

%A _Vladimir Shevelev_, Jul 31 2011

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 18 22:18 EDT 2024. Contains 371782 sequences. (Running on oeis4.)