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

A353847 Composition run-sum transformation in terms of standard composition numbers. The a(k)-th composition in standard order is the sequence of run-sums of the k-th composition in standard order. Takes each index of a row of A066099 to the index of the row consisting of its run-sums.

Original entry on oeis.org

0, 1, 2, 2, 4, 5, 6, 4, 8, 9, 8, 10, 12, 13, 10, 8, 16, 17, 18, 18, 20, 17, 22, 20, 24, 25, 24, 26, 20, 21, 18, 16, 32, 33, 34, 34, 32, 37, 38, 36, 40, 41, 32, 34, 44, 45, 42, 40, 48, 49, 50, 50, 52, 49, 54, 52, 40, 41, 40, 42, 36, 37, 34, 32, 64, 65, 66, 66
Offset: 0

Views

Author

Gus Wiseman, May 30 2022

Keywords

Comments

Every sequence can be uniquely split into a sequence of non-overlapping runs. For example, the runs of (2,2,1,1,1,3,2,2) are ((2,2),(1,1,1),(3),(2,2)), with sums (4,3,3,4).
The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.

Examples

			As a triangle:
   0
   1
   2  2
   4  5  6  4
   8  9  8 10 12 13 10  8
  16 17 18 18 20 17 22 20 24 25 24 26 20 21 18 16
These are the standard composition numbers of the following compositions (transposed):
  ()  (1)  (2)  (3)    (4)      (5)
           (2)  (2,1)  (3,1)    (4,1)
                (1,2)  (4)      (3,2)
                (3)    (2,2)    (3,2)
                       (1,3)    (2,3)
                       (1,2,1)  (4,1)
                       (2,2)    (2,1,2)
                       (4)      (2,3)
                                (1,4)
                                (1,3,1)
                                (1,4)
                                (1,2,2)
                                (2,3)
                                (2,2,1)
                                (3,2)
                                (5)
		

Crossrefs

Standard compositions are listed by A066099.
The version for partitions is A353832.
The run-sums themselves are listed by A353932, with A353849 distinct terms.
A005811 counts runs in binary expansion.
A300273 ranks collapsible partitions, counted by A275870.
A353838 ranks partitions with all distinct run-sums, counted by A353837.
A353851 counts compositions with all equal run-sums, ranked by A353848.
A353840-A353846 pertain to partition run-sum trajectory.
A353852 ranks compositions with all distinct run-sums, counted by A353850.
A353853-A353859 pertain to composition run-sum trajectory.
A353860 counts collapsible compositions.
A353863 counts run-sum-complete partitions.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join@@ Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    stcinv[q_]:=Total[2^(Accumulate[Reverse[q]])]/2;
    Table[stcinv[Total/@Split[stc[n]]],{n,0,100}]

A353850 Number of integer compositions of n with all distinct run-sums.

Original entry on oeis.org

1, 1, 2, 4, 5, 12, 24, 38, 52, 111, 218, 286, 520, 792, 1358, 2628, 4155, 5508, 9246, 13182, 23480, 45150, 54540, 94986, 146016, 213725, 301104, 478586, 851506, 1302234, 1775482, 2696942, 3746894, 6077784, 8194466, 12638334, 21763463, 28423976, 45309850, 62955524, 94345474
Offset: 0

Views

Author

Gus Wiseman, May 31 2022

Keywords

Comments

Every sequence can be uniquely split into a sequence of non-overlapping runs. For example, the runs of (2,2,1,1,1,3,2,2) are ((2,2),(1,1,1),(3),(2,2)), with sums (4,3,3,4).

Examples

			The a(0) = 1 through a(5) = 12 compositions:
  ()  (1)  (2)   (3)    (4)     (5)
           (11)  (12)   (13)    (14)
                 (21)   (22)    (23)
                 (111)  (31)    (32)
                        (1111)  (41)
                                (113)
                                (122)
                                (221)
                                (311)
                                (1112)
                                (2111)
                                (11111)
For n=4, (211) is invalid because the two runs (2) and (11) have the same sum. - _Joseph Likar_, Aug 04 2023
		

Crossrefs

