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!)
A073139 Difference between the largest and smallest number having in binary representation the same number of 0's and 1's as n. 5
0, 0, 0, 0, 0, 1, 1, 0, 0, 3, 3, 3, 3, 3, 3, 0, 0, 7, 7, 9, 7, 9, 9, 7, 7, 9, 9, 7, 9, 7, 7, 0, 0, 15, 15, 21, 15, 21, 21, 21, 15, 21, 21, 21, 21, 21, 21, 15, 15, 21, 21, 21, 21, 21, 21, 15, 21, 21, 21, 15, 21, 15, 15, 0, 0, 31, 31, 45, 31, 45, 45, 49, 31, 45, 45, 49, 45, 49, 49, 45, 31 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,10
COMMENTS
a(n) = A073138(n) - A073137(n).
LINKS
MATHEMATICA
d[n_]:=Module[{idn2=IntegerDigits[n, 2]}, FromDigits[Sort[idn2, #1>#2&], 2]- FromDigits[ RotateRight[Sort[idn2], 1], 2]]; Array[d, 90, 0] (* Harvey P. Dale, Oct 22 2011 *)
CROSSREFS
Sequence in context: A141605 A356002 A251551 * A122845 A135203 A251552
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Jul 16 2002
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 16 03:59 EDT 2024. Contains 372549 sequences. (Running on oeis4.)