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-4 of 4 results.

A230252 Number of ways to write n = x + y (x, y > 0) with 2*x + 1, x^2 + x + 1 and y^2 + y + 1 all prime.

Original entry on oeis.org

0, 1, 2, 3, 2, 3, 4, 4, 4, 3, 4, 1, 3, 3, 3, 5, 5, 4, 3, 6, 4, 7, 7, 2, 4, 6, 4, 4, 6, 3, 1, 4, 2, 4, 7, 4, 1, 4, 4, 2, 6, 4, 3, 4, 2, 3, 5, 3, 2, 1, 2, 3, 6, 2, 6, 6, 3, 5, 4, 5, 3, 7, 2, 4, 6, 2, 4, 5, 3, 5, 8, 5, 2, 10, 4, 4, 8, 5, 6, 7, 8, 4, 11, 4, 3, 6, 4, 2, 4, 8, 8, 11, 5, 3, 11, 5, 3, 6, 4, 5
Offset: 1

Views

Author

Zhi-Wei Sun, Oct 13 2013

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 1.
(ii) Any integer n > 3 can be written as p + q with p, 2*p - 3 and q^2 + q + 1 all prime. Also, each integer n > 3 not equal to 30 can be expressed as p + q with p, q^2 + q - 1 and q^2 + q + 1 all prime.
(iii) Any integer n > 1 can be written as x + y (x, y > 0) with x^2 + 1 (or 4*x^2+1) and y^2 + y + 1 (or 4*y^2 + 1) both prime.
(iv) Each integer n > 3 can be expressed as p + q (q > 0) with p, 2*p - 3 and 4*q^2 + 1 all prime.
(v) Any even number greater than 4 can be written as p + q with p, q and p^2 + 4 (or p^2 - 2) all prime. Also, each even number greater than 2 and not equal to 122 can be expressed as p + q with p, q and (p-1)^2 + 1 all prime.
We have verified the first part for n up to 10^8.

Examples

			a(5) = 2 since 5 = 2 + 3 = 3 + 2, and 2*2+1 = 5, 2*3+1 = 7, 2^2+2+1 = 7, 3^2+3+1 = 13 are all prime.
a(31) = 1 since 31 = 14 + 17, and 2*14+1 = 29, 14^2+14+1 = 211 and 17^2+17+1 = 307 are all prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Sum[If[PrimeQ[2i+1]&&PrimeQ[i^2+i+1]&&PrimeQ[(n-i)^2+n-i+1],1,0],{i,1,n-1}]
    Table[a[n],{n,1,100}]

A230241 Number of ways to write n = p + q with p, 3*p - 10 and (p-1)*q - 1 all prime, where q is a positive integer.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Oct 13 2013

Keywords

Comments

Conjecture: a(n) > 0 for all n > 5.
This implies A. Murthy's conjecture mentioned in A109909.
We have verified the conjecture for n up to 10^8.
Conjecture verified for n up to 10^9. - Mauro Fiorentini, Jul 29 2023

Examples

			a(9) = 1 since 9 = 7 + 2 with 7, 3*7-10 = 11, (7-1)*2-1 = 11 all prime.
a(27) = 1 since 27 = 13 + 14, and the three numbers 13, 3*13-10 = 29, (13-1)*14-1 = 167 are prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Sum[If[PrimeQ[3Prime[i]-10]&&PrimeQ[(Prime[i]-1)(n-Prime[i])-1],1,0],{i,1,PrimePi[n-1]}]
    Table[a[n],{n,1,100}]

A230254 Number of ways to write n = p + q with p and (p+1)*q/2 + 1 both prime.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Oct 14 2013

Keywords

Comments

Conjecture: a(n) > 0 for all n > 3.
We have verified this for n up to 10^8.
We also have some similar conjectures, for example, any integer n > 3 not equal to 17 or 66 can be written as p + q with p and (p+1)*q/2 - 1 both prime.

Examples

			a(15) = 1 since 15 = 5 + 10 with 5 and (5+1)*10/2+1 = 31 both prime.
a(30) = 1 since 30 = 2 + 28 with 2 and (2+1)*28/2+1 = 43 both prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Sum[If[PrimeQ[(Prime[i]+1)(n-Prime[i])/2+1],1,0],{i,1,PrimePi[n-1]}]
    Table[a[n],{n,1,100}]

A230261 Number of ways to write 2*n - 1 = p + q with p, p + 6 and q^4 + 1 all prime, where q is a positive integer.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Oct 14 2013

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 3. Also, any odd number greater than 6 can be written as p + q (q > 0) with p, p + 6 and q^2 + 1 all prime.
(ii) Any integer n > 1 can be written as x + y (x, y > 0) with x^4 + 1 and y^2 + y + 1 both prime.
(iii) Each integer n > 2 can be expressed as x + y (x, y > 0) with 4*x^2 + 3 and 4*y^2 -3 both prime.
Either of parts (i) and (ii) implies that there are infinitely many primes of the form x^4 + 1.

Examples

			a(6) = 2 since 2*6-1 = 5 + 6 = 7 + 4, and 5, 5+6 = 11, 7, 7+6 = 13, 6^4+1 = 1297 and 4^4+1 = 257 are all prime.
a(25) = 1 since 2*25-1 = 47 + 2, and 47, 47+6 = 53, 2^4+1 = 17 are all prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Sum[If[PrimeQ[Prime[i]+6]&&PrimeQ[(2n-1-Prime[i])^4+1],1,0],{i,1,PrimePi[2n-2]}]
    Table[a[n],{n,1,100}]
  • PARI
    a(n)=my(s,p=5,q=7);forprime(r=11,2*n+4,if(r-p==6&&isprime((2*n-1-p)^4+1),s++); if(r-q==6&&isprime((2*n-1-q)^4+1),s++); p=q;q=r);s \\ Charles R Greathouse IV, Oct 14 2013
Showing 1-4 of 4 results.