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-20 of 57 results. Next

A237284 Number of ordered ways to write 2*n = p + q with p, q and A000720(p) all prime.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Feb 06 2014

Keywords

Comments

Conjecture: a(n) > 0 for all n > 2, and a(n) = 1 only for n = 3, 6, 13, 16, 19, 28, 34, 40, 61, 166, 278.
This is stronger than Goldbach's conjecture.
The conjecture is true for n <= 5*10^8. - Dmitry Kamenetsky, Mar 13 2020

Examples

			a(13) = 1 since 2*13 = 3 + 23 with 3, 23 and A000720(3) = 2 all prime.
a(278) = 1 since 2*278 = 509 + 47 with 509, 47 and A000720(509) = 97 all prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Sum[If[PrimeQ[2n-Prime[Prime[k]]],1,0],{k,1,PrimePi[PrimePi[2n-1]]}]
    Table[a[n],{n,1,80}]

A209320 Number of ways to write 2n = p+q with p and q both prime, p+1 and q-1 both practical.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Jan 19 2013

Keywords

Comments

Conjecture: a(n)>0 for all n>2.
As p+q=(p+1)+(q-1), this unifies Goldbach's conjecture and its analog involving practical numbers.
The conjecture has been verified for n up to 10^7.

Examples

			a(8) = 2 since 2*8 = 3+13 = 11+5 with 3, 5, 11, 13 all prime and 3+1, 13-1, 11+1, 5-1 all practical.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    a[n_]:=a[n]=Sum[If[PrimeQ[2n-Prime[k]]==True&&pr[Prime[k]+1]==True&&pr[2n-Prime[k]-1]==True,1,0],{k,1,PrimePi[2n-2]}]
    Do[Print[n," ",a[n]],{n,1,100}]

A236566 Number of ordered ways to write 2*n = p + q with p, q and prime(p + 2) + 2 all prime.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Jan 28 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 2.
(ii) If n > 30, then 2*n + 1 can be written as 2*p + q with p, q and prime(p + 2) + 2 all prime.
Part (i) implies both the Goldbach conjecture and the twin prime conjecture. If all primes p with prime(p + 2) + 2 are smaller than an even number N > 2, then for any such a prime p the number N! + N - p is in the interval (N!, N! + N) and hence not prime.
Similarly, part (ii) implies both Lemoine's conjecture (cf. A046927) and the twin prime conjecture.
We have verified part (i) of the conjecture for n up to 2*10^8.

Examples

			a(10) = 1 since 2*10 = 3 + 17 with 3, 17 and prime(3 + 2) + 2 = 11 + 2 = 13 all prime.
a(589) = 1 since 2*589 = 577 + 601 with 577, 601 and prime(577 + 2) + 2 = 4229 + 2 = 4231 all prime.
		

Crossrefs

Programs

  • Mathematica
    p[m_]:=PrimeQ[Prime[m+2]+2]
    a[n_]:=Sum[If[p[Prime[k]]&&PrimeQ[2n-Prime[k]],1,0],{k,1,PrimePi[2n-1]}]
    Table[a[n],{n,1,100}]

A233867 a(n) = |{0 < m < 2*n: m is a square with 2*n - 1 - phi(m) prime}|, where phi(.) is Euler's totient function (A000010).

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Dec 17 2013

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 1.
(ii) For any odd number 2*n - 1 > 4, there is a positive integer k < 2*n such that 2*n - 1 - phi(k) and 2*n - 1 + phi(k) are both prime.
By Goldbach's conjecture, 2*n > 2 could be written as p + q with p and q both prime, and hence 2*n - 1 = p + (q - 1) = p + phi(q).
By induction, phi(k^2) (k = 1,2,3,...) are pairwise distinct.

Examples

			a(29) = 1 since 2*29 - 1 = 37 + phi(5^2) with 37 prime.
