[go: up one dir, main page]

login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A174922
Lesser of twin primes p1 such that p1+(p2^2-p1^2) and p2+(p2^2-p1^2) are prime numbers.
5
5, 11, 29, 461, 599, 659, 809, 1019, 1289, 2027, 2141, 2309, 2339, 2801, 3329, 3557, 3581, 4127, 4421, 4547, 5879, 6761, 10091, 10457, 10709, 13829, 15329, 18911, 20231, 21839, 23561, 23909, 26249, 26879, 27581, 27689, 27917, 28109, 30491
OFFSET
1,1
COMMENTS
5+(7^2-5^2)=5+24=29; 7+(7^2-5^2)=7+24=31,..
LINKS
MATHEMATICA
lst={}; Do[p1=Prime[n]; p2=p1+2; If[PrimeQ[p2]&&PrimeQ[p1+(p2^2-p1^2)]&&PrimeQ[p2+(p2^2-p1^2)], AppendTo[lst, p1]], {n, 8!}]; lst
prQ[{a_, b_}]:=Module[{c=b^2-a^2}, AllTrue[{a+c, b+c}, PrimeQ]]; Transpose[ Select[ Select[ Partition[Prime[Range[5000]], 2, 1], #[[2]]-#[[1]] == 2&], prQ]][[1]] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Aug 12 2015 *)
KEYWORD
nonn
AUTHOR
STATUS
approved