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.

Previous Showing 11-19 of 19 results.

A220554 Number of ways to write 2n = p+q (q>0) with p, 2p+1 and (p-1)^2+q^2 all prime.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Dec 15 2012

Keywords

Comments

Conjecture: a(n)>0 for all n>1.
This has been verified for n up to 2*10^8. It implies that there are infinitely many Sophie Germain primes.
Note that Ming-Zhi Zhang asked (before 1990) whether any odd integer greater than 1 can be written as x+y (x,y>0) with x^2+y^2 prime, see A036468.
Zhi-Wei Sun also made the following related conjectures:
(1) Any integer n>2 can be written as x+y (x,y>=0) with 3x-1, 3x+1 and x^2+y^2-3(n-1 mod 2) all prime.
(2) Each integer n>3 not among 20, 40, 270 can be written as x+y (x,y>0) with 3x-2, 3x+2 and x^2+y^2-3(n-1 mod 2) all prime.
(3) Any integer n>4 can be written as x+y (x,y>0) with 2x-3, 2x+3 and x^2+y^2-3(n-1 mod 2) all prime. Also, every n=10,11,... can be written as x+y (x,y>=0) with x-3, x+3 and x^2+y^2-3(n-1 mod 2) all prime.
(4) Any integer n>97 can be written as p+q (q>0) with p, 2p+1, n^2+pq all prime. Also, each integer n>10 can be written as p+q (q>0) with p, p+6, n^2+pq all prime.
(5) Every integer n>3 different from 8 and 18 can be written as x+y (x>0, y>0) with 3x-2, 3x+2 and n^2-xy all prime.
All conjectures verified for n up to 10^9. - Mauro Fiorentini, Sep 21 2023

Examples

			a(16)=1 since 32=11+21 with 11, 2*11+1=23 and (11-1)^2+21^2=541 all prime.
		

References

  • R. K. Guy, Unsolved Problems in Number Theory, 2nd Edition, Springer, New York, 2004, p. 161.

Crossrefs

Programs

  • Mathematica
    a[n_]:=a[n]=Sum[If[PrimeQ[p]==True&&PrimeQ[2p+1]==True&&PrimeQ[(p-1)^2+(2n-p)^2]==True,1,0],{p,1,2n-1}]
    Do[Print[n," ",a[n]],{n,1,1000}]

A229969 Number of ways to write n = x + y + z with 0 < x <= y <= z such that all the six numbers 2*x-1, 2*y-1, 2*z-1, 2*x*y-1, 2*x*z-1, 2*y*z-1 are prime.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Oct 04 2013

Keywords

Comments

Conjecture: a(n) > 0 for all n > 5. Moreover, any integer n > 6 can be written as x + y + z with x among 3, 4, 6, 10, 15 such that 2*y-1, 2*z-1, 2*x*y-1, 2*x*z-1, 2*y*z-1 are prime.
We have verified this conjecture for n up to 10^6. As (2*x-1)+(2*y-1)+(2*z-1) = 2*(x+y+z)-3, it implies Goldbach's weak conjecture which has been proved.
Zhi-Wei Sun also had some similar conjectures including the following (i)-(iii):
(i) Any integer n > 6 can be written as x + y + z (x, y, z > 0) with 2*x-1, 2*y-1, 2*z-1 and 2*x*y*z-1 all prime and x among 2, 3, 4. Also, each integer n > 2 can be written as x + y + z (x, y, z > 0) with 2*x+1, 2*y+1, 2*z+1 and 2*x*y*z+1 all prime and x among 1, 2, 3.
(ii) Each integer n > 4 can be written as x + y + z with x = 3 or 6 such that 2*y+1, 2*x*y*z-1 and 2*x*y*z+1 are prime.
(iii) Every integer n > 5 can be written as x + y + z (x, y, z > 0) with x*y-1, x*z-1, y*z-1 all prime and x among 2, 6, 10. Also, any integer n > 2 not equal to 16 can be written as x + y + z (x, y, z > 0) with x*y+1, x*z+1, y*z+1 all prime and x among 1, 2, 6.
See also A229974 for a similar conjecture involving three pairs of twin primes.

Examples

			a(10) = 2 since 10 = 2+2+6 = 3+3+4 with 2*2-1, 2*6-1, 2*2*2-1, 2*2*6 -1, 2*3-1, 2*4-1, 2*3*3-1, 2*3*4-1 all prime.
		