a(39) = 1 since 2*39 - 1 = 71 + phi(3^2) with 71 prime.
a(66) = 1 since 2*66 - 1 = 89 + phi(7^2) with 89 prime.
a(128) = 1 since 2*128 - 1 = 223 + phi(8^2) with 223 prime.
a(182) = 1 since 2*182 - 1 = 331 + phi(8^2) with 331 prime.
a(413) = 1 since 2*413 - 1 = 823 + phi(2^2) with 823 prime.
a(171) = 3 since 2*171 - 1 = 233 + phi(18^2) = 257 + phi(14^2) = 293 + phi(12^2) with 233, 257, 293 all prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Sum[If[PrimeQ[2n-1-EulerPhi[k^2]],1,0],{k,1,Sqrt[2n-1]}]
    Table[a[n],{n,1,100}]

A066285 a(n) is the minimal difference between primes p and q whose sum is 2n.

Original entry on oeis.org

0, 0, 2, 0, 2, 0, 6, 4, 6, 0, 2, 0, 6, 4, 6, 0, 2, 0, 6, 4, 18, 0, 10, 12, 6, 8, 18, 0, 2, 0, 18, 8, 6, 12, 10, 0, 18, 4, 6, 0, 2, 0, 6, 4, 30, 0, 10, 24, 6, 16, 18, 0, 14, 24, 6, 8, 30, 0, 2, 0, 18, 8, 6, 12, 10, 0, 30, 4, 6, 0, 2, 0, 30, 8, 6, 12, 10, 0, 18, 4, 30, 0, 10, 24, 6, 28, 18, 0
Offset: 2

Views

Author

Dean Hickerson, Dec 12 2001

Keywords

Comments

Terms are always even numbers because primes present in Goldbach partitions of n > 4 are odd and n = 4 has just one partition (2+2) where the difference is 0. a(n) = 0 iff n is prime. - Marcin Barylski, Apr 28 2018

Crossrefs

Programs

  • Mathematica
    a[n_] := For[p=n, True, p--, If[PrimeQ[p]&&PrimeQ[2n-p], Return[2n-2p]]]
  • PARI
    a(n) = {forstep(k=n, 1, -1, if (isprime(k) && isprime(2*n-k), return(2*n-2*k)););} \\ Michel Marcus, Jun 01 2020

Formula

a(n) = 2 * A047160(n). - Alois P. Heinz, Jun 01 2020

A210528 Number of ways to write 2n = p+q (p<=q) with p, q and p^6+q^6 all practical.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Jan 27 2013

Keywords

Comments

Conjecture: a(n)>0 for all n>0. Moreover, for any positive integers m and n, if m is greater than one or n is not among 17, 181, 211, 251, 313, 337, then 2n can be written as p+q with p, q and p^{3m}+q^{3m} all practical.
This conjecture implies that for each m=1,2,3,... there are infinitely many practical numbers of the form p^{3m}+q^{3m} with p and q both practical.

Examples

			a(3)=1 since 2*3=2+4 with 2, 4 and 2^6+4^6=4160 all practical.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    a[n_]:=a[n]=Sum[If[pr[k]==True&&pr[2n-k]==True&&pr[k^6+(2n-k)^6]==True,1,0],{k,1,n}]
    Do[Print[n," ",a[n]],{n,1,100}]

A237168 Number of ways to write 2*n - 1 = 2*p + q with p, q, phi(p+1) - 1 and phi(p+1) + 1 all prime, where phi(.) is Euler's totient function.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Feb 04 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 12.
(ii) Any even number greater than 4 can be written as p + q with p, q, phi(p+2) - 1 and phi(p+2) + 1 all prime.
Part (i) implies both Lemoine's conjecture (cf. A046927) and the twin prime conjecture, while part (ii) unifies Goldbach's conjecture and the twin prime conjecture.

Examples

			a(9) = 1 since 2*9 - 1 = 2*7 + 3 with 7, 3, phi(7+1) - 1 = 3 and phi(7+1) + 1 = 5 all prime.
a(934) = 1 since 2*934 - 1 = 2*457 + 953 with 457, 953, phi(457+1) - 1 = 227 and phi(457+1) + 1 = 229 all prime.
		

