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

A256555 Number of ways to write n as the sum of two (unordered) distinct elements of the set {floor(p/3): p is prime}.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Apr 01 2015

Keywords

Comments

Conjecture: For any integer m > 2, every positive integer can be written as the sum of two distinct elements of the set {floor(p/m): p is prime}.
Note that Goldbach's conjecture essentially asserts that any integer n > 1 can be written as floor(p/2) + floor(q/2) with p and q prime.

Examples

			 a(4) = 2 since 4 = 0 + 4 = 1 + 3 with 0,1,3,4 elements of the set {floor(p/3): p is prime}. Note that floor(2/3) = 0, floor(3/3) = 1, floor(11/3) = 3 and floor(13/3) = 4.
		

Crossrefs

Programs

  • Mathematica
    S[n_]:=Union[Table[Floor[Prime[k]/3], {k,1,PrimePi[3n+2]}]]
    L[n_]:=Length[S[n]]
    Do[r=0;Do[If[Part[S[n],x]>=n/2,Goto[cc]];
    If[MemberQ[S[n], n-Part[S[n],x]]==True,r=r+1]; Continue,{x,1,L[n]}];Label[cc];Print[n," ",r];Continue, {n,1,100}]

A256558 Number of ways to write n = p + floor(k*(k+1)/4), where p is a prime and k is a positive integer.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Apr 01 2015

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 1.
(ii) For any integer m > 4 not equal to 12, each integer n > 1 can be written as p + floor((k^2-1)/m), where p is a prime and k is a positive integer.
We also have some other conjectures on representations n = p + floor(k*(k+1)/m) with m > 4.

Examples

			 a(15) = 1 since 15 = 5 + floor(6*7/4) with 5 prime.
a(420) = 1 since 420 = 419 + floor(2*3/4) with 419 prime.
a(945) = 1 since 945 = 877 + floor(16*17/4) with 877 prime.
		

Crossrefs

Programs

  • Mathematica
    Do[r=0;Do[If[PrimeQ[n-Floor[k(k+1)/4]],r=r+1],{k,1,(Sqrt[16n+1]-1)/2}];Print[n," ",r];Continue,{n,1,100}]

A256587 Number of ways to write n = r + s + t, where r,s,t are elements of the set {floor(k*(k+1)/4): k = 1,2,3,...} with s odd and r <= s <= t.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Apr 02 2015

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 1.
(ii) If the ordered pair (b,c) is among (1,2), (1,3), (1,4), (1,5), (1,6), (1,8), (1,9), (2,2) and (2,3), then each nonnegative integer can be written as r + b*s + c*t, where r,s,t belong to the set S = {floor(k*(k+1)/4): k = 1, 2, 3, ...}.
We have shown that if b and c are positive integers with b <= c such that every n = 0,1,2,... can be written as r + b*s + c*t with r,s,t in the above set S, then the ordered pair (b,c) must be among (1,1), (1,2,), (1,3), (1,4), (1,5), (1,6), (1,8), (1,9), (2,2) and (2,3).

Examples

			 a(27) = 1 since 27 = 0 + 5 + 22 = floor(1*2/4) + floor(4*5/4) + floor(9*10/4).
a(56) = 1 since 56 = 1 + 3 + 52 = floor(2*3/4) + floor(3*4/4) + floor(14*15/4).
		

Crossrefs

Programs

  • Mathematica
    S[n_]:=Union[Table[Floor[k*(k+1)/4],{k,1,(Sqrt[16n+13]-1)/2}]]
    L[n_]:=Length[S[n]]
    Do[r=0;Do[If[Part[S[n],x]>n/3,Goto[cc]];Do[If[Part[S[n],x]+2*Part[S[n],y]>n,Goto[bb]];
    If[Mod[Part[S[n],y],2]==1&&MemberQ[S[n], n-Part[S[n],x]-Part[S[n],y]]==True,r=r+1];
    Continue,{y,x,L[n]}];Label[bb];Continue,{x,1,L[n]}];Label[cc];Print[n," ",r];Continue, {n,1,100}]
Showing 1-3 of 3 results.