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

A358618 First differences of A258036.

Original entry on oeis.org

2, 2, 2, 2, 2, 3, 2, 2, 2, 2, 3, 2, 2, 2, 2, 2, 3, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2
Offset: 1

Views

Author

Keywords

Comments

Conjecture: All terms belong to {1, 2, 3}. See third comment in A258036.

Crossrefs

Programs

  • Maple
    P:= :
    S:= NULL: count:= 0:
    for i from 2 while count < 101 do
      P:= P[2..-1] - P[1..-2];
      if P[1] < 0 then S:= S,i; count:= count+1; fi;
    od:
    S:= [S]:
    S[2..-1]-S[1..-2]; # Robert Israel, Dec 21 2022
  • Mathematica
    nn = 210; p = Prime@ Range@ nn; t = Table[ Differences[p, n][[1]], {n, 0, nn - 1}]; s = Select[ Range@ nn, t[[#]] < 0 &]; d = Differences@ s

A258037 Numbers k such that D(prime(k), k-1) > 0, where D( * , k-1) = (k-1)-st difference.

Original entry on oeis.org

1, 2, 3, 5, 7, 9, 11, 13, 15, 16, 18, 20, 22, 24, 26, 27, 29, 31, 33, 35, 37, 39, 40, 42, 44, 46, 49, 51, 53, 55, 57, 59, 61, 63, 65, 67, 69, 71, 73, 75, 77, 79, 81, 83, 85, 87, 89, 91, 93, 95, 97, 100, 102, 104, 106, 108, 110, 112, 113, 115, 117, 119, 121
Offset: 1

Views

Author

Clark Kimberling, Jun 05 2015

Keywords

Comments

Partition of the positive integers: A258036, A258037;
Corresponding partition of the primes: A258038, A258039.
Conjecture: all the terms of the difference sequence of A258037 belong to {1,2,3}.

Examples

			D(prime(2), 1) = 3 - 2 > 0, so a(1) = 1;
D(prime(3), 2) = 5 - 2*3 + 2 > 0, so a(2) = 2;
D(prime(4), 3) = 7 - 3*5 + 3*3 - 2 < 0;
		

Crossrefs

Programs

  • Mathematica
    u = Table[Prime[Range[k]], {k, 1, 1000}];
    v = Flatten[Table[Sign[Differences[u[[k]], k - 1]], {k, 1, 100}]];
    w1 = Flatten[Position[v, -1]] (* A258036 *)
    w2 = Flatten[Position[v, 1]]  (* A258037 *)
    p1 = Prime[w1]  (* A258038 *)
    p2 = Prime[w2]  (* A258039 *)
  • PARI
    is(k) = {my(p=primes(k));sum(i=0,k-1,(-1)^i*p[k-i]*binomial(k-1,i))>0} \\ Jason Yuen, Nov 13 2024

Formula

D(prime(k), k-1) = Sum_{i=0..k-1} (-1)^i*prime(k-i)*binomial(k-1,i). [corrected by Jason Yuen, Nov 13 2024]

A258038 Numbers prime(k) such that D(prime(k), k-1) < 0, where D( * , k-1) = (k-1)-st difference.

Original entry on oeis.org

7, 13, 19, 29, 37, 43, 59, 67, 73, 83, 97, 107, 113, 131, 139, 151, 163, 179, 191, 197, 211, 223, 229, 239, 251, 263, 271, 281, 293, 311, 317, 337, 349, 359, 373, 383, 397, 409, 421, 433, 443, 457, 463, 479, 491, 503, 521, 523, 547, 563, 571, 587, 599, 607
Offset: 1

Views

Author

Clark Kimberling, Jun 05 2015

Keywords

Comments

Partition of the positive integers: A258036, A258037;
Corresponding partition of the primes: A258038, A258039.

Examples

			D(prime(2), 1) = 3 - 2 > 0;
D(prime(3), 2) = 5 - 2*3 + 2 > 0;
D(prime(4), 3) = 7 - 3*5 + 3*3 - 2 < 0, so a(1) = prime(4) = 7;
		

Crossrefs

Programs

  • Mathematica
    u = Table[Prime[Range[k]], {k, 1, 1000}];
    v = Flatten[Table[Sign[Differences[u[[k]], k - 1]], {k, 1, 100}]];
    w1 = Flatten[Position[v, -1]] (* A258036 *)
    w2 = Flatten[Position[v, 1]]  (* A258037 *)
    p1 = Prime[w1]  (* A258038 *)
    p2 = Prime[w2]  (* A258039 *)

Formula

D(prime(k), k-1) = Sum_{i=0..k-1} (-1)^i*prime(k-i)*binomial(k-1,i). [corrected by Jason Yuen, Nov 13 2024]
a(n) = prime(A258036(n)). - Jason Yuen, Nov 13 2024

A258039 Numbers prime(k) such that D(prime(k), k-1) > 0, where D( * , k-1) = (k-1)-st difference.

Original entry on oeis.org

2, 3, 5, 11, 17, 23, 31, 41, 47, 53, 61, 71, 79, 89, 101, 103, 109, 127, 137, 149, 157, 167, 173, 181, 193, 199, 227, 233, 241, 257, 269, 277, 283, 307, 313, 331, 347, 353, 367, 379, 389, 401, 419, 431, 439, 449, 461, 467, 487, 499, 509, 541, 557, 569, 577
Offset: 1

Views

Author

Clark Kimberling, Jun 05 2015

Keywords

Comments

Partition of the positive integers: A258036, A258037;
Corresponding partition of the primes: A258038, A258039.

Examples

			D(prime(2), 1) = 3 - 2 > 0, so a(1) = prime(1) = 2;
D(prime(3), 2) = 5 - 2*3 + 2 > 0, so a(2) = prime(2) = 3;
D(prime(4), 3) = 7 - 3*5 + 3*3 - 2 < 0.
		

Crossrefs

Programs

  • Mathematica
    u = Table[Prime[Range[k]], {k, 1, 1000}];
    v = Flatten[Table[Sign[Differences[u[[k]], k - 1]], {k, 1, 100}]];
    w1 = Flatten[Position[v, -1]] (* A258036 *)
    w2 = Flatten[Position[v, 1]]  (* A258037 *)
    p1 = Prime[w1]  (* A258038 *)
    p2 = Prime[w2]  (* A258039 *)

Formula

D(prime(k), k-1) = Sum_{i=0..k-1} (-1)^i*prime(k-i)*binomial(k-1,i). [corrected by Jason Yuen, Nov 13 2024]
a(n) = prime(A258037(n)). - Jason Yuen, Nov 13 2024
Showing 1-4 of 4 results.