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.

A336300 Primes p such that there exists k with p < k < q such that p+k and q+k are prime, where q is the next prime after p.

This page as a plain text file.
%I A336300 #24 Oct 25 2020 00:01:57
%S A336300 5,23,29,31,47,53,73,83,113,131,139,151,173,199,211,251,293,317,359,
%T A336300 373,467,491,509,523,541,557,593,607,647,659,683,709,719,761,773,797,
%U A336300 809,811,863,911,991,997,1063,1069,1103,1117,1163,1171,1187,1201,1231,1259,1307,1327,1409,1439,1459,1499
%N A336300 Primes p such that there exists k with p < k < q such that p+k and q+k are prime, where q is the next prime after p.
%C A336300 There may be more than one such k: thus for a(17) = 293, k = 294, 300, and 306 all work.
%H A336300 Robert Israel, <a href="/A336300/b336300.txt">Table of n, a(n) for n = 1..10000</a>
%e A336300 a(4)=31 is included because 31 is prime, the next prime after 31 is 37, and with k=36 we have 31+36=67 and 37+36=73 both prime.
%p A336300 P:= [seq(ithprime(i),i=2..1000)]:
%p A336300 R:= NULL:
%p A336300 for i from 1 to nops(P)-1 do
%p A336300   for k from ceil(P[i]/2) to floor(P[i+1]/2) do
%p A336300     if isprime(P[i]+2*k) and isprime(P[i+1]+2*k) then
%p A336300       R:= R, P[i]; break
%p A336300     fi
%p A336300   od;
%p A336300 od:
%p A336300 R;
%Y A336300 Includes A069142.
%K A336300 nonn
%O A336300 1,1
%A A336300 _J. M. Bergot_ and _Robert Israel_, Oct 22 2020