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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A136013 a(n) = floor(n/2) + 2 a(floor(n/2)), a(0) = 0. 2
0, 0, 1, 1, 4, 4, 5, 5, 12, 12, 13, 13, 16, 16, 17, 17, 32, 32, 33, 33, 36, 36, 37, 37, 44, 44, 45, 45, 48, 48, 49, 49, 80, 80, 81, 81, 84, 84, 85, 85, 92, 92, 93, 93, 96, 96, 97, 97, 112, 112, 113, 113, 116, 116, 117, 117, 124, 124, 125, 125, 128 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,5

COMMENTS

A recursive sequence that seems to be related to the ruler function.

It seems that a(2n) = a(2n+1) = A080277(n). - Emeric Deutsch, Mar 31 2008

It appears that if the binary expansion of n is n = Sum b_i*2^i (b_i=0 or 1), then a(n) = Sum i*b_i*2^(i-1). - Marc LeBrun, Sep 07 2015

LINKS

Table of n, a(n) for n=0..60.

MAPLE

a:=proc(n) if n=0 then 0 else floor((1/2)*n)+2*a(floor((1/2)*n)) end if end proc: seq(a(n), n=0..60); # Emeric Deutsch, Mar 31 2008

MATHEMATICA

a = {0}; Do[AppendTo[a, Floor[n/2] + 2*a[[Floor[n/2] + 1]]], {n, 1, 100}]; a (* Stefan Steinerberger, Mar 24 2008 *)

Table[Sum[2^(k-1)*Floor[n*2^-k], {k, 1, Log[2, n]}], {n, 0, 100}] (* Federico Provvedi, Aug 17 2013 *)

CROSSREFS

Cf. A080277.

Sequence in context: A257291 A152465 A082968 * A232172 A114884 A132704

Adjacent sequences:  A136010 A136011 A136012 * A136014 A136015 A136016

KEYWORD

nonn,easy

AUTHOR

Jack Preston (jpreston(AT)earthlink.net), Mar 20 2008

EXTENSIONS

More terms from Stefan Steinerberger and Emeric Deutsch, Mar 24 2008

Spelling corrected by Jason G. Wurtzel, Aug 30 2010

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 March 18 17:51 EDT 2019. Contains 321292 sequences. (Running on oeis4.)