This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A224789 #9 Jul 04 2017 10:39:29 %S A224789 5,7,13,19,67,229,269,307,313,401,439,613,643,863,1051,1693,1783,1999, %T A224789 2143,2239,2309,2423,2549,2753,2819,3037,3079,3089,3361,3373,3389, %U A224789 3677,3863,3877,4139,4259,4519,4663,4909,4933,5323,5527,5581,5849,6359,6577 %N A224789 Primes p such that both p + nextprime(p) + 1 and p*nextprime(p) + 2 are primes. %C A224789 Intersection of A051507 and A177017. %H A224789 Harvey P. Dale, <a href="/A224789/b224789.txt">Table of n, a(n) for n = 1..1000</a> %e A224789 5 is a member since 5 + 7 + 1 = 13 and 5 * 7 + 2 = 37 are both primes. %t A224789 Select[Prime[Range[900]], PrimeQ[# + NextPrime[#] + 1] && PrimeQ[#*NextPrime[#] + 2] &] %t A224789 npQ[n_]:=Module[{np=NextPrime[n]},AllTrue[{n+np+1,n*np+2},PrimeQ]]; Select[ Prime[ Range[900]],npQ] (* The program uses the AllTrue function from Mathematica version 10 *) (* _Harvey P. Dale_, Jul 04 2017 *) %Y A224789 Cf. A051507, A177017. %K A224789 nonn %O A224789 1,1 %A A224789 _Jayanta Basu_, Apr 17 2013