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.

A164130 Sums s of squares of three consecutive primes, such that s-+2 are primes.

This page as a plain text file.
%I A164130 #11 Apr 21 2023 05:11:09
%S A164130 195,5739,18459,32259,33939,60291,74019,169491,187131,244899,276819,
%T A164130 388179,783531,902139,3588339,5041491,5145819,5193051,8687091,9637491,
%U A164130 10227291,10910019,11341491,11757339,14834379,15354651,16115091
%N A164130 Sums s of squares of three consecutive primes, such that s-+2 are primes.
%H A164130 Robert Israel, <a href="/A164130/b164130.txt">Table of n, a(n) for n = 1..10000</a>
%F A164130 A133529 INTERSECT A087679. - _R. J. Mathar_, Aug 27 2009
%e A164130 5^2 + 7^2 + 11^2 = 195 is a sum of the squared consecutive primes 5, 7 and 11, and 193 and 197 are primes, so 195 is a member of the sequence.
%p A164130 q:= 2: r:= 3: R:= NULL: count:= 0:
%p A164130 while count < 100 do
%p A164130   p:= q; q:= r; r:= nextprime(r);
%p A164130   s:= p^2+q^2+r^2;
%p A164130   if isprime(s-2) and isprime(s+2) then
%p A164130     count:= count+1; R:= R,s;
%p A164130   fi;
%p A164130 od:
%p A164130 R; # _Robert Israel_, Apr 21 2023
%t A164130 lst={};Do[p=Prime[n]^2+Prime[n+1]^2+Prime[n+2]^2;If[PrimeQ[p-2]&&PrimeQ[p+2], AppendTo[lst,p]],{n,8!}];lst
%Y A164130 Cf. A075893, A133529, A133530, A034962, A164129
%K A164130 nonn
%O A164130 1,1
%A A164130 _Vladimir Joseph Stephan Orlovsky_, Aug 10 2009
%E A164130 Comment turned into example by _R. J. Mathar_, Aug 27 2009