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 31-40 of 109 results. Next

A204814 Number of decompositions of 2n into an unordered sum of two Ramanujan primes.

Original entry on oeis.org

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

Views

Author

Donovan Johnson, Jan 27 2012

Keywords

Comments

Suggested by John W. Nicholson.
There are 95 zeros in the first 10000 terms. Are there more? Related to Goldbach's conjecture. - T. D. Noe, Jan 27 2012
There are no other zeros in the first 10^8 terms. a(n) > 0 for n from 1313 to 10^8. - Donovan Johnson, Jan 27 2012

Examples

			a(29) = 3. 2*29 = 58 = 11+47 = 17+41 = 29+29 (11, 17, 29, 41 and 47 are all Ramanujan primes). 58 is the unordered sum of two Ramanujan primes in three ways.
		

Crossrefs

A235645 From Goldbach's conjecture and Chen's theorem: number of decompositions of 2n as the sum of either two primes, or a prime and a semiprime.

Original entry on oeis.org

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

Views

Author

Jean-François Alcover, Jan 13 2014

Keywords

Comments

The first 15 terms from this sequence and from A045917 are identical.

Examples

			40 = 23+17 = 29+11 = 37+3, so a(20) = 3.
Compare with 40 = 23+17 = 29+11 = 31+9 = 37+3 and A045917(20) = 4.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := Count[IntegerPartitions[2*n, {2}], {p_, q_} /; PrimeQ[p] && (PrimeQ[q] || Length[FactorInteger[q]] == 2)]; Table[a[n], {n, 1, 100}]

A240708 Number of decompositions of 2n into an unordered sum of two terms of A240699.

Original entry on oeis.org

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

Views

Author

Lei Zhou, Apr 10 2014

Keywords

Comments

The first different term of this sequence to A002375 is a(107).
Conjecture: for n >= 3, this sequence is always positive.
This is a stronger version of the Goldbach Conjecture.

Examples

			For n <= 106, refer to examples in A002375.
For n = 107, 2n=214. A240699 up to 214 gives {3, 5, 7, 11, 13, 17, 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}.  We have 214 = 17+197 = 23+191 = 41+173 = 47+167 = 83+131 = 101+113 = 107+107. Seven instances found. So a(107)=7.
Where as for A002375, there is one more instance as 3+211, however 211 is not a term in A240699.
		

Crossrefs

Programs

  • Mathematica
    a240699 = {3}; Table[s = 2*n; While[a240699[[-1]] < s, p = a240699[[-1]]; While[p = NextPrime[p]; ((NextPrime[p] - p) > 6) && (6 < (p - NextPrime[p, -1]))]; AppendTo[a240699, p]]; pos = 0; ct = 0; While[pos++; pos <= Length[a240699], p = a240699[[pos]]; If[p <= n, If[MemberQ[a240699, s - p], ct++]]]; ct, {n, 1, 110}]

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

A053033 Numbers which are the average of two primes in more ways than any smaller number.

Original entry on oeis.org

1, 2, 5, 11, 17, 24, 30, 39, 42, 45, 57, 60, 84, 90, 105, 150, 165, 195, 210, 255, 315, 390, 420, 495, 525, 570, 630, 735, 825, 840, 945, 1050, 1155, 1365, 1575, 1785, 1995, 2100, 2205, 2310, 2625, 2730, 3045, 3255, 3465, 3990, 4095
Offset: 1

Views

Author

Len Smiley, Feb 23 2000

Keywords

Comments

From Ahmad J. Masad, Dec 09 2019: (Start)
Conjecture 1: This sequence is infinite.
Conjecture 2: If this sequence is infinite, then for each prime number p > 2, there exists a minimum sufficiently large number k such that all terms >= k are multiples of p. (End)
Apparently, all terms >= 90 are multiples of 15. - Hugo Pfoertner, Dec 09 2019
Positions of records in A045917. - Sean A. Irvine, Dec 04 2021

Examples

			a(1) = 1: average of 0 pairs of primes;
a(2) = 2: average of 1 pair of primes (2,2);
a(3) = 5: average of 2 pairs of primes (3,7), (5,5);
a(4) = 11: average of 3 pairs of primes (3,19), (5,17), (11,11);
a(5) = 17: average of 4 pairs of primes (3,31), (5,29), (11,23), (17,17).
		

Crossrefs

Programs

  • Maple
    (for n>0): printlevel := -1:maxx := 0:for j from 2 to 1000 do count := 0; for k from 0 to j-2 do if (isprime(j-k) and isprime(j+k)) then count := count+1 fi od; if count>maxx then print(j,count); maxx := count fi od;

Extensions

More terms from James Sellers, Feb 25 2000

A116619 a(n) = number of ways of representing 2*prime(n) as the unordered sum of two primes.

Original entry on oeis.org

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

Views

Author

Jonathan Vos Post, Mar 14 2006

Keywords

Comments

2*prime(n) = A100484(n), the n-th even semiprime.
a(n) = A071681(n) + 1. - Reinhard Zumkeller, Mar 27 2015

