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-10 of 14 results. Next

A025512 Index of n-th 2 in A022300.

Original entry on oeis.org

3, 5, 8, 11, 13, 14, 16, 19, 22, 23, 25, 26, 28, 31, 33, 34, 37, 40, 41, 43, 44, 46, 49, 52, 53, 55, 58, 60, 61, 64, 67, 68, 70, 71, 73, 76, 78, 79, 82, 85, 87, 88, 90, 91, 94, 96, 97, 99, 102, 103, 105, 106, 109, 112, 114, 115, 117, 118, 121, 123, 124, 126, 129, 132, 133, 135
Offset: 1

Views

Author

Keywords

Programs

  • Maple
    N:= 10^3: # to get all terms <= N
    B:= Vector(N):
    B[1..4]:= <1,1,2,1>:
    m:= 4: t:= 2:
    for n from 1 while m < N do
      t:= 3-t;
      B[m]:= t;
      if B[n] = 2 and m+1 < N then
         B[m+1]:= t; m:= m+2
      else m:= m+1
      fi
    od:
    select(t -> B[t]=2, [$1..N]); # Robert Israel, Nov 02 2016

A025513 Exactly half of first a(n) terms of A022300 are 1's (not known to be infinite).

Original entry on oeis.org

5904, 5986, 6050, 6068, 6074, 6076, 6078, 6080, 6084, 6086, 6092, 6094, 6096, 6098, 6100, 6102, 6104, 6106, 6108, 6114, 6116, 6118, 6120, 6124, 6126, 6136, 6138, 6142, 6144, 6146, 6148, 6154, 6156, 6158, 6160, 6162, 6164, 6166, 6168, 6170, 6174, 6176
Offset: 1

Views

Author

Keywords

Comments

Even numbers n such that A025512(n/2) <= n and A025512(n/2+1) > n. - Robert Israel, Nov 02 2016

Crossrefs

Programs

  • Maple
    N:= 10000: # to use A022300(1..N)
    B:= Vector(N):
    B[1..4]:= <1,1,2,1>:
    m:= 4: t:= 2:
    for n from 1 while m < N do
      t:= 3-t;
      B[m]:= t;
      if B[n] = 2 and m+1 < N then
         B[m+1]:= t; m:= m+2
      else m:= m+1
      fi
    od:
    S:= ListTools:-PartialSums(convert(B,list)):
    select(t -> S[t] = 3/2*t, [$1..nops(S)]); # Robert Israel, Nov 02 2016

A022301 Index of n-th 1 in A022300.

Original entry on oeis.org

1, 2, 4, 6, 7, 9, 10, 12, 15, 17, 18, 20, 21, 24, 27, 29, 30, 32, 35, 36, 38, 39, 42, 45, 47, 48, 50, 51, 54, 56, 57, 59, 62, 63, 65, 66, 69, 72, 74, 75, 77, 80, 81, 83, 84, 86, 89, 92, 93, 95, 98, 100
Offset: 0

Views

Author

Keywords

A022302 Least k such that first k terms of A022300 contain n more 1's than 2's.

Original entry on oeis.org

1, 2, 7, 10, 21, 66, 213, 246, 273, 454, 673, 700, 727, 934, 2451, 2766, 2799, 3006, 3099, 3396, 234665, 234758, 234977, 235004, 235013, 434216, 436951, 436978, 437005, 437128, 437155, 437708, 437735, 437762, 438017, 438044, 438145, 438314, 438341
Offset: 0

Views

Author

Keywords

A025515 Least k such that first k terms of A022300 contain n more 2's than 1's.

Original entry on oeis.org

6077, 6110, 6131, 6386, 6413, 7160, 7361, 8436, 8975, 9008, 9071, 11626, 11653, 11822, 11849, 11876, 12545, 12714, 12741, 12768, 13019, 13118, 13145, 13172, 13277, 13358, 16661, 26214, 26241, 26268, 26475, 51382, 51639, 51786, 52173, 52466, 52753
Offset: 1

Views

Author

Keywords

A022303 The sequence a of 1's and 2's starting with (1,2,1) such that a(n) is the length of the (n+2)nd run of a.

Original entry on oeis.org

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

Views

Author

Keywords

Examples

			a(1) =1, so the 3rd run has length 1, so a(4) must be 2.
a(2) = 2, so the 4th run has length 2, so a(5) = 2 and a(6) = 1.
a(3) = 1, so the 5th run has length 1, so a(7) = 2.
a(4) = 2, so the 6th run has length 2, so a(8) = 1 and a(9) = 1.
Globally, the runlength sequence of a is 1,1,1,2,1,2,2,1,2,2,1,1,2,1,...., and deleting the first two terms leaves a = A022303.
		

Crossrefs

Programs

  • Mathematica
    a = {1, 2}; Do[a = Join[a, ConstantArray[If[Last[a] == 1, 2, 1], {a[[n]]}]], {n, 100}]; a (* Peter J. C. Moses, Apr 02 2016 *)

Extensions

Clarified and augmented by Clark Kimberling, Apr 02 2016

A270641 The sequence a of 1's and 2's starting with (1,1,1,1) such that a(n) is the length of the (n+1)st run of a.

Original entry on oeis.org

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

Views

Author

Clark Kimberling, Apr 05 2016

Keywords

Comments

