The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A333766 Maximum part of the n-th composition in standard order. a(0) = 0. 26
0, 1, 2, 1, 3, 2, 2, 1, 4, 3, 2, 2, 3, 2, 2, 1, 5, 4, 3, 3, 3, 2, 2, 2, 4, 3, 2, 2, 3, 2, 2, 1, 6, 5, 4, 4, 3, 3, 3, 3, 4, 3, 2, 2, 3, 2, 2, 2, 5, 4, 3, 3, 3, 2, 2, 2, 4, 3, 2, 2, 3, 2, 2, 1, 7, 6, 5, 5, 4, 4, 4, 4, 4, 3, 3, 3, 3, 3, 3, 3, 5, 4, 3, 3, 3, 2, 2 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
One plus the longest run of 0's in the binary expansion of n.
A composition of n is a finite sequence of positive integers summing to n. The k-th composition in standard order (row k of 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.
LINKS
FORMULA
For n > 0, a(n) = A087117(n) + 1.
EXAMPLE
The 100th composition in standard order is (1,3,3), so a(100) = 3.
MATHEMATICA
stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n, 2]], 1], 0]]//Reverse;
Table[If[n==0, 0, Max@@stc[n]], {n, 0, 100}]
CROSSREFS
Positions of ones are A000225.
Positions of terms <= 2 are A003754.
The version for prime indices is A061395.
Positions of terms > 1 are A062289.
Positions of first appearances are A131577.
The minimum part is given by A333768.
All of the following pertain to compositions in standard order (A066099):
- Length is A000120.
- Compositions without 1's are A022340.
- Sum is A070939.
- Product is A124758.
- Runs are counted by A124767.
- Strict compositions are A233564.
- Constant compositions are A272919.
- Runs-resistance is A333628.
- Weakly decreasing compositions are A114994.
- Weakly increasing compositions are A225620.
- Strictly decreasing compositions are A333255.
- Strictly increasing compositions are A333256.
Sequence in context: A371014 A284267 A296525 * A333226 A175548 A038571
KEYWORD
nonn
AUTHOR
Gus Wiseman, Apr 05 2020
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 18 19:36 EDT 2024. Contains 372666 sequences. (Running on oeis4.)