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.

A158870 Sums of the form (twin primes + 1) which are also an upper twin prime.

This page as a plain text file.
%I A158870 #12 Mar 01 2019 01:48:05
%S A158870 13,61,1321,1621,4261,5101,6661,6781,11701,12541,21061,66361,83221,
%T A158870 88261,107101,110881,114661,127681,130201,140761,141961,144541,148201,
%U A158870 149521,157561,161341,163861,175081,186481,204601,230941,249541,267961
%N A158870 Sums of the form (twin primes + 1) which are also an upper twin prime.
%C A158870 If the sum is a member of a twin prime pair, it always is the upper member, shown in A158866.
%C A158870 Moreover, except the first term, these numbers are of the form 10k+1. [We prove this by exhausting the possibilities when calculating the upper, summing and inspecting the lower of the sum. Here are the possible outcomes.
%C A158870 p1(k), p2(k)  p2(m) = p1(k)+p2(k)+1
%C A158870 ------------  ---------------------------------
%C A158870 10k+1 10k+3   20k+4+1 not prime
%C A158870 10k+3 10k+5   p2(k) not prime
%C A158870 10k+5 10k+7   p1(k) not prime
%C A158870 10k+7 10k+9   20k+16+1 upper => p1(m) not prime
%C A158870 10k+9 10k+11  20k+20+1 = 10(2k+2)+1
%C A158870 So the only form that was not eliminated, is 10k+1. 13 defies this scheme because 10k+5 is prime for k=0, Q.E.D.]
%H A158870 Harvey P. Dale, <a href="/A158870/b158870.txt">Table of n, a(n) for n = 1..1000</a>
%F A158870 {A054735(k)+1: A054735(k)+1 = A006512(j), any j,k} - _R. J. Mathar_, Apr 06 2009
%e A158870 The 30th lower twin prime is 659. 659+661+1 = 1321, prime and 1319 is too.
%e A158870 Then 1319 is the lower member of the twin prime pair (1319,1321). So 1321 is in the sequence.
%t A158870 With[{tws=Total/@Select[Partition[Prime[Range[25000]],2,1],#[[2]]-#[[1]] == 2&]+1},Select[tws,And@@PrimeQ[#+{0,-2}]&]] (* _Harvey P. Dale_, Apr 30 2014 *)
%o A158870 (PARI) gp > g(n)=for(x=1,n,y=2*twinl(x)+3;if(isprime(y)&&isprime(y-2), print1(y",")))
%Y A158870 Cf. A158866.
%K A158870 nonn
%O A158870 1,1
%A A158870 _Cino Hilliard_, Mar 28 2009
%E A158870 Edited by _R. J. Mathar_, Apr 06 2009