OFFSET
1,1
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
EXAMPLE
6 is a term because it is the 2nd composite number, 6=2*3, and 2+3=5 is prime;
10 is a term because it is the 5th composite number, 10=2*5, and 2+5=7 is prime;
22 is a term because it is the 13th composite number, 22=2*11, and 2+11=13 is prime;
44 is a term because it is the 29th composite number, 44=2*2*11, and 2+11=13 is prime.
MAPLE
A020639 := proc(n) numtheory[factorset](n) ; min(op(%)) ; end proc:
A006530 := proc(n) numtheory[factorset](n) ; max(op(%)) ; end proc:
A002808 := proc(n) if n = 1 then 4; else for a from procname(n-1)+1 do if not isprime(a) then return a; end if; end do: end if; end proc:
A145351 := proc(n) c := A065858(n) ; if isprime(A020639(c) + A006530(c)) then printf("%d, ", c) ; end if; end proc:
seq(A145351(n), n=1..400) ; # R. J. Mathar, May 01 2010
MATHEMATICA
pfiQ[n_]:=Module[{f=FactorInteger[n]}, PrimeQ[f[[1, 1]]+f[[-1, 1]]]]; Module[ {nn=2000, c}, c=Select[ Range[nn], CompositeQ]; Select[ Table[ Take[c, {n}][[1]], {n, Prime[Range[PrimePi[Length[c]]]]}], pfiQ]] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, May 18 2019 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Juri-Stepan Gerasimov, Jan 04 2009
EXTENSIONS
Corrected (inserted 20 from n=5, 30 from n=8, removed 200) and extended beyond 204 by R. J. Mathar, May 01 2010
Edited by Jon E. Schoenfield, Feb 07 2019
STATUS
approved