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!)
A144517 Primes p=prime(k) such that p - nonprime(k) is nonprime and p + nonprime(k) is prime, where prime(n) is the n-th prime and nonprime(n) is the n-th nonprime starting with nonprime(1) = 0. 2
7, 23, 31, 41, 101, 109, 227, 241, 311, 347, 389, 587, 701, 757, 859, 947, 977, 1063, 1069, 1123, 1181, 1229, 1237, 1289, 1303, 1327, 1451, 1489, 1543, 1559, 1613, 1669, 1733, 1787, 1879, 2011, 2029, 2039, 2203, 2213, 2281, 2357, 2393, 2459, 2503, 2593 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
EXAMPLE
7(4) - 6(4) = 1 (nonprime) and 7(4) + 6(4) = 13 (prime), so 7 is in the sequence.
31(11) - 16(11) = 15 (nonprime) and 31(11) + 16(11) = 47 (prime), so 31 is in the sequence.
41(13) - 20(13) = 21 (nonprime) and 41(13) + 20(13) = 61 (prime), so 41 is in the sequence.
101(26) - 36(20) = 65 (nonprime) and 101(26) + 36(26) = 137 (prime), so 101 is in the sequence.
109(29) - 40(29) = 69 (nonprime) and 109(29) + 40(29) = 149 (prime), so 109 is in the sequence.
MAPLE
A141468 := proc(n) option remember; local a; if n = 1 then 0; else for a from procname(n-1)+1 do if not isprime(a) then return a; end if; od: end if; end proc: A144517 := proc(n) option remember; local p, i; if n = 1 then 7; else p := nextprime(procname(n-1)) ; while true do i := numtheory[pi](p) ; if not isprime(p-A141468(i)) and isprime(p+A141468(i)) then return p; fi; p := nextprime(p) ; end do: end if; end: seq(A144517(n), n=1..80) ; # R. J. Mathar, Oct 22 2009
MATHEMATICA
Module[{pr=Prime[Range[1000]], npr, len}, npr=Complement[Range[0, Last[pr]], pr]; len=Min[Length[pr], Length[npr]]; Transpose[Select[Thread[ {Take[pr, len], Take[npr, len]}], !PrimeQ[First[#]-Last[#]]&&PrimeQ[Total[#]]&]][[1]]] (* Harvey P. Dale, Aug 24 2012 *)
CROSSREFS
Sequence in context: A225822 A044449 A095087 * A225185 A091531 A036259
KEYWORD
nonn
AUTHOR
EXTENSIONS
Roughly 20 percent of the entries corrected by R. J. Mathar, Oct 22 2009
Better definition from Michel Marcus, Aug 07 2017
STATUS
approved

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 11:19 EDT 2024. Contains 371910 sequences. (Running on oeis4.)