login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

a(n)=n-a(a(n-2)) with a(0)=0,a(1)=1
1

%I #1 Jun 01 2010 03:00:00

%S 0,1,2,2,2,3,4,5,6,6,6,7,8,8,8,9,10,11,12,12,12,13,14,15,16,16,16,17,

%T 18,18,18,19,20,21,22,22,22,23,24,24,24,25,26,27,28,28,28,29,30,31,32,

%U 32,32,33,34,34,34,35,36,37,38,38,38,39,40,41,42,42,42,43,44,44,44,45,46

%N a(n)=n-a(a(n-2)) with a(0)=0,a(1)=1

%C A generalization of the Hofstadter G-sequence A005206 since it is part of the following family of sequences:

%C a(n)=n-a(a(n-k)) with the initial values a(0)=0,a(1)=a(2)=...=a(k-1)=1 and with k=1,2,3... (here k=2)

%C Every a(n) occurs either exactly one or exactly three times. Two blocks of three same elements are interrupted by either exactly one singular or exactly three consecutive natural numbers.

%C Since every natural number occurs in the sequence at least once the elements can be ordered in such a way that every n is connected to its a(n) in a tree structure so that:

%C ..a..

%C ..|..

%C .a(n)

%C This will give for the first 26 elements the following (ternary) tree:

%C ....1..............................

%C ....|..............................

%C ....2..............................

%C ./..|...\..........................

%C ....|......\.......................

%C ....|.........\....................

%C ....3...........4..................

%C ....|.............\................

%C ....5...............6..............

%C ....|.........../...|...\..........

%C ....7........8......9....10........

%C ....|....../.|.\....|.....\........

%C ....|...../..|..\...|......\.......

%C ....|..../....|..\..|.......\......

%C ...11...12....13.14.15......16.....

%C ....|../.|.\...|..|..|..../..|..\..

%C ...17.18.19.20.21.22.23.24..25..26.

%C Conjecture: Which features a certain structure (Comparable to A005206 or A135414). If the (below) following two constructs (C and D) are added on top of their ends (either marked with C or D) one will (if starting with one instance of D) receive the above tree (x marks a node):

%C Diagram of D:

%C .....x......

%C .../.|.\....

%C ..D..C..x...

%C .........\..

%C ..........D.

%C Diagram of C:

%C ..x..

%C ..|..

%C ..C..

%Y Same recurrence relation as A135414.

%K easy,nonn

%O 0,3

%A Daniel Platt (d.platt(AT)web.de), Aug 04 2009