login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A243615 Numbers n whose digital sum equals the number of binary digits in its binary expansion. 5
1, 2, 13, 23, 33, 42, 51, 60, 70, 106, 115, 124, 134, 143, 152, 161, 170, 206, 215, 224, 233, 242, 251, 261, 270, 306, 315, 324, 333, 342, 351, 360, 405, 414, 423, 432, 441, 450, 504, 514, 523, 532, 541, 550, 604, 613, 622, 631, 640, 703, 712, 721, 730, 802, 811, 820 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

LINKS

Andreas Boe, Table of n, a(n) for n = 1..10000

EXAMPLE

134 -> 1+3+4=8  134=10000110 -> Eight bits.

MATHEMATICA

Select[Range[10^3], Total@ IntegerDigits@ # == 1 + Floor@ Log2@ # &] (* Michael De Vlieger, Nov 05 2018 *)

PROG

(PARI) isok(n) = sumdigits(n) == #binary(n); \\ Michel Marcus, Jun 08 2014

CROSSREFS

Cf. A000120, A007953.

Sequence in context: A118796 A234218 A171794 * A243617 A045389 A243621

Adjacent sequences:  A243612 A243613 A243614 * A243616 A243617 A243618

KEYWORD

nonn,base

AUTHOR

Andreas Boe, Jun 07 2014

STATUS

approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 6 19:52 EDT 2021. Contains 343586 sequences. (Running on oeis4.)