A384177 Number of subsets of {1..n} with all distinct lengths of maximal anti-runs (increasing by more than 1).
1, 2, 3, 5, 10, 19, 35, 62, 109, 197, 364, 677, 1251, 2288, 4143, 7443, 13318, 23837, 42809, 77216, 139751, 253293, 458800, 829237, 1494169, 2683316, 4804083, 8580293, 15301324, 27270061, 48607667, 86696300, 154758265, 276453311, 494050894, 882923051
Offset: 0
Keywords
Examples
The subset {1,2,4,5,7,10} has maximal anti-runs ((1),(2,4),(5,7,10)), with lengths (1,2,3), so is counted under a(10). The a(0) = 1 through a(5) = 19 subsets: {} {} {} {} {} {} {1} {1} {1} {1} {1} {2} {2} {2} {2} {3} {3} {3} {1,3} {4} {4} {1,3} {5} {1,4} {1,3} {2,4} {1,4} {1,2,4} {1,5} {1,3,4} {2,4} {2,5} {3,5} {1,2,4} {1,2,5} {1,3,4} {1,3,5} {1,4,5} {2,3,5} {2,4,5}
Links
- Christian Sievers, Table of n, a(n) for n = 0..1000
Crossrefs
These subsets are ranked by A384879.
Programs
-
Mathematica
Table[Length[Select[Subsets[Range[n]],UnsameQ@@Length/@Split[#,#2!=#1+1&]&]],{n,0,10}]
-
PARI
lista(n)={my(o=(1-x^(n+1))/(1-x)*O(y*y^n),p=prod(i=1,(n+1)\2,1+o+x*y^(2*i-1)/(1-y)^(i-1)));p=subst(serlaplace(p),x,1);Vec((p-y)/(1-y)^2)} \\ Christian Sievers, Jun 18 2025
Extensions
a(21) and beyond from Christian Sievers, Jun 18 2025