cp's OEIS Frontend

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.

A173037 Numbers k such that k-4, k-2, k+2 and k+4 are prime.

This page as a plain text file.
%I A173037 #52 Nov 10 2023 09:38:21
%S A173037 9,15,105,195,825,1485,1875,2085,3255,3465,5655,9435,13005,15645,
%T A173037 15735,16065,18045,18915,19425,21015,22275,25305,31725,34845,43785,
%U A173037 51345,55335,62985,67215,69495,72225,77265,79695,81045,82725,88815,97845
%N A173037 Numbers k such that k-4, k-2, k+2 and k+4 are prime.
%C A173037 Average k of the four primes in two twin prime pairs (k-4, k-2) and (k+2, k+4) which are linked by the cousin prime pair (k-2, k+2).
%C A173037 All terms are odd composites; except for a(1) they are multiples of 5.
%C A173037 Subsequence of A087679, of A087680 and of A164385.
%C A173037 All terms except for a(1) are multiples of 15. - _Zak Seidov_, May 18 2014
%C A173037 One of (k-1, k, k+1) is always divisible by 7. - _Fred Daniel Kline_, Sep 24 2015
%C A173037 Terms other than a(1) must be equivalent to 1 mod 2, 0 mod 3, 0 mod 5, and 0,+/-1 mod 7. Taken together, this requires terms other than a(1) to have the form 210k+/-15 or 210k+105. However, not all numbers of that form belong to this sequence. - _Keith Backman_, Nov 09 2023
%H A173037 Klaus Brockhaus, <a href="/A173037/b173037.txt">Table of n, a(n) for n = 1..28388</a> (terms < 10^9).
%F A173037 For n >= 2, a(n) = 15*A112540(n-1). - _Michel Marcus_, May 19 2014
%F A173037 From _Jeppe Stig Nielsen_, Feb 18 2020: (Start)
%F A173037 For n >= 2, a(n) = 30*A014561(n-1) + 15.
%F A173037 For n >= 2, a(n) = 10*A007811(n-1) + 5.
%F A173037 a(n) = A007530(n) + 4.
%F A173037 a(n) = A125855(n) + 5. (End)
%e A173037 9 is a term because 9-4 = 5 is prime, 9-2 = 7 is prime, 9+2 = 11 is prime and 9+4 = 13 is prime.
%t A173037 Select[Range[100000],AllTrue[#+{4,2,-2,-4},PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* _Harvey P. Dale_, Jul 30 2015 *)
%o A173037 (Magma) [ p+4: p in PrimesUpTo(100000) | IsPrime(p) and IsPrime(p+2) and IsPrime(p+6) and IsPrime(p+8) ]; // _Klaus Brockhaus_, Feb 09 2010
%o A173037 (PARI) is(n)=isprime(n-4) && isprime(n-2) && isprime(n+2) && isprime(n+4) \\ _Charles R Greathouse IV_, Sep 24 2015
%o A173037 (Python)
%o A173037 from sympy import primerange
%o A173037 def aupto(limit):
%o A173037     p, q, r, alst = 2, 3, 5, []
%o A173037     for s in primerange(7, limit+5):
%o A173037         if p+2 == q and p+6 == r and p+8 == s: alst.append(p+4)
%o A173037         p, q, r = q, r, s
%o A173037     return alst
%o A173037 print(aupto(10**5)) # _Michael S. Branicky_, Feb 03 2022
%Y A173037 Cf. A001359, A006512, A007530, A007811, A014561, A023200, A038800, A046132, A087680, A112540, A125855, A164385.
%K A173037 nonn
%O A173037 1,1
%A A173037 _Juri-Stepan Gerasimov_, Feb 07 2010
%E A173037 Edited and extended beyond a(9) by _Klaus Brockhaus_, Feb 09 2010