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.
%I A385818 #12 Sep 04 2025 08:40:24 %S A385818 0,1,2,3,4,5,6,8,7,9,10,12,16,11,13,17,14,18,20,24,32,15,19,21,25,33, %T A385818 22,26,34,28,36,40,48,64,23,27,35,29,37,41,49,65,30,38,42,50,66,44,52, %U A385818 68,56,72,80,96,128,31,39,43,51,67,45,53,69,57,73,81,97 %N A385818 The number k such that the k-th composition in standard order lists the maximal run lengths of each nonnegative integer's binary indices, with duplicates removed. %C A385818 A permutation of the nonnegative integers. %C A385818 A binary index of n is any position of a 1 in its reversed binary expansion. The binary indices of n are row n of A048793. %C A385818 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. %H A385818 John Tyler Rascoe, <a href="/A385818/b385818.txt">Table of n, a(n) for n = 0..8192</a> %e A385818 The binary indices of 53 are {1,3,5,6}, with maximal runs ((1),(3),(5,6)) with lengths (1,1,2), which is the 14th composition in standard order, so A385889(53) = 14, and after removing duplicate rows a(16) = 14. %t A385818 bpe[n_]:=Join@@Position[Reverse[IntegerDigits[n,2]],1]; %t A385818 stcinv[q_]:=Total[2^(Accumulate[Reverse[q]])]/2; %t A385818 stcinv/@DeleteDuplicates[Table[Length/@Split[bpe[n],#2==#1+1&],{n,0,100}]] %Y A385818 For anti-runs instead of runs we appear to have A348366. %Y A385818 See also A385816 (standard compositions of rows of A384877), reverse A209859. %Y A385818 The compositions themselves are listed by A385817. %Y A385818 Before removing duplicates we had A385889. %Y A385818 A245563 lists run lengths of binary indices (ranks A246029), rev A245562, strict A328592. %Y A385818 A384175 counts subsets with all distinct lengths of maximal runs, complement A384176. %Y A385818 Cf. A000120, A029931, A048793, A052499, A069010, A200648, A200649, A200650, A384890, A385886, A385887. %K A385818 nonn,easy,changed %O A385818 0,3 %A A385818 _Gus Wiseman_, Jul 18 2025