Examples

			2*prime(23) = 166 can be represented in 6 ways as the unordered sum of two primes: 166 = 3+163 = 17+149 = 29+137 = 53+113 = 59+107 = 83+83, so a(23) = 6.
2*prime(54) = 502 can be represented in 15 ways as the unordered sum of two primes: 502 = 3+499 = 11+491 = 23+479 = 41+461 = 53+449 = 59+443 = 71+431 = 83+419 = 101+401 = 113+389 = 149+353 = 191+311 = 233+269 = 239+263 = 251+251, so a(54) = 15.
		

Crossrefs

Programs

  • Haskell
    a116619 = (+ 1) . a071681  -- Reinhard Zumkeller, Mar 27 2015
  • PARI
    {for(n=1,83,c=0;k=2*prime(n);forprime(p=2,prime(n),if(isprime(k-p),c++));print1(c,","))} \\ Klaus Brockhaus, Dec 23 2006
    

Formula

a(n) = A045917(A100484(n)).

Extensions

Edited, corrected and extended by Klaus Brockhaus, Dec 23 2006

A136244 Least positive integer k such that 2k can be expressed as the sum of two primes in exactly n ways.

Original entry on oeis.org

1, 2, 5, 11, 17, 24, 30, 39, 42, 45, 57, 72, 60, 84, 90, 117, 123, 144, 120, 105, 162, 150, 180, 237, 165, 264, 288, 195, 231, 240, 210, 285, 255, 336, 396, 378, 438, 357, 399, 345, 519, 315, 504, 465, 390, 480, 435, 462, 450, 567, 717, 420, 495, 651, 540, 615, 759, 525, 570, 693, 645
Offset: 0

Views

Author

K. B. Subramaniam (shunya_1950(AT)yahoo.co.in), Dec 24 2007

Keywords

Comments

It appears that 2, 3, 4, 6 are the only numbers k such that 2k can be expressed as the sum of two primes in only one way.
Except when n = 1, a(n) = A258713(n). The first 11 terms of this sequence are the same as the initial terms of A053033. If a(n) exists for all n then A053033 is a subsequence. - Andrew Howroyd, Jan 28 2020

Examples

			a(3) = 11: 22 = 3 + 19 = 5 + 17 = 11 + 11. Also 22 is the least number which could be expressed as the sum of two prime numbers in exactly three ways.
		

Crossrefs

Programs

  • PARI
    a(n, lim=oo)={for(i=1, lim, my(s=0); forprime(p=2, i, s+=isprime(2*i-p)); if(s==n, return(i))); -1} \\ Andrew Howroyd, Jan 28 2020

Formula

From Andrew Howroyd, Jan 28 2020: (Start)
a(n) = A023036(n) / 2.
A045917(a(n)) = n. (End)

Extensions

a(0)=1 prepended, a(5) corrected and a(7) and beyond from Andrew Howroyd, Jan 28 2020

A171611 From Goldbach problem: number of decompositions of 2n into unordered sums of two primes > 3.

Original entry on oeis.org

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

Views

Author

Juri-Stepan Gerasimov, Dec 13 2009

Keywords

Examples

			a(5)=1 because 2*5 = 5 + 5.
		

Crossrefs

Programs

  • Maple
    A171611 := proc(n) a := 0 ; for i from 3 do p := ithprime(i) ; q := 2*n-p ; if q < p then return a ; end if; if isprime(q) then a := a+1 ; end if; if q <= p then return a ; end if; end do: end proc:
    seq(A171611(n), n=1..120) ; # R. J. Mathar, May 22 2010
  • Mathematica
    Table[s = 2*n; ct = 0; p = 3; While[p = NextPrime[p]; p <= n, If[PrimeQ[s - p], ct++]]; ct, {n, 100}] (* Lei Zhou, Apr 10 2014 *)

Extensions

a(38) changed from 5 to 4 and a(79) and a(82) changed by R. J. Mathar, May 22 2010

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

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Jan 05 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n >= 2480.
(ii) If n > 4368 then 2*n+1 can be written as 2*p + q with p and q terms of the sequence A234695.
Parts (i) and (ii) are stronger than Goldbach's conjecture (A045917) and Lemoine's conjecture (A046927) respectively.

Examples

			a(8) = 1 since 2*8 = 5 + 11 with 5, 11, prime(5) - 5 + 1 = 7 and prime(11) + 11 + 1 = 43 all prime.
		

Crossrefs

Programs

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

A083338 Number of partitions of odd numbers into three primes and of even numbers into two primes.

Original entry on oeis.org

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

Views

Author

Reinhard Zumkeller, Apr 24 2003

Keywords

Comments

a(n) > 0 for all n iff Goldbach's conjectures hold.

Crossrefs

Programs

  • Mathematica
    f[n_] := Length@ IntegerPartitions[n, If[ OddQ@ n, {3}, {2}], Prime@ Range@ PrimePi@ n]; Array[f, 92] (* Robert G. Wilson v, Nov 28 2012 *)

Formula

a(n) = if n is even then A045917(n/2) else A054860((n-1)/2).
For even n: a(n) = A061358(n); for odd n: a(n) = A068307(n). - Antti Karttunen, Sep 14 2017
Previous Showing 31-40 of 109 results. Next