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!)
A092525 To binary representation of n, append as many ones as there are trailing zeros. 1
1, 5, 3, 19, 5, 13, 7, 71, 9, 21, 11, 51, 13, 29, 15, 271, 17, 37, 19, 83, 21, 45, 23, 199, 25, 53, 27, 115, 29, 61, 31, 1055, 33, 69, 35, 147, 37, 77, 39, 327, 41, 85, 43, 179, 45, 93, 47, 783, 49, 101, 51, 211, 53, 109, 55, 455, 57, 117, 59, 243, 61, 125, 63, 4159 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
a(n) = (n+1)*A006519(n)-1;
a(2*n-1) = 2*n-1, a(2*n) > 4*n.
LINKS
EXAMPLE
n=20='10100'='101'00' -> a(20)='101'00'11'='1010011'=83.
MATHEMATICA
bra1[n_]:=Module[{idn2=IntegerDigits[n, 2]}, FromDigits[Join[ idn2, Table[1, {IntegerExponent[FromDigits[idn2]]}]], 2]]; Array[bra1, 70] (* Harvey P. Dale, Sep 30 2012 *)
PROG
(Haskell)
a092525 n = f n n where
f x y = if m == 0 then f x' (2 * y + 1) else y
where (x', m) = divMod x 2
-- Reinhard Zumkeller, Oct 06 2012
(Python)
def A092525(n): return (n+1)*(~n&n-1)+n # Chai Wah Wu, Jul 07 2022
CROSSREFS
Sequence in context: A349118 A073845 A169697 * A101367 A338790 A256565
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Apr 07 2004
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 April 19 19:02 EDT 2024. Contains 371798 sequences. (Running on oeis4.)