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 22 results. Next

A180007 Number of Goldbach partitions of 6^n.

Original entry on oeis.org

1, 4, 13, 49, 161, 656, 2751, 12505, 58482, 280348, 1374563, 6864809
Offset: 1

Views

Author

Jonathan Vos Post, Aug 06 2010

Keywords

Comments

Number of ways of writing 6^n as the sum of two odd primes, when the order does not matter. Number of ways writing 6^n as unordered sums of 2 primes. This is to 6 as A006307 is to 2 and as A065577 is to 10. This is the 6th row of the array A[k,n] = Number of ways writing k^n as unordered sums of 2 primes.
A061358(4^n) starts 1, 2, 5, 8, 22, 53, 151, 435, for n=1,2,... (bisection of A006307). A061358(8^n) starts 1, 5, 11, 53, 244, 1314, 7471, (tri-section of A006307). A061358(10^n) = A065577(n). A061358(12^n) = 1, 11, 53, 348, 2523, 20564... A061358(14^n) = 2, 9, 50, 330, 2924, 27225,... - R. J. Mathar, Aug 07 2010

Examples

			a(1) = 1 because 6^1 = 6 = 3+3.
a(2) = 4 because 6^2 = 36 = 5+31 = 7+29 = 13+23 = 17+19.
a(3) = 13 because 6^3 = 216 = 5+211 = 17+199 = 19+197 = 23+193 = 37+179 = 43+173 = 53+163 = 59+157 = 67+149 = 79+137 = 89+127 = 103+113 = 107+109.
		

Crossrefs

Programs

  • Maple
    A061358 := proc(n) local a,p ; a := 0 ; p := nextprime(floor((n-1)/2)) ; while p <= n do if isprime(n-p) then a := a+1 ; end if; p := nextprime(p) ; end do ; return a; end proc:
    A180007 := proc(n) A061358(6^n) ; end proc:
    for n from 1 do printf("%d,\n",A180007(n)) ; end do:
    # R. J. Mathar, Aug 07 2010
  • Mathematica
    Table[Count[Sort@ IntegerPartitions[6^n, {2}], {u_, v_} /; And[PrimeQ@ u, u != 2, PrimeQ@ v]], {n, 6}] (* Michael De Vlieger, Jun 02 2015 *)
  • PARI
    a(n)=my(t=6^n,s); forprime(p=2,t\2, if(isprime(t-p), s++)); s \\ Charles R Greathouse IV, Jun 02 2015

Formula

a(n) = A061358(6^n) = A061358(A000400(n)).

Extensions

a(5) corrected, 4 terms added by R. J. Mathar, Aug 07 2010
a(10)-a(12) from Manfred Scheucher, Jun 01 2015

A154804 Number of ways to represent 2*n as the sum of two distinct primes (counting 1 as a prime).

Original entry on oeis.org

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

Views

Author

Omar E. Pol, Jan 16 2009

Keywords

Comments

Number of ways to represent 2*n as the sum of two distinct noncomposite numbers. - Omar E. Pol, Dec 11 2024

Crossrefs

Formula

a(n) = A101264(n-1) + A061357(n). [From R. J. Mathar, Jan 21 2009]
a(n) = A001031(n) - A080339(n).

Extensions

More terms from R. J. Mathar, Jan 21 2009
Edited by Franklin T. Adams-Watters, Jan 31 2009

A276034 a(n) is the number of decompositions of 2n into an unordered sum of two primes in A274987.

Original entry on oeis.org

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

Views

Author

Lei Zhou, Nov 15 2016

Keywords

Comments

The two primes are allowed to be the same.
It is conjectured that the primes in A274987 (a subset of all primes) are sufficient to decomposite even numbers into two primes in A274987 when n > 958.
This sequence provides a very tight alternative of the Goldbach conjecture for all positive integers, in which indices of zero terms form a complete sequence {1, 2, 16, 26, 64, 97, 107, 122, 146, 167, 194, 391, 451, 496, 707, 856, 958}.
There is no more zero terms of a(n) tested up to n = 100000.