For distinct parts instead of run-sums we have A032020.
For distinct multiplicities instead of run-sums we have A242882.
For distinct run-lengths instead of run-sums we have A329739, ptns A098859.
For runs instead of run-sums we have A351013.
For partitions we have A353837, ranked by A353838 (complement A353839).
For equal instead of distinct run-sums we have A353851, ptns A304442.
These compositions are ranked by A353852.
The weak version (rucksack compositions) is A354580, ranked by A354581.
A003242 counts anti-run compositions, ranked by A333489.
A005811 counts runs in binary expansion.
A011782 counts compositions.
A175413 lists numbers whose binary expansion has all distinct runs.
A351014 counts distinct runs in standard compositions, firsts A351015.
A353847 gives composition run-sum transformation.
A353929 counts distinct runs in binary expansion, firsts A353930.

Programs

  • Mathematica
    Table[Length[Select[Join@@Permutations/@IntegerPartitions[n], UnsameQ@@Total/@Split[#]&]],{n,0,15}]

Extensions

Terms a(21) and onwards from Joseph Likar, Aug 04 2023

A353848 Numbers k such that the k-th composition in standard order (row k of A066099) has all equal run-sums.

Original entry on oeis.org

0, 1, 2, 3, 4, 7, 8, 10, 11, 14, 15, 16, 31, 32, 36, 39, 42, 46, 59, 60, 63, 64, 127, 128, 136, 138, 143, 168, 170, 175, 187, 238, 248, 250, 255, 256, 292, 316, 487, 511, 512, 528, 543, 682, 750, 955, 1008, 1023, 1024, 2047, 2048, 2080, 2084, 2090, 2111, 2184
Offset: 0

Views

Author

Gus Wiseman, May 30 2022

Keywords

Comments

Every sequence can be uniquely split into non-overlapping runs, read left-to-right. For example, the runs of (2,2,1,1,1,3,2,2) are ((2,2),(1,1,1),(3),(2,2)), with sums (4,3,3,4).
The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.

Examples

			The terms together with their binary expansions and corresponding compositions begin:
     0:       0  ()
     1:       1  (1)
     2:      10  (2)
     3:      11  (1,1)
     4:     100  (3)
     7:     111  (1,1,1)
     8:    1000  (4)
    10:    1010  (2,2)
    11:    1011  (2,1,1)
    14:    1110  (1,1,2)
    15:    1111  (1,1,1,1)
    16:   10000  (5)
    31:   11111  (1,1,1,1,1)
    32:  100000  (6)
    36:  100100  (3,3)
    39:  100111  (3,1,1,1)
    42:  101010  (2,2,2)
    46:  101110  (2,1,1,2)
    59:  111011  (1,1,2,1,1)
    60:  111100  (1,1,1,3)
For example:
- The 59th composition in standard order is (1,1,2,1,1), with run-sums (2,2,2), so 59 is in the sequence.
- The 2298th composition in standard order is (4,1,1,1,1,2,2), with run-sums (4,4,4), so 2298 is in the sequence.
- The 2346th composition in standard order is (3,3,2,2,2), with run-sums (6,6), so 2346 is in the sequence.
		

Crossrefs

Standard compositions are listed by A066099.
For equal lengths instead of sums we have A353744, counted by A329738.
The version for partitions is A353833, counted by A304442.
These compositions are counted by A353851.
The distinct instead of equal version is A353852, counted by A353850.
The run-sums themselves are listed by A353932, with A353849 distinct terms.
A005811 counts runs in binary expansion.
A300273 ranks collapsible partitions, counted by A275870.
A351014 counts distinct runs in standard compositions, firsts A351015.
A353840-A353846 pertain to partition run-sum trajectory.
A353847 represents the run-sum transformation for compositions.
A353853-A353859 pertain to composition run-sum trajectory.
A353860 counts collapsible compositions.
A353863 counts run-sum-complete partitions.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join@@ Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    Select[Range[0,100],SameQ@@Total/@Split[stc[#]]&]

Formula

A353849(a(n)) = 1.

A353932 Irregular triangle read by rows where row k lists the run-sums of the k-th composition in standard order.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Jun 10 2022

Keywords

Comments

Every sequence can be uniquely split into a sequence of non-overlapping runs. For example, the runs of (2,2,1,1,1,3,2,2) are ((2,2),(1,1,1),(3),(2,2)), with sums (4,3,3,4).
The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.

Examples

			Triangle begins:
  1
  2
  2
  3
  2 1
  1 2
  3
  4
  3 1
  4
  2 2
  1 3
  1 2 1
For example, composition 350 in standard order is (2,2,1,1,1,2), so row 350 is (4,3,2).
		

Crossrefs

Row-sums are A029837.
Standard compositions are listed by A066099.
Row-lengths are A124767.
These compositions are ranked by A353847.
Row k has A353849(k) distinct parts.
The version for partitions is A354584, ranked by A353832.
A005811 counts runs in binary expansion.
A300273 ranks collapsible partitions, counted by A275870.
A353838 ranks partitions with all distinct run-sums, counted by A353837.
A353851 counts compositions with all equal run-sums, ranked by A353848.
A353840-A353846 pertain to partition run-sum trajectory.
A353852 ranks compositions with all distinct run-sums, counted by A353850.
A353853-A353859 pertain to composition run-sum trajectory.
A353860 counts collapsible compositions.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    Table[Total/@Split[stc[n]],{n,0,30}]

A353852 Numbers k such that the k-th composition in standard order (row k of A066099) has all distinct run-sums.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 15, 16, 17, 18, 19, 20, 21, 23, 24, 26, 28, 30, 31, 32, 33, 34, 35, 36, 37, 38, 40, 41, 42, 43, 44, 47, 48, 50, 51, 52, 55, 56, 57, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 79, 80, 81, 84, 85, 86, 87, 88
Offset: 0

Views

Author

Gus Wiseman, May 31 2022

Keywords

Comments

The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.
Every sequence can be uniquely split into a sequence of non-overlapping runs. For example, the runs of (2,2,1,1,1,3,2,2) are ((2,2),(1,1,1),(3),(2,2)), with sums (4,3,3,4).

Examples

			The terms together with their binary expansions and corresponding compositions begin:
   0:        0  ()
   1:        1  (1)
   2:       10  (2)
   3:       11  (1,1)
   4:      100  (3)
   5:      101  (2,1)
   6:      110  (1,2)
   7:      111  (1,1,1)
   8:     1000  (4)
   9:     1001  (3,1)
  10:     1010  (2,2)
  12:     1100  (1,3)
  15:     1111  (1,1,1,1)
  16:    10000  (5)
  17:    10001  (4,1)
  18:    10010  (3,2)
  19:    10011  (3,1,1)
  20:    10100  (2,3)
  21:    10101  (2,2,1)
  23:    10111  (2,1,1,1)
		

Crossrefs

The version for runs in binary expansion is A175413.
The version for parts instead of run-sums is A233564, counted A032020.
The version for run-lengths instead of run-sums is A351596, counted A329739.
The version for runs instead of run-sums is A351290, counted by A351013.
The version for partitions is A353838, counted A353837, complement A353839.
The equal instead of distinct version is A353848, counted by A353851.
These compositions are counted by A353850.
The weak version (rucksack compositions) is A354581, counted by A354580.
A003242 counts anti-run compositions, ranked by A333489.
A005811 counts runs in binary expansion.
A011782 counts compositions.
A242882 counts composition with distinct multiplicities, partitions A098859.
A304442 counts partitions with all equal run-sums.
A351014 counts distinct runs in standard compositions, firsts A351015.
A353853-A353859 pertain to composition run-sum trajectory.
A353864 counts rucksack partitions, perfect A353865.
A353929 counts distinct runs in binary expansion, firsts A353930.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join@@ Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    Select[Range[0,100],UnsameQ@@Total/@Split[stc[#]]&]

A353851 Number of integer compositions of n with all equal run-sums.

Original entry on oeis.org

1, 1, 2, 2, 5, 2, 8, 2, 12, 5, 8, 2, 34, 2, 8, 8, 43, 2, 52, 2, 70, 8, 8, 2, 282, 5, 8, 18, 214, 2, 386, 2, 520, 8, 8, 8, 1957, 2, 8, 8, 2010, 2, 2978, 2, 3094, 94, 8, 2, 16764, 5, 340, 8, 12310, 2, 26514, 8, 27642, 8, 8, 2, 132938, 2, 8, 238, 107411, 8, 236258
Offset: 0

Views

Author

Gus Wiseman, May 31 2022

Keywords

Comments

Every sequence can be uniquely split into a sequence of non-overlapping runs. For example, the runs of (2,2,1,1,1,3,2,2) are ((2,2),(1,1,1),(3),(2,2)), with sums (4,3,3,4).

Examples

			The a(0) = 1 through a(8) = 12 compositions:
  ()  (1)  (2)   (3)    (4)     (5)      (6)       (7)        (8)
           (11)  (111)  (22)    (11111)  (33)      (1111111)  (44)
                        (112)            (222)                (224)
                        (211)            (1113)               (422)
                        (1111)           (2112)               (2222)
                                         (3111)               (11114)
                                         (11211)              (41111)
                                         (111111)             (111122)
                                                              (112112)
                                                              (211211)
                                                              (221111)
                                                              (11111111)
For example:
  (1,1,2,1,1) has run-sums (2,2,2) so is counted under a(6).
  (4,1,1,1,1,2,2) has run-sums (4,4,4) so is counted under a(12).
  (3,3,2,2,2) has run-sums (6,6) so is counted under a(12).
		

Crossrefs

The version for parts or runs instead of run-sums is A000005.
The version for multiplicities instead of run-sums is A098504.
All parts are divisors of n, see A100346.
The version for partitions is A304442, ranked by A353833.
The version for run-lengths instead of run-sums is A329738, ptns A047966.
These compositions are ranked by A353848.
The distinct instead of equal version is A353850.
A003242 counts anti-run compositions, ranked by A333489.
A005811 counts runs in binary expansion.
A011782 counts compositions.
A353847 represents the composition run-sum transformation.
For distinct instead of equal run-sums: A032020, A098859, A242882, A329739, A351013, A353837, ranked by A353838 (complement A353839), A353852, A354580, ranked by A354581.

Programs

  • Mathematica
    Table[Length[Select[Join@@Permutations/@ IntegerPartitions[n],SameQ@@Total/@Split[#]&]],{n,0,15}]
  • PARI
    a(n) = {if(n <=1, return(1)); my(d = divisors(n), res = 0); for(i = 1, #d, nd = numdiv(d[i]); res+=(nd*(nd-1)^(n/d[i]-1)) ); res } \\ David A. Corneth, Jun 02 2022

Formula

From David A. Corneth, Jun 02 2022 (Start)
a(p) = 2 for prime p.
a(p*q) = 8 for distinct primes p and q (Cf. A006881).
a(n) = Sum_{d|n} tau(d)*(tau(d)-1) ^ (n/d - 1) where tau = A000005. (End)

Extensions

More terms from David A. Corneth, Jun 02 2022

A353849 Number of distinct positive run-sums of the n-th composition in standard order.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, May 30 2022

Keywords

Comments

Every sequence can be uniquely split into a sequence of non-overlapping runs. For example, the runs of (2,2,1,1,1,3,2,2) are ((2,2),(1,1,1),(3),(2,2)), with sums (4,3,3,4).
The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.

Examples

			Composition 462903 in standard order is (1,1,4,7,1,2,1,1,1), with run-sums (2,4,7,1,2,3), of which a(462903) = 5 are distinct.
		

Crossrefs

Counting repeated runs also gives A124767.
Positions of first appearances are A246534.
For distinct runs instead of run-sums we have A351014 (firsts A351015).
A version for partitions is A353835, weak A353861.
Positions of 1's are A353848, counted by A353851.
The version for binary expansion is A353929 (firsts A353930).
The run-sums themselves are listed by A353932, with A353849 distinct terms.
For distinct run-lengths instead of run-sums we have A354579.
A005811 counts runs in binary expansion.
A066099 lists compositions in standard order.
A165413 counts distinct run-lengths in binary expansion.
A297770 counts distinct runs in binary expansion, firsts A350952.
A353847 represents the run-sum transformation for compositions.
A353853-A353859 pertain to composition run-sum trajectory.
Selected statistics of standard compositions:
- Length is A000120.
- Sum is A070939.
- Heinz number is A333219.
- Number of distinct parts is A334028.
Selected classes of standard compositions:
- Partitions are A114994, strict A333256.
- Multisets are A225620, strict A333255.
- Strict compositions are A233564.
- Constant compositions are A272919.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join@@ Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    Table[Length[Union[Total/@Split[stc[n]]]],{n,0,100}]

A353840 Trajectory of the partition run-sum transformation of n, using Heinz numbers.

Original entry on oeis.org

1, 2, 3, 4, 3, 5, 6, 7, 8, 5, 9, 7, 10, 11, 12, 9, 7, 13, 14, 15, 16, 7, 17, 18, 14, 19, 20, 15, 21, 22, 23, 24, 15, 25, 13, 26, 27, 13, 28, 21, 29, 30, 31, 32, 11, 33, 34, 35, 36, 21, 37, 38, 39, 40, 25, 13, 41, 42, 43, 44, 33, 45, 35, 46, 47, 48, 21, 49, 19
Offset: 1

Views

Author

Gus Wiseman, May 25 2022

Keywords

Comments

The Heinz number of a partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k). This gives a bijective correspondence between positive integers and integer partitions.
The run-sum trajectory is obtained by repeatedly taking the run-sum transformation (A353832) until a squarefree number is reached. For example, the trajectory 12 -> 9 -> 7 given in row 12 corresponds to the partitions (2,1,1) -> (2,2) -> (4).
This is the iteration of the transformation f described by Kimberling at A237685.

Examples

			Triangle begins:
   1
   2
   3
   4  3
   5
   6
   7
   8  5
   9  7
  10
  11
  12  9  7
Row 87780 is the following trajectory (left column), with prime indices shown on the right:
  87780: {1,1,2,3,4,5,8}
  65835: {2,2,3,4,5,8}
  51205: {3,4,4,5,8}
  19855: {3,5,8,8}
   2915: {3,5,16}
		

Crossrefs

The version for run-lengths instead of sums is A325239 or A325277.
This is the iteration of A353832, with composition version A353847.
Row-lengths are A353841, counted by A353846.
Final terms are A353842.
Counting rows by final omega gives A353843.
Rows ending in a prime number are A353844, counted by A353845.
These sequences for compositions are A353853-A353859.
A001222 counts prime factors, distinct A001221.
A056239 adds up prime indices, row sums of A112798 and A296150.
A124010 gives prime signature, sorted A118914.
A182850 or A323014 gives frequency depth.
A300273 ranks collapsible partitions, counted by A275870.
A353833 ranks partitions with all equal run-sums, counted by A304442.
A353835 counts distinct run-sums of prime indices, weak A353861.
A353838 ranks partitions with all distinct run-sums, counted by A353837.
A353862 gives greatest run-sum of prime indices, least A353931.

Programs

  • Mathematica
    Table[NestWhileList[Times@@Prime/@Cases[FactorInteger[#],{p_,k_}:>PrimePi[p]*k]&,n,Not@*SquareFreeQ],{n,30}]

A353859 Triangle read by rows where T(n,k) is the number of integer compositions of n with composition run-sum trajectory of length k.

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 3, 1, 0, 0, 4, 2, 2, 0, 0, 7, 7, 2, 0, 0, 0, 14, 14, 4, 0, 0, 0, 0, 23, 29, 12, 0, 0, 0, 0, 0, 39, 56, 25, 8, 0, 0, 0, 0, 0, 71, 122, 53, 10, 0, 0, 0, 0, 0, 0, 124, 246, 126, 16, 0, 0, 0, 0, 0, 0, 0, 214, 498, 264, 48, 0, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Gus Wiseman, Jun 02 2022

Keywords

Comments

Every sequence can be uniquely split into a sequence of non-overlapping runs. For example, the runs of (2,2,1,1,1,3,2,2) are ((2,2),(1,1,1),(3),(2,2)), with sums (4,3,3,4). The run-sum trajectory is obtained by repeatedly taking the run-sums transformation (or condensation, represented by A353847) until an anti-run is reached. For example, the trajectory (2,4,2,1,1) -> (2,4,2,2) -> (2,4,4) -> (2,8) is counted under T(10,4).

Examples

			Triangle begins:
   1
   0   1
   0   1   1
   0   3   1   0
   0   4   2   2   0
   0   7   7   2   0   0
   0  14  14   4   0   0   0
   0  23  29  12   0   0   0   0
   0  39  56  25   8   0   0   0   0
   0  71 122  53  10   0   0   0   0   0
   0 124 246 126  16   0   0   0   0   0   0
   0 214 498 264  48   0   0   0   0   0   0   0
For example, row n = 5 counts the following compositions:
  (5)    (113)    (1121)
  (14)   (122)    (1211)
  (23)   (221)
  (32)   (311)
  (41)   (1112)
  (131)  (2111)
  (212)  (11111)
		

Crossrefs

Column k = 1 is A003242, ranked by A333489, complement A261983.
Row sums are A011782.
Positive row-lengths are A070939.
The version for partitions is A353846, ranked by A353841.
This statistic (trajectory length) is ranked by A353854, firsts A072639.
Counting by length of last part instead of number of parts gives A353856.
A333627 ranks the run-lengths of standard compositions.
A353847 represents the run-sums of a composition, partitions A353832.
A353853-A353859 pertain to composition run-sum trajectory.
A353932 lists run-sums of standard compositions.

Programs

  • Mathematica
    rsc[y_]:=If[y=={},{},NestWhileList[Total/@Split[#]&,y,MatchQ[#,{_,x_,x_,_}]&]];
    Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],Length[rsc[#]]==k&]],{n,0,10},{k,0,n}]

A353860 Number of collapsible integer compositions of n.

Original entry on oeis.org

0, 1, 2, 2, 5, 2, 12, 2, 26, 9, 36, 2, 206, 2, 132, 40, 677, 2, 1746, 2, 3398, 136, 2052, 2, 44388, 33, 8196, 730, 79166, 2, 263234, 2, 458330, 2056, 131076, 160, 8804349, 2, 524292, 8200, 13662156, 2, 36036674, 2, 48844526, 90282, 8388612, 2, 1971667502, 129
Offset: 0

Views

Author

Gus Wiseman, Jun 04 2022

Keywords

Comments

If a collapse is a joining of some number of adjacent equal parts of an integer composition, we call a composition collapsible iff by some sequence of collapses it can be reduced to a single part. An example of such a sequence of collapses is (1,1,1,3,2,1,1,2) -> (3,3,2,1,1,2) -> (3,3,2,2,2) -> (6,2,2,2) -> (6,6) -> (12), which shows that (1,1,1,3,2,1,1,2) is a collapsible composition of 12.

Examples

			The a(0) = 0 through a(6) = 12 compositions:
  .  (1)  (2)   (3)    (4)     (5)      (6)
          (11)  (111)  (22)    (11111)  (33)
                       (112)            (222)
                       (211)            (1113)
                       (1111)           (1122)
                                        (2112)
                                        (2211)
                                        (3111)
                                        (11112)
                                        (11211)
                                        (21111)
                                        (111111)
		

Crossrefs

The version for partitions is A275870, ranked by A300273.
A003242 counts anti-run compositions, ranked by A333489, complement A261983.
A011782 counts compositions.
A353847 represents the run-sums of a composition, partitions A353832.
A353853-A353859 pertain to composition run-sum trajectory.
A353932 lists run-sums of standard compositions.

Programs

  • Mathematica
    repcams[q_List]:=repcams[q]=Union[{q},If[UnsameQ@@q,{},Union@@repcams/@ Union[Insert[Drop[q,#],Plus@@Take[q,#],First[#]]&/@ Select[Tuples[Range[Length[q]],2],And[Less@@#,SameQ@@Take[q,#]]&]]]];
    Table[Length[Select[Join@@Permutations/@ IntegerPartitions[n],MemberQ[repcams[#],{n}]&]],{n,0,15}]
  • PARI
    a(n) = if(n==0, 0, 1 - sumdiv(n, d, if(d>1, moebius(d)*a(n/d)^d ))) \\ Andrew Howroyd, Feb 04 2023

Formula

Sum_{d|n} mu(d)*a(n/d)^d = 1 for n > 0. - Andrew Howroyd, Feb 04 2023

Extensions

Terms a(16) and beyond from Andrew Howroyd, Feb 04 2023
Showing 1-10 of 33 results. Next