Guide to related sequences (with adjustments for initial terms):
1, 1, 1, 1; a(n) = length of (n + 1)st run of a; A270641
1, 1, 1, 2; a(n) = length of (n + 2)nd run of a; A270641
1, 1, 2, 1; a(n) = length of (n + 3)rd run of a; A270641
1, 1, 2, 2; a(n) = length of (n + 2)nd run of a; A270642
1, 2, 1, 1; a(n) = length of (n + 3)rd run of a; A022300
1, 2, 1, 2; a(n) = length of (n + 4)th run of a; A270641
1, 2, 2, 1; a(n) = length of (n + 3)rd run of a; A270643
1, 2, 2, 2; a(n) = length of (n + 2)nd run of a; A270644
2, 1, 1, 1; a(n) = length of (n + 2)nd run of a; A270645
2, 1, 1, 2; a(n) = length of (n + 3)rd run of a; A222300
2, 1, 2, 1; a(n) = length of (n + 4)th run of a; A270641
2, 1, 2, 2; a(n) = length of (n + 3)rd run of a; A000002 (Kolakoski)
2, 2, 1, 1; a(n) = length of (n + 2)nd run of a; A270646
2, 2, 1, 2; a(n) = length of (n + 3)rd run of a; A270647
2, 2, 2, 1; a(n) = length of (n + 2)nd run of a; A270644
2, 2, 2, 2; a(n) = length of (n + 1)st run of a; A270648

Examples

			a(1) = 1, so the 2nd run has length 1, so a(5) must be 2 and a(6) = 1.
a(2) = 1, so the 3rd run has length 1, so a(7) = 2.
a(3) = 1, so the 4th run has length 1, so a(8) = 1.
a(4) = 1, so the 5th run has length 1, so a(9) = 2.
a(5) = 2, so the 6th run has length 2, so a(10) = 2 and a(11) = 1.
Globally, the runlength sequence of a is 4,1,1,1,1,2,1,2,1,2,2,1,...., and deleting the first term leaves a = A270641.
		

Crossrefs

Programs

  • Mathematica
    a = {1, 1, 1, 1};
    Do[a = Join[a, ConstantArray[If[Last[a] == 1, 2, 1], {a[[n]]}]], {n,   200}]; a
    (* Peter J. C. Moses, Apr 01 2016 *)

A270642 The sequence a of 1's and 2's starting with (1,1,2,2) such that a(n) is the length of the (n+2)nd run of a.

Original entry on oeis.org

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

Views

Author

Clark Kimberling, Apr 06 2016

Keywords

Comments

See A270641 for a guide to related sequences.

Examples

			a(1) = 1, so the 3rd run has length 1, so a(5) must be 1.
a(2) = 1, so the 4th run has length 1, so a(6) = 2 and a(7) = 1.
a(3) = 2, so the 5th run has length 2, so a(8) = 1 and a(9) = 2.
a(4) = 2, so the 6th run has length 2, so a(10) = 2 and a(11) = 1.
Globally, the runlength sequence is 2,2,1,1,2,2,1,2,1,1,2,2,1,2,..., and deleting the first 2 terms leaves the same sequence.
		

Crossrefs

Programs

  • Mathematica
    a = {1, 1, 2, 2}; Do[a = Join[a, ConstantArray[If[Last[a] == 1, 2, 1], {a[[n]]}]], {n,   200}]; a  (* Peter J. C. Moses, Apr 01 2016 *)

A270643 The sequence a of 1's and 2's starting with (1,2,2,1) such that a(n) is the length of the (n+3)rd run of a.

Original entry on oeis.org

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

Views

Author

Clark Kimberling, Apr 06 2016

Keywords

Comments

See A270641 for a guide to related sequences.

Examples

			a(1) = 1, so the 4th run has length 1, so a(5) must be 1 and a(6) must be 2.
a(2) = 2, so the 5th run has length 2, so a(7) = 1 and a(8) = 2.
a(3) = 2, so the 6th run has length 2, so a(9) = 2 and a(10) = 1.
Globally, the runlength sequence is 1,2,1,1,2,2,1,2,1,1,2,2,1,2,2,1,...., and deleting the first 3 terms leaves the same sequence.
		

Crossrefs

Programs

  • Mathematica
    a = {1, 2, 2, 1}; Do[a = Join[a, ConstantArray[If[Last[a] == 1, 2, 1], {a[[n]]}]], {n,   200}]; a  (* Peter J. C. Moses, Apr 01 2016 *)

Formula

Conjecture: a(n) = A270642(n+1). - R. J. Mathar, Jun 21 2025

A270644 The sequence a of 1's and 2's starting with (1,2,2,2) such that a(n) is the length of the (n+2)nd run of a.

Original entry on oeis.org

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

Views

Author

Clark Kimberling, Apr 06 2016

Keywords

Comments

See A270641 for a guide to related sequences.

Examples

			a(1) = 1, so the 3rd run has length 1, so a(5) must be 1 and a(6) = 2.
a(2) = 2, so the 4th run has length 2, so a(7) = 2 and a(8) = 1.
a(3) = 2, so the 5th run has length 2, so a(9) = 1and a(10) = 2.
Globally, the runlength sequence is 1,3,1,2,2,2,1,2,2,1,1,2,2,1,2,2,..., and deleting the first 2 terms leaves the same sequence.
		

Crossrefs

Programs

  • Mathematica
    a = {1, 2, 2, 2}; Do[a = Join[a, ConstantArray[If[Last[a] == 1, 2, 1], {a[[n]]}]], {n,   200}]; a  (* Peter J. C. Moses, Apr 01 2016 *)
Showing 1-10 of 14 results. Next