Examples

			A274987 = {3, 5, 7, 11, 13, 17, 23, 31, 37, 53, 59, 61, 73, 79, 83, 89, 101, 103, 109, ...}.
For n=3, 2n=6 = 3+3, one case of decomposition, so a(3)=1;
for n=4, 2n=8 = 3+5, one case of decomposition, so a(4)=1;
...
for n=17, 2n=34 = 3+31 = 11+23 = 17+17, three cases of decompositions, so a(17)=3.
		

Crossrefs

Programs

  • Mathematica
    p = 3; sp = {p}; a = Table[m = 2*n; l = Length[sp]; While[sp[[l]] < m, While[p = NextPrime[p]; cp = 2*3^(Floor[Log[3, 2*p - 1]]) - p; ! PrimeQ[cp]]; AppendTo[sp, p]; l++]; ct = 0; Do[If[(2*sp[[i]] <= m) && (MemberQ[sp, m - sp[[i]]]), ct++], {i, 1, l}]; ct, {n, 1, 87}]

A276520 a(n) is the number of decompositions of n into unordered form p + c*q, where p, q are terms of A274987, c=1 for even n-s and c=2 for odd n-s.

Original entry on oeis.org

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

Views

Author

Lei Zhou, Nov 11 2016

Keywords

Comments

p=q is allowed.
It is conjectured that the primes p, q in A274987 (a subset of all primes) are sufficient to decomposite all numbers into p and c*q (c=1 when n is even, 2 when c is odd) when n > 2551.
This sequence provides a very tight alternative of the Goldbach conjecture for all positive integers, in which indices of zero terms form a complete sequence {1, 2, 3, 4, 5, 7, 32, 52, 55, 61, 128, 194, 214, 244, 292, 334, 388, 782, 902, 992, 1414, 1571, 1712, 1916, 2551}.
There are no more zero terms of a(n) up to n = 100000.

Examples

			A274987 = {3, 5, 7, 11, 13, 17, 23, 31, 37, 53, 59, 61, 73, 79, 83, 89, 101, 103, 109, ...}
For n=6, 6 = 3+3, one case of decomposition, so a(6)=1;
For n=7, 7 < 3+2*3=9, no eligible case could be found, so a(7)=0;
...
For n=17, 17 = 3+2*7 = 7+2*5 = 11+2*3, three cases of decompositions, so a(17)=3.
		

Crossrefs

Programs

  • Mathematica
    p = 3; sp = {p}; Table[l = Length[sp]; While[sp[[l]] < n, While[p = NextPrime[p]; cp = 2*3^(Floor[Log[3, 2*p - 1]]) - p; ! PrimeQ[cp]]; AppendTo[sp, p]; l++]; c = 2 - Mod[n + 1, 2]; ct = 0; Do[If[MemberQ[sp, n - c*sp[[i]]], If[c == 1, If[(2*sp[[i]]) <= n, ct++], ct++]], {i, 1, l}]; ct, {n, 1, 87}]

A209266 a(n) is the number of 3-prime arithmetic progression prime chains surrounding the n-th prime number with 5-smooth intervals.

Original entry on oeis.org

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

Views

Author

Lei Zhou, Feb 07 2013

Keywords

Comments