Crossrefs

Programs

  • Mathematica
    PQ[n_]:=PrimeQ[EulerPhi[n]-1]&&PrimeQ[EulerPhi[n]+1]
    a[n_]:=Sum[If[PQ[Prime[k]+1]&&PrimeQ[2n-1-2*Prime[k]],1,0],{k,1,PrimePi[n-1]}]
    Table[a[n],{n,1,70}]

A002092 From a Goldbach conjecture: records in A185091.

Original entry on oeis.org

1, 3, 5, 7, 17, 29, 47, 61, 73, 83, 277, 317, 349, 419, 503, 601, 709, 829, 877, 1129, 1237, 1367, 1429, 1669, 1801, 2467, 2833, 2879, 3001, 3037, 3329, 3821, 4861, 5003, 5281, 5821, 5897, 6301, 6329, 6421, 6481, 6841, 7069, 7121, 7309, 7873, 8017, 8597, 8821
Offset: 1

Views

Author

Keywords

Comments

See A002091. The sequence gives the record values of q in the representations minimizing q of 2*k+1 = 2*p+q, p prime, q {1,prime}.
Checked up to 2*k = 10^13.

References

  • Brian H. Mayoh, On the second Goldbach conjecture. Nordisk Tidskr. Informations-Behandling 6, 1966, pp. 48-50.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Formula

a(n) = A185091((A002091(n)+1)/2).

Extensions

Comment added, a(19)-a(32) from Hugo Pfoertner, Sep 03 2011
a(33) from Jason Kimberley, a(34)-a(40) from Hugo Pfoertner, Sep 09 2011
a(41)-a(49) from Hugo Pfoertner, Sep 25 2011

A024684 Number of ways prime(n) is a sum of three distinct primes.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 6, 9, 11, 13, 13, 15, 18, 17, 19, 25, 26, 28, 32, 31, 37, 32, 39, 44, 51, 54, 48, 60, 55, 62, 64, 73, 80, 79, 74, 89, 84, 92, 86, 92, 107, 119, 105, 118, 122, 117, 135, 143, 146, 147, 141, 149, 159, 157, 176, 175, 190, 180
Offset: 1

Views

Author

Keywords

Examples

			a(9) = 2 because prime(9) = 23 and 23 = 3 + 7 + 13 = 5 + 7 + 11.
		

Crossrefs

Programs

  • Mathematica
    last = 313; pp = PrimePi[last]; t = Select[Sort[Tally[Select[Total /@ Subsets[Prime[Range[2, pp]], {3}], PrimeQ]]], #[[1]] <= last &]; Join[{0, 0, 0, 0, 0, 0, 0}, Transpose[t][[2]]] (* T. D. Noe, Apr 15 2013 *)

Formula

a(n) = A125688(prime(n)). - R. J. Mathar, Jun 09 2014

A224534 Prime numbers that are the sum of three distinct prime numbers.

Original entry on oeis.org

19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 251, 257, 263, 269, 271, 277, 281, 283, 293, 307
Offset: 1

Views

Author

T. D. Noe, Apr 15 2013

Keywords

Comments

Similar to Goldbach's weak conjecture.
Primes in A124867, and by the comment in A124867 also the set of all primes >=19. - R. J. Mathar, Apr 19 2013
"Goldbach's original conjecture (sometimes called the 'ternary' Goldbach conjecture), written in a June 7, 1742 letter to Euler, states 'at least it seems that every number that is greater than 2 is the sum of three primes' (Goldbach 1742; Dickson 2005, p. 421). Note that here Goldbach considered the number 1 to be a prime, a convention that is no longer followed." [Weisstein] - Jonathan Vos Post, May 15 2013

Examples

			19 = 3 + 5 + 11.
		

Crossrefs

Cf. A002372, A002375, A024684 (number of sums), A224535, A166063, A166061, A071621.

Programs

  • Mathematica
    Union[Select[Total /@ Subsets[Prime[Range[2, 30]], {3}], PrimeQ]]
Previous Showing 11-20 of 57 results. Next