Crossrefs

Programs

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

A229974 Number of ways to write n = x + y + z (x, y, z > 0) with the six numbers 2*x-1, 2*x+1, 2*x*y-1, 2*x*y+1, 2*x*y*z-1, 2*x*y*z+1 all prime.

Original entry on oeis.org

0, 0, 0, 1, 1, 4, 2, 1, 2, 4, 5, 3, 3, 8, 1, 9, 4, 6, 3, 8, 16, 8, 4, 8, 7, 3, 10, 7, 3, 14, 4, 6, 8, 13, 12, 14, 6, 8, 13, 7, 13, 15, 13, 9, 9, 10, 7, 13, 14, 7, 16, 15, 12, 8, 16, 31, 11, 6, 16, 13, 16, 15, 26, 8, 10, 17, 10, 12, 11, 17, 9, 9, 13, 18, 17, 23, 14, 10, 7, 13, 29, 13, 18, 14, 9, 19, 21, 14, 19, 14, 25, 11, 14, 18, 13, 21, 15, 26, 14, 8
Offset: 1

Views

Author

Zhi-Wei Sun, Oct 05 2013

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 3. Moreover, any integer n > 3 can be written as x + y + z with x among 2, 3, 6 such that {2*x*y-1, 2*x*y+1} and {2*x*y*z-1, 2*x*y*z+1} are twin prime pairs.
(ii) Each integer n > 11 can be written as x + y + z (x, y, z > 0) with x-1, x+1, x*y-1, x*y+1, x*y*z-1, x*y*z+1 all prime, moreover we may require that x is among 4, 6, 12.
(iii) Any integer n > 3 not equal to 10 can be written as x + y + z (x, y, z > 0) such that the three numbers 2*x-1, 2*x*y-1 and 2*x*y*z-1 are Sophie Germain primes, moreover we may require that x is among 2, 3, 6.
Note that part (i) or (ii) of the above conjecture implies the twin prime conjecture, while part (iii) implies that there are infinitely many Sophie Germain primes.
See also the comments of A229969 for other similar conjectures.

Examples

			a(4) = 1 since 4 = 2+1+1 with 2*2-1 and 2*2+1 both prime.
a(5) = 1 since 5 = 3+1+1 with 2*3-1 and 2*3+1 both prime.
a(15) = 1 since 15 = 6+5+4 with 2*6-1, 2*6+1, 2*6*5-1, 2*6*5+1, 2*6*5*4-1, 2*6*5*4+1 all prime.
		

Crossrefs

Programs

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

A230037 Number of ways to write n = x + y + z (0 < x <= y <= z) such that the four pairs {6*x-1, 6*x+1}, {6*y-1, 6*y+1}, {6*z-1, 6*z+1} and {6*x*y-1, 6*x*y+1} are twin prime pairs.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Oct 06 2013

Keywords

Comments

Conjecture: a(n) > 0 for all n > 2. Moreover, any integer n > 2 can be written as x + y + z with x = 1 or 5 such that {6*y-1, 6*y+1}, {6*z-1, 6*z+1} and {6*x*y-1, 6*x*y+1} are twin prime pairs.
We have verified this for n up to 5*10^7. It implies the twin prime conjecture.
Zhi-Wei Sun also made the following similar conjectures:
(i) Any integer n > 2 can be written as x + y + z (x, y, z > 0) with the 8 numbers 6*x-1, 6*x+1, 6*y-1, 6*y+1, 6*z-1, 6*z+1, 6*x*y-1 and 6*x*y*z-1 (or 12*x*y-1) all prime.
(ii) Each integer n > 2 can be written as x + y + z (x, y, z > 0) with the 8 numbers 6*x-1, 6*x+1, 6*y-1, 12*y-1, 6*z-1 (or 6*x*y-1), 2*(x^2+y^2)+1, 2*(x^2+z^2)+1, 2*(y^2+z^2)+1 all prime.
(iii) Any integer n > 8 can be written as x + y + z (x, y, z > 0) with x-1, x+1, y-1, y+1, x*z-1 and y*z-1 all prime.
(iv) Every integer n > 4 can be written as p + q + r (r > 0) with p, q, 2*p*q-1, 2*p*r-1 and 2*q*r-1 all prime.
(v) Any integer n > 10 can be written as x^2 + y^2 + z (x, y, z > 0) with 2*x*y-1, 2*x*z+1 and 2*y*z+1 all prime.

