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.

Showing 1-2 of 2 results.

A339625 a(n) is the number of ways to write 6*n = p + q with p a lesser twin prime (A001359) and q a greater twin prime (A006512).

Original entry on oeis.org

0, 1, 2, 3, 2, 3, 2, 4, 2, 3, 2, 4, 4, 3, 4, 0, 4, 2, 6, 5, 2, 4, 2, 5, 4, 4, 4, 6, 2, 6, 2, 4, 6, 5, 12, 3, 6, 2, 4, 8, 6, 8, 8, 2, 6, 3, 6, 10, 4, 13, 2, 6, 4, 4, 10, 4, 10, 4, 6, 3, 4, 6, 10, 5, 8, 1, 0, 6, 2, 12, 4, 6, 6, 2, 10, 3, 10, 6, 6, 7, 2, 8, 4, 6, 6, 0, 6, 6, 6, 9, 2, 6, 2, 5, 6, 4
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Dec 10 2020

Keywords

Comments

If 6*n = p + q, then also 6*n = (p+2) + (q-2), with p+2 a greater and q-2 a lesser twin prime. Thus a(n) is odd if and only if n/2 is in A002822.

Examples

			a(4)=3 because 6*4 = 24 = 5 + 19 = 11 + 13 = 17 + 7 where (5,7), (11,13) and (17,19) are twin prime pairs.
		

Crossrefs

a(n)=0 for n in A243956.

Programs

  • Maple
    N:= 600: # for a(1)..a(floor(N/6)))
    P:= select(isprime, {seq(i,i=3..N,2)}):
    T1:= sort(convert(P intersect map(`-`,P,2),list)):
    T2:= map(`+`,T1,2):
    V:= Vector(N):
    nT:= nops(T1):
    for i from 1 to nT do
      for j from 1 to nT do
        v:= T1[i]+T2[j];
        if v > N then break fi;
        V[v]:= V[v]+1;
    od od:
    seq(V[6*i],i=1..N/6);

A235644 Number of decompositions of 12*n into the sum of two (not necessarily distinct) twin prime pairs.

Original entry on oeis.org

0, 1, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 2, 2, 2, 0, 2, 1, 3, 3, 1, 2, 1, 3, 2, 2, 2, 3, 1, 3, 1, 2, 3, 3, 6, 2, 3, 1, 2, 4, 3, 4, 4, 1, 3, 2, 3, 5, 2, 7, 1, 3, 2, 2, 5, 2, 5, 2, 3, 2, 2, 3, 5, 3, 4, 1, 0, 3, 1, 6, 2, 3, 3, 1, 5, 2, 5, 3, 3, 4, 1, 4
Offset: 1

Views

Author

Lear Young, Jun 16 2014

Keywords

Comments

In the 1980's, Liang conjectured that (6n)^2 = p_1 + p_2 + p_3 + p_4, where (p_1, p_2) and (p_3, p_4) are twin prime pairs. See reference for more details.
It seems there are at least 2 solutions for the decompositions when n > 701.
If the two twin prime pairs are required to be distinct, the sequence is A187759.

Examples

			a(736) = 2 because 12*736 = 197 + 199 + 4217 + 4219 = 857 + 859 + 3557 + 3559, so there are 2 ways of expressing 12*n as the sum of two twin prime pairs.
		

References

  • Liang Ding Xiang, Problem 93#, Bulletin of Mathematics (Wuhan), 6(1992),41. ISSN 0488-7395.

Crossrefs

Programs

  • PARI
    v=select(p->isprime(p-2)&&p>5, primes(200))\6; l=List(); for(i=1, #v, if(2*v[i]<100, listput(l, 2*v[i])); for(j=i+1, #v, if((v[i]+v[j])<100, listput(l, v[i]+v[j])))); l1=vecsort(l); k=1; for(i=1, 100, s=sum(j=k, #l1, l1[j]==i); print1(s", "); k+=s) \\ Lear Young, Jun 16 2014
    
  • PARI
    v=select(p->isprime(p-2)&&p>5,primes(110))\6;for(i=1, 99, print1(sum(j=1,#v,vecsearch(v,i-v[j])>0 && i-v[j]>=v[j])", "))   \\ change i-v[j]>=v[j] to i-v[j]>v[j] is A187759.  Lear Young, Jun 16 2014
Showing 1-2 of 2 results.