Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A006165
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A006165 a(1) = a(2) = 1; thereafter a(2n+1) = a(n+1) + a(n), a(2n) = 2a(n).
(Formerly M0277)
+0
6
1, 1, 2, 2, 3, 4, 4, 4, 5, 6, 7, 8, 8, 8, 8, 8, 9, 10, 11, 12, 13, 14, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43 (list; graph; listen)
OFFSET

1,3

COMMENT

a(n+1) is the second-order survivor of the n-person Josephus problem where every second person is marked until only one remains, who is then eliminated; the process is repeated from the beginning until all but one is eliminated. a(n) is first a power of 2 when n is three times a power of 2. For example, the first appearances of 2, 4, 8 and 16 are at positions 3, 6, 12 and 24, or (3*1),(3*2),(3*4) and (3*8). Eugene McDonnell (eemcd(AT)aol.com), Jan 19 2002, reporting on work of Boyko Bantchev (Bulgaria).

a(n+1)=min(msb(n),1+n-msb(n)/2) for all n (msb = most significant bit, A053644). - Boyko Bantchev (bantchev(AT)math.bas.bg), May 17 2002

Appears to coincide with following sequence: Let n >= 1. Start with a bag B containing n 1's. At each step, replace the two least elements x and y in B with the single element x+y. Repeat until B contains 2 or fewer elements. Let a(n) be the largest element remaining in B at this point. - David W. Wilson, Jul 01, 2003

REFERENCES

N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

J.-P. Allouche and J. Shallit, The ring of k-regular sequences, II, Theoret. Computer Sci., 307 (2003), 3-29.

J. Arkin, D. C. Arney, L. S. Dewald and W. E. Ebel, Jr., Families of recursive sequences, J. Rec. Math., 22 (No. 22, 1990), 85-94.

LINKS

J.-P. Allouche and J. Shallit, The Ring of k-regular Sequences, II

R. Stephan, Some divide-and-conquer sequences ...

R. Stephan, Table of generating functions

FORMULA

For n>=2, if a(n)>=A006257(n), i.e. if msb(n)>n-a(n)/2, then a(n+1)=a(n)+1, otherwise a(n+1)=a(n). Henry Bottomley (se16(AT)btinternet.com), Jan 21 2002.

a(1)=1, a(n)=n-a(n-a(a(n-1))). - Benoit Cloitre (benoit7848c(AT)orange.fr), Nov 08 2002

For k>0, 0<=i<=2^k-1, a(2^k+i)=2^(k-1)+i; for 2^k-2^(k-2)<=x<=2^k a(x)=2^(k-1); (also a(m*2^k)=a(m)*2^k for m>=2 ) - Benoit Cloitre (benoit7848c(AT)orange.fr), Dec 16 2002

G.f. x * (1/(1+x) + 1/(1-x)^2 * sum(k>=0, t^2(1-t), t=x^2^k)). - Ralf Stephan (ralf(AT)ark.in-berlin.de), Sep 12 2003

a(n) = A005942(n+1)/2 - n = n - A060973(n) = 2n - A007378(n). - Ralf Stephan (ralf(AT)ark.in-berlin.de), Sep 13 2003

CROSSREFS

Cf. A066997.

a(n) = A080776(n-1) + A060937(n). (from Ralf Stephan)

Sequence in context: A076897 A078881 A066997 this_sequence A131807 A104351 A070172

Adjacent sequences: A006162 A006163 A006164 this_sequence A006166 A006167 A006168

KEYWORD

nonn,easy

AUTHOR

N. J. A. Sloane (njas(AT)research.att.com).

EXTENSIONS

More terms from Larry Reeves (larryr(AT)acm.org), Jun 12 2002

page 1

Search completed in 0.002 seconds

Lookup | Welcome | Find friends | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
More pages | Superseeker | Maintained by N. J. A. Sloane (njas@research.att.com)

Last modified November 24 23:16 EST 2009. Contains 167481 sequences.


AT&T Labs Research