login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A029471 Numbers n such that n divides the (left) concatenation of all numbers <= n written in base 2 (most significant digit on left). 141

%I

%S 1,85,145,245,1189,356717,19590671,35741759

%N Numbers n such that n divides the (left) concatenation of all numbers <= n written in base 2 (most significant digit on left).

%C No other terms below 10^8.

%H <a href="/index/N#concat">Index entries for related sequences</a>

%o (Python)

%o from itertools import count

%o .

%o def a029471():

%o ...total = 0

%o ...power_of_two = 1

%o ...index_of_two = 0

%o ...length_of_string = 0

%o .

%o ...for n in count(1):

%o ......total += (n<<length_of_string)

%o ......if n==power_of_two:

%o .........power_of_two*=2

%o .........index_of_two += 1

%o .

%o ......length_of_string += index_of_two

%o .

%o ......if total % n == 0:

%o .........yield n

%o # _Christian Perfect_, Feb 07 2014

%Y Cf. A029447-A029470, A029471-A029494, A029495-A029518, A029519-A029542, A061931-A061954, A061955-A061978

%K nonn,base,hard,more

%O 1,2

%A _Olivier GĂ©rard_

%E One more term from Larry Reeves (larryr(AT)acm.org), Dec 03 2001

%E Edited and updated by Larry Reeves (larryr(AT)acm.org), Apr 12 2002

%E a(7)-a(8) from _Max Alekseyev_, May 12 2011

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified November 18 01:16 EST 2018. Contains 317279 sequences. (Running on oeis4.)