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

A239455 Number of Look-and-Say partitions of n; see Comments.

Original entry on oeis.org

0, 1, 2, 2, 4, 5, 7, 10, 13, 16, 21, 28, 33, 45, 55, 65, 83, 105, 121, 155, 180, 217, 259, 318, 362, 445, 512, 614, 707, 850, 958, 1155, 1309, 1543, 1754, 2079, 2327, 2740, 3085, 3592, 4042, 4699, 5253, 6093, 6815, 7839, 8751, 10069, 11208, 12832, 14266, 16270
Offset: 0

Views

Author

Keywords

Comments

Suppose that p = x(1) >= x(2) >= ... >= x(k) is a partition of n. Let y(1) > y(2) > ... > y(h) be the distinct parts of p, and let m(i) be the multiplicity of y(i) for 1 <= i <= h. Then we can "look" at p as "m(1) y(1)'s and m(2) y(2)'s and ... m(h) y(h)'s". Reversing the m's and y's, we can then "say" the Look-and-Say partition of p, denoted by LS(p). The name "Look-and-Say" follows the example of Look-and-Say integer sequences (e.g., A005150). As p ranges through the partitions of n, LS(p) ranges through all the Look-and-Say partitions of n. The number of these is A239455(n).
The Look-and-Say array is distinct from the Wilf array, described at A098859; for example, the number of Look-and-Say partitions of 9 is A239455(9) = 16, whereas the number of Wilf partitions of 9 is A098859(9) = 15. The Look-and-Say partition of 9 which is not a Wilf partition of 9 is [2,2,2,1,1,1].
Conjecture: a partition is Look-and-Say iff it has a permutation with all distinct run-lengths. For example, the partition y = (2,2,2,1,1,1) has the permutation (2,2,1,1,1,2), with run-lengths (2,3,1), which are all distinct, so y is counted under a(9). - Gus Wiseman, Aug 11 2025
Also the number of integer partitions y of n such that there is a pairwise disjoint way to choose a strict integer partition of each multiplicity (or run-length) of y. - Gus Wiseman, Aug 11 2025

Examples

			The 11 partitions of 6 generate 7 Look-and-Say partitions as follows:
6 -> 111111
51 -> 111111
42 -> 111111
411 -> 21111
33 -> 222
321 -> 111111
3111 -> 3111
222 -> 33
2211 -> 222
21111 -> 411
111111 -> 6,
so that a(6) counts these 7 partitions: 111111, 21111, 222, 3111, 33, 411, 6.
		

Crossrefs

These include all Wilf partitions, counted by A098859, ranked by A130091.
These partitions are listed by A239454 in graded reverse-lex order.
Non-Wilf partitions are counted by A336866, ranked by A130092.
A variant for runs is A351204, complement A351203.
The complement is counted by A351293, apparently ranked by A351295, conjugate A381433.
These partitions appear to be ranked by A351294, conjugate A381432.
The non-Wilf case is counted by A351592.
For normal multisets we appear to have A386580, complement A386581.
A000110 counts set partitions, ordered A000670.
A000569 = graphical partitions, complement A339617.
A003242 and A335452 count anti-runs, ranks A333489, patterns A005649.
A181819 = Heinz number of the prime signature of n (prime shadow).
A279790 counts disjoint families on strongly normal multisets.
A329738 = compositions with all equal run-lengths.
A386583 counts separable partitions, sums A325534, ranks A335433.
A386584 counts inseparable partitions, sums A325535, ranks A335448.
A386585 counts separable type partitions, sums A336106, ranks A335127.
A386586 counts inseparable type partitions, sums A386638 or A025065, ranks A335126.
Counting words with all distinct run-lengths:
- A032020 = binary expansions, for runs A351018, ranked by A044813.
- A329739 = compositions, for runs A351013, ranked by A351596.
- A351017 = binary words, for runs A351016.
- A351292 = patterns, for runs A351200.

