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.

A047948 Smallest of three consecutive primes with a difference of 6: primes p such that p+6 and p+12 are the next two primes.

This page as a plain text file.
%I A047948 #43 Feb 28 2025 06:45:02
%S A047948 47,151,167,251,257,367,557,587,601,647,727,941,971,1097,1117,1181,
%T A047948 1217,1361,1741,1747,1901,2281,2411,2671,2897,2957,3301,3307,3631,
%U A047948 3727,4007,4451,4591,4651,4987,5101,5107,5297,5381,5387,5557,5801,6067,6257,6311,6317
%N A047948 Smallest of three consecutive primes with a difference of 6: primes p such that p+6 and p+12 are the next two primes.
%C A047948 Let p(k) be the k-th prime; sequence gives p(k) such that p(k+2) - p(k+1) = p(k+1) - p(k) = 6.
%H A047948 Amiram Eldar, <a href="/A047948/b047948.txt">Table of n, a(n) for n = 1..10000</a> (terms 1..1000 from T. D. Noe)
%e A047948 47 is a term as the next two primes are 53 and 59.
%t A047948 ok[p_] := (q = NextPrime[p]) == p+6 && NextPrime[q] == q+6; Select[Prime /@ Range[1000], ok][[;; 45]] (* _Jean-François Alcover_, Jul 11 2011 *)
%t A047948 Transpose[Select[Partition[Prime[Range[1000]],3,1],Differences[#]=={6,6}&]] [[1]] (* _Harvey P. Dale_, Apr 25 2014 *)
%o A047948 (PARI) is_A047948(n)={nextprime(n+1)==n+6 && nextprime(n+7)==n+12 && isprime(n)} \\ _Charles R Greathouse IV_, Aug 17 2011, simplified by _M. F. Hasler_, Jan 13 2013
%o A047948 (PARI) p=2;q=3;forprime(r=5,1e4,if(r-p==12&&q-p==6,print1(p", "));p=q;q=r) \\ _Charles R Greathouse IV_, Aug 17 2011
%Y A047948 Subsequence of A031924.
%Y A047948 A033451 (four consecutive primes with difference 6) is a subsequence.
%Y A047948 Cf. A078853, A046789.
%Y A047948 Cf. A001223, A033451, A052197, A052198.
%K A047948 easy,nonn
%O A047948 1,1
%A A047948 _Enoch Haga_
%E A047948 Corrected by _T. D. Noe_, Mar 07 2008