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!)
A112248 a(n) = n mod floor(log_2(n)). 3
0, 0, 0, 1, 0, 1, 2, 0, 1, 2, 0, 1, 2, 0, 0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 2, 3, 2, 3, 4, 0, 1, 2, 3, 4, 0, 1, 2, 3, 4, 0, 1, 2, 3, 4, 0, 1, 2, 3, 4, 0, 1, 2, 3, 4, 0, 1, 2, 3, 4, 5, 0, 1, 2, 3, 4, 5, 0, 1, 2, 3, 4, 5, 0, 1, 2, 3, 4, 5, 0, 1, 2, 3, 4, 5, 0, 1, 2, 3, 4, 5, 0, 1, 2, 3, 4, 5, 0, 1, 2, 3, 4 (list; graph; refs; listen; history; text; internal format)
OFFSET
2,7
COMMENTS
a(A112249(n)) = 0, a(A112250(n)) > 0, a(A112251(n)) = 1.
LINKS
MAPLE
seq(seq(n mod d, n=2^d .. 2^(d+1)-1), d=1..8); # Robert Israel, Aug 27 2020
MATHEMATICA
Table[Mod[n, Floor @ Log2[n]], {n, 2, 100}] (* Amiram Eldar, Aug 27 2020 *)
PROG
(PARI) a(n) = n % logint(n, 2); \\ Michel Marcus, Aug 27 2020
CROSSREFS
Sequence in context: A331466 A166124 A134979 * A244860 A308009 A010872
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Aug 30 2005
EXTENSIONS
Name edited by Michel Marcus, Aug 27 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 6 23:32 EDT 2024. Contains 372298 sequences. (Running on oeis4.)