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!)
A216944 The least odd prime p for which the n-th prime can be written as 3p + q - 3 for some odd prime q. 1

%I #17 Mar 08 2018 21:14:18

%S 3,3,3,3,3,3,5,3,5,3,3,3,3,7,3,5,3,3,5,3,7,5,3,3,3,3,7,7,3,5,5,5,3,3,

%T 7,3,3,7,5,5,3,3,5,5,11,3,3,3,5,5,3,3,3,11,3,5,3,5,11,7,3,3,7,3,11,5,

%U 3,3,7,3,3,11,3,7,5,5,7,5,5,5,3,5,3,7,5,3,3

%N The least odd prime p for which the n-th prime can be written as 3p + q - 3 for some odd prime q.

%C Conjecture: Any prime >= 11 can be written this way.

%H Robert Israel, <a href="/A216944/b216944.txt">Table of n, a(n) for n = 5..10000</a>

%e The corresponding q and prime(n): (5,11), (7,13), (11,17), (13,19), (17,23), (23,29), (19,31), (31,37), (29,41), (37,43), (41,47), (47,53), (53,59), (43,61), (61,67), (67,73), (73,79), (71,83), (83,89), (79,97), (89,101), (97,103), (101,107), (103,109), (107,113), (109,127), (113,131), (131,137), (127,139), (137,149), (139,151), (151,157), (157,163), (149,167), (167,173), (173,179), (163,181), (179,191), (181,193), (191,197), (193,199), (199,211), (211,223), (197,227), (223,229), (227,233), (233,239), (229,241), (239,251), (251,257), (257,263), (263,269), (241,271), (271,277), (269,281), (277,283), (281,293), (277,307), (293,311), (307,313), (311,317), (313,331), (331,337), (317,347), (337,349), (347,353), (353,359), (349,367), (367,373), (373,379), (353,383), (383,389), (379,397), (389,401), (397,409), (401,419), (409,421), (419,431), (421,433), (433,439), (431,443), (443,449), (439,457), (449,461), (457,463), (461,467), (467,479).

%p f:= proc(n) local p,q;

%p p:= 2;

%p while 3*p<n+3 do

%p p:= nextprime(p);

%p if isprime(n-3*p+3) then return p fi;

%p od;

%p FAIL

%p end proc:

%p p:= 7: Res:= NULL:

%p for i from 1 to 100 do

%p p:= nextprime(p); Res:= Res, f(p);

%p od:

%p Res; # _Robert Israel_, Mar 08 2018

%o (PARI) a(n)=my(r=prime(n)+3); forprime(p=3,r\3-1,if(isprime(r-3*p), return(p))) \\ _Charles R Greathouse IV_, Dec 07 2014

%K nonn

%O 5,1

%A _Marius Coman_, Sep 20 2012

%E New name from _Charles R Greathouse IV_, Dec 07 2014

%E Corrected by _Charles R Greathouse IV_, Dec 07 2014

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