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.

A320702 Indices of primes followed by a gap (distance to next larger prime) of 8.

This page as a plain text file.
%I A320702 #17 Sep 08 2022 08:46:23
%S A320702 24,72,77,79,87,92,94,124,126,128,132,135,156,158,166,186,192,196,220,
%T A320702 228,241,246,248,270,281,299,304,325,330,334,338,364,370,379,386,393,
%U A320702 400,413,417,421,432,436,454,456,482,488,507,517,519,538,589,594,620,640,661,676,689,691,712,736,750,759
%N A320702 Indices of primes followed by a gap (distance to next larger prime) of 8.
%C A320702 Indices of the primes given in A031926.
%H A320702 Vincenzo Librandi, <a href="/A320702/b320702.txt">Table of n, a(n) for n = 1..10340</a>
%H A320702 <a href="/index/Pri#gaps">Index entries for primes, gaps between</a>
%F A320702 a(n) = A000720(A031926(n)) = A174349(4,n).
%F A320702 A320702 = { i > 0 | prime(i+1) = prime(i) + 8 } = A001223^(-1)({8}).
%p A320702 p:= 2: Res:= NULL: count:= 0:
%p A320702 for n from 1 while count < 100 do
%p A320702   q:= nextprime(p);
%p A320702   if q-p = 8 then count:= count+1; Res:= Res, n; fi;
%p A320702   p:= q;
%p A320702 od:
%p A320702 Res; # _Robert Israel_, Oct 19 2018
%t A320702 Select[Range[800], Prime[#] + 8 == Prime[# + 1] &] (* _Vincenzo Librandi_, Mar 21 2019 *)
%o A320702 (PARI) A_vec(N=100,g=8,p=2,i=primepi(p)-1,L=List())={forprime(q=1+p,,i++; if(p+g==p=q, listput(L,i); N--||break));Vec(L)}
%o A320702 (Magma) [n: n in [1..800] | NthPrime(n+1) - NthPrime(n) eq 8]; // _Vincenzo Librandi_, Mar 21 2019
%Y A320702 Equals A000720 o A031926.
%Y A320702 Row 4 of A174349.
%Y A320702 Indices of 8's in A001223.
%Y A320702 Cf. A029707, A029709, A320701, A320703, ..., A320720 (analog for gaps 2, 4, 6, 10, ..., 44), A116493 (gap 70), A116496 (gap 100), A116497 (gap 200), A116495 (gap 210).
%K A320702 nonn
%O A320702 1,1
%A A320702 _M. F. Hasler_, Oct 19 2018