Programs

  • Mathematica
    LS[part_List] := Reverse[Sort[Flatten[Map[Table[#[[2]], {#[[1]]}] &, Tally[part]]]]]; LS[n_Integer] := #[[Reverse[Ordering[PadRight[#]]]]] &[DeleteDuplicates[Map[LS, IntegerPartitions[n]]]]; TableForm[t = Map[LS[#] &, Range[10]]](*A239454,array*)
    Flatten[t](*A239454,sequence*)
    Map[Length[LS[#]] &, Range[25]](*A239455*)
    (* Peter J. C. Moses, Mar 18 2014 *)
    disjointFamilies[y_]:=Select[Tuples[IntegerPartitions/@Length/@Split[y]],UnsameQ@@Join@@#&];
    Table[Length[Select[IntegerPartitions[n],Length[disjointFamilies[#]]>0&]],{n,0,10}] (* Gus Wiseman, Aug 11 2025 *)

A351293 Number of non-Look-and-Say partitions of n. Number of integer partitions of n such that there is no way to choose a disjoint strict integer partition of each multiplicity.

Original entry on oeis.org

0, 0, 0, 1, 1, 2, 4, 5, 9, 14, 21, 28, 44, 56, 80, 111, 148, 192, 264, 335, 447, 575, 743, 937, 1213, 1513, 1924, 2396, 3011, 3715, 4646, 5687, 7040, 8600, 10556, 12804, 15650, 18897, 22930, 27593, 33296, 39884, 47921, 57168, 68360, 81295, 96807, 114685
Offset: 0

Views

Author

Gus Wiseman, Feb 16 2022

Keywords

Comments

First differs from A336866 (non-Wilf partitions) at a(9) = 14, A336866(9) = 15, the difference being the partition (2,2,2,1,1,1).
See A239455 for the definition of Look-and-Say partitions.

Examples

			The a(3) = 1 through a(9) = 14 partitions:
  (21)  (31)  (32)  (42)    (43)    (53)     (54)
              (41)  (51)    (52)    (62)     (63)
                    (321)   (61)    (71)     (72)
                    (2211)  (421)   (431)    (81)
                            (3211)  (521)    (432)
                                    (3221)   (531)
                                    (3311)   (621)
                                    (4211)   (3321)
                                    (32111)  (4221)
                                             (4311)
                                             (5211)
                                             (32211)
                                             (42111)
                                             (321111)
		

Crossrefs

The complement is counted by A239455, ranked by A351294.
These are all non-Wilf partitions (counted by A336866, ranked by A130092).
A variant for runs is A351203, complement A351204, ranked by A351201.
These partitions appear to be ranked by A351295.
Non-Wilf partitions in the complement are counted by A351592.
A000569 = graphical partitions, complement A339617.
A032020 = number of binary expansions with all distinct run-lengths.
A044813 = numbers whose binary expansion has all distinct run-lengths.
A098859 = Wilf partitions (distinct multiplicities), ranked by A130091.
A181819 = Heinz number of the prime signature of n (prime shadow).
A329738 = compositions with all equal run-lengths.
A329739 = compositions with all distinct run-lengths, for all runs A351013.
A351017 = binary words with all distinct run-lengths, for all runs A351016.
A351292 = patterns with all distinct run-lengths, for all runs A351200.

Programs

  • Mathematica
    disjointFamilies[y_]:=Select[Tuples[IntegerPartitions/@Length/@Split[y]],UnsameQ@@Join@@#&];
    Table[Length[Select[IntegerPartitions[n],Length[disjointFamilies[#]]==0&]],{n,0,15}] (* Gus Wiseman, Aug 13 2025 *)

Formula

a(n) = A000041(n) - A239455(n).

Extensions

Edited by Gus Wiseman, Aug 12 2025

A351013 Number of integer compositions of n with all distinct runs.

Original entry on oeis.org

1, 1, 2, 4, 7, 14, 26, 48, 88, 161, 294, 512, 970, 1634, 2954, 5156, 9119, 15618, 27354, 46674, 80130, 138078, 232286, 394966, 665552, 1123231, 1869714, 3146410, 5186556, 8620936, 14324366, 23529274, 38564554, 63246744, 103578914, 167860584, 274465845
Offset: 0

Views

Author

Gus Wiseman, Feb 09 2022

Keywords

Examples

			The a(1) = 1 through a(5) = 14 compositions:
  (1)  (2)    (3)      (4)        (5)
       (1,1)  (1,2)    (1,3)      (1,4)
              (2,1)    (2,2)      (2,3)
              (1,1,1)  (3,1)      (3,2)
                       (1,1,2)    (4,1)
                       (2,1,1)    (1,1,3)
                       (1,1,1,1)  (1,2,2)
                                  (2,2,1)
                                  (3,1,1)
                                  (1,1,1,2)
                                  (1,1,2,1)
                                  (1,2,1,1)
                                  (2,1,1,1)
                                  (1,1,1,1,1)
For example, the composition c = (3,1,1,1,1,2,1,1,3,4,1,1) has runs (3), (1,1,1,1), (2), (1,1), (3), (4), (1,1), and since (3) and (1,1) both appear twice, c is not counted under a(20).
		

Crossrefs

The version for run-lengths instead of runs is A329739, normal A329740.
These compositions are ranked by A351290, complement A351291.
A000005 counts constant compositions, ranked by A272919.
A005811 counts runs in binary expansion.
A011782 counts integer compositions.
A059966 counts binary Lyndon compositions, necklaces A008965, aperiodic A000740.
A116608 counts compositions by number of distinct parts.
A238130 and A238279 count compositions by number of runs.
A242882 counts compositions with distinct multiplicities.
A297770 counts distinct runs in binary expansion.
A325545 counts compositions with distinct differences.
A329744 counts compositions by runs-resistance.
A351014 counts distinct runs in standard compositions.
Counting words with all distinct runs:
- A351016 = binary words, for run-lengths A351017.
- A351018 = binary expansions, for run-lengths A032020, ranked by A175413.
- A351200 = patterns, for run-lengths A351292.
- A351202 = permutations of prime factors.

Programs

  • Mathematica
    Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],UnsameQ@@Split[#]&]],{n,0,10}]
  • PARI
    \\ here LahI is A111596 as row polynomials.
    LahI(n,y) = {sum(k=1, n, y^k*(-1)^(n-k)*(n!/k!)*binomial(n-1, k-1))}
    S(n) = {my(p=prod(k=1, n, 1 + y*x^k + O(x*x^n))); 1 + sum(i=1, (sqrtint(8*n+1)-1)\2, polcoef(p,i,y)*LahI(i,y))}
    seq(n)={my(q=S(n)); [subst(serlaplace(p),y,1) | p<-Vec(prod(k=1, n, subst(q + O(x*x^(n\k)), x, x^k)))]} \\ Andrew Howroyd, Feb 12 2022

Extensions

Terms a(26) and beyond from Andrew Howroyd, Feb 12 2022

A175413 Those positive integers n that when written in binary, the lengths of the runs of 1 are distinct and the lengths of the runs of 0's are distinct.

Original entry on oeis.org

1, 2, 3, 4, 6, 7, 8, 11, 12, 13, 14, 15, 16, 19, 23, 24, 25, 28, 29, 30, 31, 32, 35, 38, 39, 44, 47, 48, 49, 50, 52, 55, 56, 57, 59, 60, 61, 62, 63, 64, 67, 70, 71, 78, 79, 88, 92, 95, 96, 97, 98, 103, 104, 111, 112, 113, 114, 115, 116, 120, 121, 123, 124, 125
Offset: 1

Views

Author

Leroy Quet, May 07 2010

Keywords

Comments

A044813 contains those positive integers that when written in binary, have all run-lengths (of both 0's and 1's) distinct.
A175414 contains those positive integers in A175413 that are not in A044813. (A175414 contains those positive integers that when written in binary, at least one run of 0's is the same length as one run of 1's, even though all run of 0 are of distinct length and all runs of 1's are of distinct length.)
Also numbers whose binary expansion has all distinct runs (not necessarily run-lengths). - Gus Wiseman, Feb 21 2022

Crossrefs

Runs in binary expansion are counted by A005811, distinct A297770.
The complement is A351205.
The version for standard compositions is A351290, complement A351291.
A000120 counts binary weight.
A242882 counts compositions with distinct multiplicities.
A318928 gives runs-resistance of binary expansion.
A325545 counts compositions with distinct differences.
A333489 ranks anti-runs, complement A348612, counted by A003242.
A334028 counts distinct parts in standard compositions.
A351014 counts distinct runs in standard compositions.
Counting words with all distinct runs:
- A351013 = compositions, for run-lengths A329739.
- A351016 = binary words, for run-lengths A351017.
- A351018 = binary expansions, for run-lengths A032020.
- A351200 = patterns, for run-lengths A351292.
- A351202 = permutations of prime factors.

Programs

  • Maple
    q:= proc(n) uses ListTools; (l-> is(nops(l)=add(
          nops(i), i={Split(`=`, l, 1)}) +add(
          nops(i), i={Split(`=`, l, 0)})))(Bits[Split](n))
        end:
    select(q, [$1..200])[];  # Alois P. Heinz, Mar 14 2022
  • Mathematica
    f[n_] := And@@Unequal@@@Transpose[Partition[Length/@Split[IntegerDigits[n, 2]], 2, 2, {1,1}, 0]]; Select[Range[125], f] (* Ray Chandler, Oct 21 2011 *)
    Select[Range[0,100],UnsameQ@@Split[IntegerDigits[#,2]]&] (* Gus Wiseman, Feb 21 2022 *)
  • Python
    from itertools import groupby, product
    def ok(n):
        runs = [(k, len(list(g))) for k, g in groupby(bin(n)[2:])]
        return len(runs) == len(set(runs))
    print([k for k in range(1, 125) if ok(k)]) # Michael S. Branicky, Feb 22 2022

Extensions

Extended by Ray Chandler, Oct 21 2011

A351202 Number of permutations of the multiset of prime factors of n (or ordered prime factorizations of n) with all distinct runs.

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 2, 1, 2, 2, 1, 1, 2, 1, 2, 2, 2, 1, 4, 1, 2, 1, 2, 1, 6, 1, 1, 2, 2, 2, 2, 1, 2, 2, 4, 1, 6, 1, 2, 2, 2, 1, 4, 1, 2, 2, 2, 1, 4, 2, 4, 2, 2, 1, 6, 1, 2, 2, 1, 2, 6, 1, 2, 2, 6, 1, 4, 1, 2, 2, 2, 2, 6, 1, 4, 1, 2, 1, 6, 2, 2, 2
Offset: 1

Views

Author

Gus Wiseman, Feb 13 2022

Keywords

Examples

			The a(36) = 2 permutations are (1,1,2,2), (2,2,1,1). Missing are: (1,2,1,2), (1,2,2,1), (2,1,1,2), (2,1,2,1). Here we use prime indices instead of factors.
		

Crossrefs

The maximum number of possible permutations is A008480.
Positions less than A008480 are A351201.
A005811 counts runs in binary expansion.
A044813 lists numbers whose binary expansion has distinct run-lengths.
A056239 adds up prime indices, row sums of A112798.
A098859 counts partitions with distinct multiplicities, ordered A242882.
A283353 counts normal multisets with a permutation without distinct runs.
A297770 counts distinct runs in binary expansion.
A351014 counts distinct runs in standard compositions, firsts A351015.
A351204 = partitions whose perms. have distinct runs, complement A351203.
Counting words with all distinct runs:
- A351013 = compositions, for run-lengths A329739, ranked by A351290.
- A351016 = binary words, for run-lengths A351017.
- A351018 = binary expansions, for run-lengths A032020, ranked by A175413.
- A351200 = patterns, for run-lengths A351292.

Programs

  • Mathematica
    Table[Length[Select[Permutations[Join@@ ConstantArray@@@FactorInteger[n]],UnsameQ@@Split[#]&]],{n,100}]

A382879 Positions of 0 in A382857 (permutations of prime indices with equal run-lengths).

Original entry on oeis.org

24, 40, 48, 54, 56, 80, 88, 96, 104, 112, 135, 136, 152, 160, 162, 176, 184, 189, 192, 208, 224, 232, 240, 248, 250, 272, 288, 296, 297, 304, 320, 328, 336, 344, 351, 352, 368, 375, 376, 384, 405, 416, 424, 448, 459, 464, 472, 480, 486, 488, 496, 513, 528, 536
Offset: 1

Views

Author

Gus Wiseman, Apr 09 2025

Keywords

Comments

A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798, sum A056239.

Examples

			The terms together with their prime indices begin:
   24: {1,1,1,2}
   40: {1,1,1,3}
   48: {1,1,1,1,2}
   54: {1,2,2,2}
   56: {1,1,1,4}
   80: {1,1,1,1,3}
   88: {1,1,1,5}
   96: {1,1,1,1,1,2}
  104: {1,1,1,6}
  112: {1,1,1,1,4}
  135: {2,2,2,3}
  136: {1,1,1,7}
  152: {1,1,1,8}
  160: {1,1,1,1,1,3}
		

Crossrefs

For distinct instead of equal the complement is A351294, counted by A239455.
For distinct instead of equal we have A351295, counted by A351293.
For run-sums instead of run-lengths we have A383100, zeros of A382877, distinct A382876.
Positions of 0 in A382857 (firsts A382878), by signature A382858 (distinct A382773).
For prime signature instead of prime indices we have A382914.
Partitions of this type are counted by A382915.
The complement is counted by A383013.
A005811 counts runs in binary expansion.
A056239 adds up prime indices, row sums of A112798.
A297770 counts distinct runs in binary expansion.
A164707 lists numbers whose binary form has equal runs of ones, distinct A328592.
A304442 counts partitions with equal run-sums, ranks A353833.
A329739 counts compositions with distinct run-lengths, ranks A351290.
A353744 ranks compositions with equal run-lengths, distinct A351596 (complement A351291).

Programs

  • Mathematica
    Select[Range[100], Select[Permutations[Join@@ConstantArray@@@FactorInteger[#]], SameQ@@Length/@Split[#]&]=={}&]

A382912 Numbers k such that row k of A305936 (a multiset whose multiplicities are the prime indices of k) has no permutation with all distinct run-lengths.

Original entry on oeis.org

4, 8, 9, 12, 16, 18, 20, 24, 27, 28, 32, 36, 40, 44, 45, 48, 50, 52, 54, 56, 60, 63, 64, 68, 72, 75, 76, 80, 81, 84, 88, 90, 92, 96, 98, 99, 100, 104, 108, 112, 116, 117, 120, 124, 125, 126, 128, 132, 135, 136, 140, 144, 148, 150, 152, 153, 156, 160, 162, 164
Offset: 1

Views

Author

Gus Wiseman, Apr 12 2025

Keywords

Comments

This described multiset (row n of A305936, Heinz number A181821) is generally not the same as the multiset of prime indices of n (A112798). For example, the prime indices of 12 are {1,1,2}, while a multiset whose multiplicities are {1,1,2} is {1,1,2,3}.
A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798, sum A056239.

Examples

			The terms, prime indices, and corresponding multisets begin:
   4:       {1,1} {1,2}
   8:     {1,1,1} {1,2,3}
   9:       {2,2} {1,1,2,2}
  12:     {1,1,2} {1,1,2,3}
  16:   {1,1,1,1} {1,2,3,4}
  18:     {1,2,2} {1,1,2,2,3}
  20:     {1,1,3} {1,1,1,2,3}
  24:   {1,1,1,2} {1,1,2,3,4}
  27:     {2,2,2} {1,1,2,2,3,3}
  28:     {1,1,4} {1,1,1,1,2,3}
  32: {1,1,1,1,1} {1,2,3,4,5}
  36:   {1,1,2,2} {1,1,2,2,3,4}
  40:   {1,1,1,3} {1,1,1,2,3,4}
  44:     {1,1,5} {1,1,1,1,1,2,3}
  45:     {2,2,3} {1,1,1,2,2,3,3}
  48: {1,1,1,1,2} {1,1,2,3,4,5}
  50:     {1,3,3} {1,1,1,2,2,2,3}
  52:     {1,1,6} {1,1,1,1,1,1,2,3}
		

Crossrefs

The Look-and-Say partition is ranked by A048767, listed by A381440.
Look-and-Say partitions are counted by A239455, ranks A351294.
Non-Look-and-Say partitions are counted by A351293.
For prime indices instead of signature we have A351295, conjugate A381433.
The complement is A382913.
For equal instead of distinct run-lengths we have A382914, see A382858, A382879, A382915.
A056239 adds up prime indices, row sums of A112798.
A329739 counts compositions with distinct run-lengths, ranks A351596, complement A351291.
A381431 lists the section-sum partition of n, ranks A381436, union A381432.

Programs

  • Mathematica
    nrmptn[n_]:=Join@@MapIndexed[Table[#2[[1]],{#1}]&,If[n==1,{}, Flatten[Cases[FactorInteger[n]//Reverse,{p_,k_} :> Table[PrimePi[p],{k}]]]]];
    lasQ[y_]:=Select[Permutations[y], UnsameQ@@Length/@Split[#]&]!={};
    Select[Range[100],Not@*lasQ@*nrmptn]

A351200 Number of patterns of length n with all distinct runs.

Original entry on oeis.org

1, 1, 3, 11, 53, 305, 2051, 15731, 135697, 1300869, 13726431, 158137851, 1975599321, 26607158781, 384347911211, 5928465081703, 97262304328573, 1691274884085061, 31073791192091251, 601539400910369671, 12238270940611270161, 261071590963047040241
Offset: 0

Views

Author

Gus Wiseman, Feb 09 2022

Keywords

Comments

We define a pattern to be a finite sequence covering an initial interval of positive integers. Patterns are counted by A000670 and ranked by A333217.

Examples

			The a(1) = 1 through a(3) = 11 patterns:
  (1)  (1,1)  (1,1,1)
       (1,2)  (1,1,2)
       (2,1)  (1,2,2)
              (1,2,3)
              (1,3,2)
              (2,1,1)
              (2,1,3)
              (2,2,1)
              (2,3,1)
              (3,1,2)
              (3,2,1)
The complement for n = 3 counts the two patterns (1,2,1) and (2,1,2).
		

Crossrefs

The version for run-lengths instead of runs is A351292.
A000670 counts patterns, ranked by A333217.
A005649 counts anti-run patterns, complement A069321.
A005811 counts runs in binary expansion.
A032011 counts patterns with distinct multiplicities.
A044813 lists numbers whose binary expansion has distinct run-lengths.
A060223 counts Lyndon patterns, necklaces A019536, aperiodic A296975.
A131689 counts patterns by number of distinct parts.
A238130 and A238279 count compositions by number of runs.
A297770 counts distinct runs in binary expansion.
A345194 counts alternating patterns, up/down A350354.
Counting words with all distinct runs:
- A351013 = compositions, for run-lengths A329739, ranked by A351290.
- A351016 = binary words, for run-lengths A351017.
- A351018 = binary expansions, for run-lengths A032020, ranked by A175413.
- A351202 = permutations of prime factors.
- A351642 = word structures.
Row sums of A351640.

Programs

  • Mathematica
    allnorm[n_]:=If[n<=0,{{}},Function[s,Array[Count[s,y_/;y<=#]+1&,n]] /@Subsets[Range[n-1]+1]];
    Table[Length[Select[Join@@Permutations/@allnorm[n],UnsameQ@@Split[#]&]],{n,0,6}]
  • PARI
    \\ here LahI is A111596 as row polynomials.
    LahI(n,y)={sum(k=1, n, y^k*(-1)^(n-k)*(n!/k!)*binomial(n-1, k-1))}
    S(n)={my(p=prod(k=1, n, 1 + y*x^k + O(x*x^n))); 1 + sum(i=1, (sqrtint(8*n+1)-1)\2, polcoef(p,i,y)*LahI(i,y))}
    R(q)={[subst(serlaplace(p), y, 1) | p<-Vec(q)]}
    seq(n)={my(q=S(n)); concat([1], sum(k=1, n, R(q^k-1)*sum(r=k, n, binomial(r, k)*(-1)^(r-k)) ))} \\ Andrew Howroyd, Feb 12 2022

Extensions

Terms a(10) and beyond from Andrew Howroyd, Feb 12 2022

A351290 Numbers k such that the k-th composition in standard order has all distinct runs.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 47, 48, 50, 51, 52, 55, 56, 57, 58, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 78
Offset: 1

Views

Author

Gus Wiseman, Feb 10 2022

Keywords

Comments

The n-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 n, 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)
   5:    101  (2,1)
   6:    110  (1,2)
   7:    111  (1,1,1)
   8:   1000  (4)
   9:   1001  (3,1)
  10:   1010  (2,2)
  11:   1011  (2,1,1)
  12:   1100  (1,3)
  14:   1110  (1,1,2)
  15:   1111  (1,1,1,1)
		

Crossrefs

The version for Heinz numbers and prime multiplicities is A130091.
The version using binary expansions is A175413, complement A351205.
The version for run-lengths instead of runs is A329739.
These compositions are counted by A351013.
The complement is A351291.
A005811 counts runs in binary expansion, distinct A297770.
A011782 counts integer compositions.
A044813 lists numbers whose binary expansion has distinct run-lengths.
A085207 represents concatenation of standard compositions, reverse A085208.
A333489 ranks anti-runs, complement A348612.
A345167 ranks alternating compositions, counted by A025047.
A351204 counts partitions where every permutation has all distinct runs.
Counting words with all distinct runs:
- A351016 = binary words, for run-lengths A351017.
- A351018 = binary expansions, for run-lengths A032020.
- A351200 = patterns, for run-lengths A351292.
- A351202 = permutations of prime factors.
Selected statistics of standard compositions:
- Length is A000120.
- Parts are A066099, reverse A228351.
- Sum is A070939.
- Runs are counted by A124767, distinct A351014.
- 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;
    Select[Range[0,100],UnsameQ@@Split[stc[#]]&]

A383013 Number of integer partitions of n having a permutation with all equal run-lengths.

Original entry on oeis.org

1, 1, 2, 3, 5, 6, 9, 11, 18, 21, 31, 38, 56, 67, 94, 121, 162, 199, 265, 330, 438, 543, 693, 859, 1103, 1353, 1702, 2097, 2619, 3194, 3972, 4821, 5943, 7206, 8796, 10632, 12938, 15536, 18794, 22539, 27133, 32374, 38827, 46175, 55134, 65421, 77751, 91951, 109011, 128482
Offset: 0

Views

Author

Gus Wiseman, Apr 12 2025

Keywords

Comments

A partition of n counts towards a(n) if and only if #p + g >= 2*L where #p is the number of parts counted with multiplicity of the partition, g is the gcd of all the frequencies of every distinct part and L is the largest frequency of a part. - David A. Corneth, Apr 27 2025

Examples

			The partition (2,2,1,1,1,1) has permutation (1,1,2,2,1,1) with equal run-lengths (2,2,2) so is counted under a(8).
The a(1) = 1 through a(8) = 18 partitions:
  (1)  (2)   (3)    (4)     (5)      (6)       (7)        (8)
       (11)  (21)   (22)    (32)     (33)      (43)       (44)
             (111)  (31)    (41)     (42)      (52)       (53)
                    (211)   (221)    (51)      (61)       (62)
                    (1111)  (311)    (222)     (322)      (71)
                            (11111)  (321)     (331)      (332)
                                     (411)     (421)      (422)
                                     (2211)    (511)      (431)
                                     (111111)  (3211)     (521)
                                               (22111)    (611)
                                               (1111111)  (2222)
                                                          (3221)
                                                          (3311)
                                                          (4211)
                                                          (22211)
                                                          (32111)
                                                          (221111)
                                                          (11111111)
		

Crossrefs

For distinct instead of equal run-lengths we have A239455, ranked by A351294.
The complement for distinct run-lengths is A351293, ranked by A351295.
The complement is counted by A382915, ranked by A382879, by signature A382914.
A000041 counts integer partitions, strict A000009.
A304442 counts partitions with equal run-sums, ranks A353833.
A329738 counts compositions with equal run-lengths, ranks A353744.
A329739 counts compositions with distinct run-lengths, ranks A351596.
A382857 counts permutations of prime indices with equal run-lengths, firsts A382878.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n],Select[Permutations[#], SameQ@@Length/@Split[#]&]!={}&]],{n,0,15}]

Extensions

More terms from Bert Dobbelaere, Apr 26 2025
Showing 1-10 of 23 results. Next