Examples

			a(10) = 1 since 10 = 1 + 2 + 7 , and {6*1-1, 6*1+1}, {6*2-1, 6*2+1}, {6*7-1, 6*7+1}  and {6*1*2-1, 6*1*2+1} are twin prime pairs.
		

Crossrefs

Programs

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

A199800 Number of ways to write n = p+q with p, 6q-1 and 6q+1 all prime.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Dec 21 2012

Keywords

Comments

Conjecture: a(n)>0 for all n>11.
This implies the twin prime conjecture, and it has been verified for n up to 10^9.
Zhi-Wei Sun also made some similar conjectures, for example, any integer n>5 can be written as p+q with p, 2q-3 and 2q+3 all prime, and each integer n>4 can be written as p+q with p, 3q-2+(n mod 2) and 3q+2-(n mod 2) all prime.

Examples

			a(3)=1 since 3=2+1 with 2, 6*1-1 and 6*1+1 all prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=a[n]=Sum[If[PrimeQ[n-k]==True&&PrimeQ[6k-1]==True&&PrimeQ[6k+1]==True,1,0],{k,1,n-1}]
    Do[Print[n," ",a[n]],{n,1,100}]

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

Original entry on oeis.org

0, 0, 1, 2, 3, 1, 3, 2, 5, 2, 4, 2, 7, 2, 5, 3, 5, 3, 10, 4, 5, 3, 8, 3, 14, 6, 5, 4, 11, 5, 11, 3, 11, 9, 4, 5, 10, 5, 11, 9, 12, 3, 19, 7, 11, 6, 12, 9, 11, 7, 17, 7, 13, 5, 22, 3, 3, 15, 16, 5, 25, 4, 9, 11, 13, 5, 19, 6, 22, 6, 11, 6, 39, 6, 24, 7, 7, 6, 25, 8, 21, 11, 24, 7, 31, 7, 19, 11, 33, 10, 14, 8, 15, 27, 18, 9, 21, 4, 27, 9
Offset: 1

Views

Author

Zhi-Wei Sun, Nov 12 2013

Keywords

Comments

Conjectures:
(i) a(n) > 0 for all n > 2. Also, any integer n > 4 can be written as x + y (x, y > 0) with x^2 * y + 1 prime.
(ii) Each n = 2, 3, ... can be expressed as x + y (x, y > 0) with (x*y)^2 + x*y + 1 prime.
(iii) Also, any integer n > 2 can be written as x + y (x, y > 0) with 2*(x*y)^2 - 1 (or (x*y)^2 + x*y - 1) prime.
From Mauro Fiorentini, Jul 31 2023: (Start)
Both parts of conjecture (i) verified for n up to 10^9.
Conjecture (ii) and both parts of conjecture (iii) verified for n up to 10^7. (End)

Examples

			a(6) = 1 since 6 = 4 + 2 with 4^2*2 - 1 = 31 prime.
		

Crossrefs

Programs

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

A220572 Number of ways to write 2n-1=x+y (x,y>=0) with x^18+3*y^18 prime.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Dec 16 2012

Keywords

Comments

Conjecture: a(n)>0 for every n=1,2,3,.... Moreover, any odd integer greater than 2092 can be written as x+y (x,y>0) with x-3, x+3 and x^18+3*y^18 all prime.
This has been verified for n up to 2*10^6.
Zhi-Wei Sun also made the following general conjecture: For each positive integer m, any sufficiently large odd integer n can be written as x+y (x,y>0) with x-3, x+3 and x^m+3*y^m all prime (and hence there are infinitely many primes in the form x^m+3*y^m). In particular, for m = 1, 2, 3, 4, 5, 6, 18 any odd integer greater than one can be written as x+y (x,y>0) with x^m+3*y^m prime, and for m =1, 2, 3 any odd integer n>15 can be written as x+y (x,y>0) with x-3, x+3 and x^m+3*y^m all prime.
Our computation suggests that for each m=7,...,20 any odd integer greater than 32, 10, 24, 30, 48, 36, 72, 146, 48, 48, 152, 2, 238, 84 respectively can be written as x+y (x,y>0) with x^m+3*y^m prime.

