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.

A335279 Positions of first appearances in A124771 = number of distinct contiguous subsequences of compositions in standard order.

Original entry on oeis.org

0, 1, 3, 5, 11, 15, 23, 27, 37, 47, 55, 107, 111, 119, 155, 215, 223, 239, 411, 431, 471, 479, 495, 549, 631, 943, 951, 959, 991, 1647, 1887, 1967, 1983, 2015, 2543, 2935, 3703, 3807, 3935, 3967, 4031, 6639, 6895, 7407, 7871, 7903, 8063, 8127, 10207, 13279
Offset: 1

Views

Author

Gus Wiseman, Jun 03 2020

Keywords

Examples

			The sequence together with the corresponding compositions begins:
     0: ()                215: (1,2,2,1,1,1)
     1: (1)               223: (1,2,1,1,1,1,1)
     3: (1,1)             239: (1,1,2,1,1,1,1)
     5: (2,1)             411: (1,3,1,2,1,1)
    11: (2,1,1)           431: (1,2,2,1,1,1,1)
    15: (1,1,1,1)         471: (1,1,2,2,1,1,1)
    23: (2,1,1,1)         479: (1,1,2,1,1,1,1,1)
    27: (1,2,1,1)         495: (1,1,1,2,1,1,1,1)
    37: (3,2,1)           549: (4,3,2,1)
    47: (2,1,1,1,1)       631: (3,1,1,2,1,1,1)
    55: (1,2,1,1,1)       943: (1,1,2,2,1,1,1,1)
   107: (1,2,2,1,1)       951: (1,1,2,1,2,1,1,1)
   111: (1,2,1,1,1,1)     959: (1,1,2,1,1,1,1,1,1)
   119: (1,1,2,1,1,1)     991: (1,1,1,2,1,1,1,1,1)
   155: (3,1,2,1,1)      1647: (1,3,1,2,1,1,1,1)
The subsequences for n = 0, 1, 3, 5, 11, 15, 23, 27 are the following (0 = empty partition):
  0  0  0   0   0    0     0     0     0    0
     1  1   1   1    1     1     1     1    1
        11  2   2    11    2     2     2    2
            21  11   111   11    11    3    11
                21   1111  21    12    21   21
                211        111   21    32   111
                           211   121   321  211
                           2111  211        1111
                                 1211       2111
                                            21111
		

Crossrefs

Positions of first appearances in A124771.
Compositions where every subinterval has a different sum are A333222.
Knapsack compositions are A333223.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    seq=Table[Length[Union[ReplaceList[stc[n],{_,s___,_}:>{s}]]],{n,0,1000}];
    Table[Position[seq,i][[1,1]]-1,{i,First/@Gather[seq]}]