Based on the conjecture in A211376, a(n) > 0.
Last appearance of positive integers in a(n) at n<220000
a(11)=1 (a(n) > 1 for 11
a(46)=2; a(10680)=3; a(32293)=4; a(212493)=5

Examples

			n=3: prime(3)=5, 3,5,7 form a 3-prime arithmetic progression prime chain with the interval of 2, a 5-smooth number.  And this is the only case.  So a(3)=1;
...
n=43: prime(43)=191, the following 3-prime arithmetic progression prime chains exists:
  149,191,233 (gap 42=2*3*7, not 5-smooth)
  131,191,251 (gap 60=2^2*3*5, 5-smooth)
  113,191,269 (gap 78=2*3*13, not 5-smooth)
  101,191,281 (gap 90=2*3^2*5, 5-smooth)
  89,191,293  (gap 102=2*3*17, not 5-smooth)
  71,191,311  (gap 120=2^3*3*5, 5-smooth)
  29,191,353  (gap 162=2*3^4, 5-smooth)
  23,191,359  (gap 168=2^3*3*7, not 5-smooth)
  3,191,379   (gap 188=2^2*47, not 5-smooth)
Among these groups, there are 4 5-smooth gaps.  So, a(43)=4.
		

Crossrefs

Programs

  • Mathematica
    Table[p = Prime[i]; ct = 0; Do[If[(PrimeQ[p - j]) && (PrimeQ[p + j]),
       f = Last[FactorInteger[j]][[1]]; If[f <= 5, ct++]], {j, 2, p,
       2}]; ct, {i, 3, 89}]

A211376 a(n) is the smallest 5-smooth number k such that both prime(n) - k and prime(n) + k are prime.

Original entry on oeis.org

2, 4, 6, 6, 6, 12, 6, 12, 12, 6, 12, 24, 6, 6, 12, 18, 6, 12, 6, 18, 24, 18, 30, 12, 6, 6, 30, 24, 24, 18, 30, 12, 18, 12, 6, 36, 30, 6, 12, 18, 60, 30, 30, 72, 12, 60, 30, 48, 6, 12, 30, 12, 6, 6, 12, 60, 6, 12, 54, 24, 24, 48, 36, 36, 18, 30, 36, 18, 6, 90
Offset: 3

Author

Lei Zhou, Feb 07 2013

Keywords

Comments

The three numbers prime(n) - k, prime(n), prime(n) + k are an arithmetic progression of primes.
Conjecture: a(n) is defined for all integers n > 2.
Conjecture confirmed true up to n = 300000, no exceptions.
Note that if (p1, n, p2) is an arithmetic progression where p1 and p2 are prime, then 2n = p1 + p2 is a Goldbach pair. There are numbers n such that no such sequence (p1, n, p2) exists for which the common difference n - p1 = p2 - n is 5-smooth. The first such number is 90. The first such odd number is 1845.
a(n) is defined for 3 <= n <= 10^7. - David A. Corneth, Jul 10 2021

Examples

			Let n = 43. The 43rd prime is 191, and 191-42 = 149 and 191+42 = 233 are both prime. However, 42 = 2*3*7 is not a 5-smooth number, so a(43) != 42. But 191-60 = 31 and 191+60 = 251 are both prime numbers, and 60 = 2^2*3*5 is the smallest such 5-smooth number. So a(43) = 60.
		

Crossrefs

Programs

  • Mathematica
    Table[p=Prime[i];j=0;While[j=j+2;If[(PrimeQ[p-j])&&(PrimeQ[p+j]), f=Last[FactorInteger[j]][[1]],f=p];f>5];j,{i,3,72}]

A378916 a(n) is the smallest positive integer having n decompositions of twice its value into sums of two noncomposite numbers.

Original entry on oeis.org

1, 2, 7, 12, 21, 24, 30, 70, 42, 45, 57, 60, 75, 84, 90, 117, 126, 156, 105, 135, 150, 189, 180, 165, 234, 288, 303, 195, 231, 240, 210, 285, 255, 396, 378, 438, 357, 444, 345, 360, 315, 330, 603, 390, 480, 435, 462, 450, 546, 609, 627, 420, 663, 540, 555, 615
Offset: 1

Author

Omar E. Pol, Dec 12 2024

Keywords

Comments

a(n) is the index of first n in A001031.

Examples

			For n = 3 we have that the first 3 in A001031 has index 7 and twice 7 is 14 and 14 has 3 decompositions into sums of two noncomposite numbers as follows: [1 + 13], [3 + 11], [7 + 7], so a(3) = 7.
		

Crossrefs

Extensions

More terms from David Consiglio, Jr., Dec 18 2024

A180041 Number of Goldbach partitions of (2n)^n.

Original entry on oeis.org

0, 2, 13, 53, 810, 20564, 274904, 6341424, 419586990
Offset: 1

Author

Jonathan Vos Post, Aug 07 2010

Keywords

Comments

This is the main diagonal of the array mentioned in A180007, only considering even rows (as odd numbers cannot be the sums of two odd primes), namely A(2n, n) = number of ways of writing (2n)^n as the sum of two odd primes, when the order does not matter.

Examples

			a(1) = 0 because 2*1 = 2 is too small to be the sum of two primes.
a(2) = 2 because 4^2 = 16 = 3+13 = 5+11.
a(3) = 13 because 6^3 = 216 and A180007(3) = Number of Goldbach partitions of 6^3 = 13.
a(4) = 53 because 8^4 = 2^12 and A006307(12) = Number of ways writing 2^12 as unordered sums of 2 primes.
		

Crossrefs

Programs

  • Maple
    A180041 := proc(n) local a,m,p: if(n=1)then return 0:fi: a:=0: m:=(2*n)^n: p:=prevprime(ceil((m-1)/2)): while p > 2 do if isprime(m-p) then a:=a+1: fi: p := prevprime(p): od: return a: end: seq(A180041(n),n=1..5); # Nathaniel Johnston, May 08 2011
  • Mathematica
    f[n_] := Block[{c = 0, p = 3, m = (2 n)^n}, lmt = Floor[m/2] + 1; While[p < lmt, If[ PrimeQ[m - p], c++ ]; p = NextPrime@p]; c]; Do[ Print[{n, f@n // Timing}], {n, 8}] (* Robert G. Wilson v, Aug 10 2010 *)

Formula

a(n) = A061358((2*n)^n) = A061358(A062971(n)).

Extensions

a(6)-a(8) from Robert G. Wilson v, Aug 10 2010
a(9) from Giovanni Resta, Apr 15 2019

A188268 Smallest k such that prime(k) + prime(k+1) = prime(k+2) + prime(k-n).

Original entry on oeis.org

4, 8, 153, 61, 258, 649, 4134, 3384, 29295, 101468, 33607, 165325, 298594, 703923, 2393291, 32214330, 12432950, 12849377, 539169143, 396264119, 406027081, 33772761, 5097974305, 4764006510, 23719367863, 44982489668, 54393474823, 25708849510
Offset: 1

Author

Michel Lagneau, Mar 30 2011

Keywords

Comments

Goldbach's conjecture is one of the oldest unsolved problems in number theory and in all of mathematics. It states: every even integer greater than 2 can be expressed as the sum of two primes. Because there exist several decompositions (see A002375), this sequence gives k for a second decomposition of prime(k) + prime(k+1) that gives prime(k+2) + prime(k-n).
a(n) > pi(2*10^12) for n >= 29. - Donovan Johnson, Apr 06 2011

Examples

			a(2) = 8 because prime(8) + prime(9) = prime(10) + prime(6); i.e., 19 + 23 = 29 + 13.
		

Crossrefs

Programs

  • Maple
    A188268 := proc(n) local k ,pk; k := 1+n ; pk := Array([ithprime(k), ithprime(k+1), ithprime(k+2), ithprime(k-n)]) ; for k from 1+n do if pk[1]+pk[2]-pk[3] = pk[4] then return k ; end if; pk[1] := pk[2] ; pk[2] := pk[3] ; pk[3] := nextprime(pk[2]) ; pk[4] := nextprime(pk[4]) ; end do; end proc: # R. J. Mathar, Mar 31 2011

Extensions

a(23)-a(28) from Donovan Johnson, Apr 06 2011

A280134 Number of primes of the form 4(n - k - 1) + 3 where 0 <= k and prime of the form 4k + 3 <= n.

Original entry on oeis.org

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

Author

Juri-Stepan Gerasimov, Dec 26 2016

Keywords

Comments

(1) Conjecture: a(n) > 0 for n >= 11.
(2) Conjecture: A278287(n) > 0 for n >= 11.
Conjecture (1) and conjecture (2) are first and second parts of Goldbach-like conjecture in A001031.

Examples

			a(12) = 2 because 4*(12-0-1)+3 = 47 and 4*0+3 = 3 are primes where 3 < 12 and 4*(12-1-1)+3 = 43 and 4*1+3 = 7 are primes where 7 < 12.
		

Crossrefs

Previous Showing 11-20 of 22 results. Next