Examples

			a(3)=1 since 2*3-1=5=1+4 with 1^18+3*4^18=206158430209 prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=a[n]=Sum[If[PrimeQ[k^18+3*(2n-1-k)^18]==True,1,0],{k,0,2n-1}]
    Do[Print[n," ",a[n]],{n,1,100}]

A231635 Number of ways to write n = x + y with 0 < x <= y such that lcm(x, y) + 1 is prime.

Original entry on oeis.org

0, 1, 1, 1, 2, 1, 3, 2, 1, 1, 4, 2, 6, 1, 3, 2, 8, 4, 5, 4, 3, 2, 7, 5, 6, 2, 3, 2, 8, 5, 10, 6, 3, 1, 8, 3, 9, 4, 4, 4, 14, 6, 16, 7, 7, 2, 12, 6, 8, 4, 5, 5, 21, 5, 8, 6, 4, 8, 11, 7, 12, 5, 6, 4, 10, 8, 22, 6, 10, 6, 17, 9, 23, 7, 11, 12, 18, 10, 19, 10, 10, 7, 23, 8, 15, 4, 7, 8, 14, 11, 19, 9, 2, 4, 11, 10, 35, 6, 10, 10
Offset: 1

Views

Author

Zhi-Wei Sun, Nov 12 2013

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 1. Also, any integer n > 3 can be written as x + y (x, y > 0) with lcm(x, y) - 1 prime.
(ii) Each n = 2, 3, ... can be expressed as x + y (x, y > 0) with lcm(x, y)^2 + lcm(x, y) + 1 prime. Also, any integer n > 1 not equal to 10 can be written as x + y (x, y > 0) with lcm(x, y)^2 + 1 prime.
From Mauro Fiorentini, Aug 02 2023: (Start)
Both parts of conjecture (i) verified for n up to 10^9.
Both parts of conjecture (ii) verified for n up to 10^6. (End)

Examples

			a(9) = 1 since 9 = 3 + 6 with lcm(3, 6) + 1 = 7 prime.
a(10) = 1 since 10 = 4 + 6 with lcm(4, 6) + 1 = 13 prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Sum[If[PrimeQ[LCM[x,n-x]+1],1,0],{x,1,n/2}]
    Table[a[n],{n,1,100}]

A231883 Number of ways to write n = x + y (x, y > 0) with x^2 + (n-2)*y^2 prime.

Original entry on oeis.org

0, 0, 2, 2, 2, 2, 4, 1, 5, 2, 5, 1, 4, 4, 3, 1, 7, 2, 3, 3, 6, 7, 3, 2, 6, 2, 9, 3, 8, 3, 10, 3, 5, 8, 8, 4, 7, 5, 13, 4, 12, 6, 7, 6, 8, 10, 14, 4, 17, 9, 9, 6, 9, 5, 8, 5, 9, 7, 12, 10, 11, 7, 11, 8, 12, 4, 13, 3, 22, 6, 16, 7, 14, 8, 10, 4, 14, 4, 17, 9, 16, 6, 12, 11, 14, 4, 21, 4, 21, 8, 18, 3, 11, 14, 23, 7, 22, 5, 23, 8
Offset: 1

Views

Author

Zhi-Wei Sun, Nov 21 2013

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 2, and a(n) = 1 only for n = 8, 12, 16. Moreover, if m and n are positive integers with m >= max{2, n-1} and gcd(m, n+1) = 1, then x^2 + n*y^2 is prime for some positive integers x and y with x + y = m, except for the case m = n + 3 = 29.
(ii) Let m and n be integers greater than one with m >= (n-1)/2 and gcd(m, n-1) = 1. Then x + n*y is prime for some positive integers x and y with x + y = m.
(iii) Any integer n > 3 not equal to 12 or 16 can be written as x + y (x, y > 0) with (n-2)*x - y and (n-2)*x^2 + y^2 both prime.

Examples

			 a(8) = 1 since 8 = 5 + 3 with 5^2 + (8-2)*3^2 = 79 prime.
a(12) = 1 since 12 = 11 + 1 with 11^2 + (12-2)*1^2 = 131 prime.
a(16) = 1 since 16 = 15 + 1 with 15^2 + (16-2)*1^2 = 239 prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Sum[If[PrimeQ[x^2+(n-2)*(n-x)^2],1,0],{x,1,n-1}]
    Table[a[n],{n,1,100}]
Previous Showing 11-19 of 19 results.