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”).

A151662
The first of three Hofstadter parents-child sequences of Thomas Stoll.
3
1, 0, 2, 1, 3, 3, 4, 4, 5, 7, 7, 8, 7, 10, 8, 10, 10, 11, 10, 13, 11, 13, 13, 14, 16, 16, 17, 16, 19, 17, 19, 19, 20, 21, 21, 22, 22, 23, 24, 24, 25, 24, 27, 25, 27, 27, 28, 30, 30, 31, 30, 33, 31, 33, 33, 34, 36, 36, 37, 36, 39, 37, 39, 39, 40, 39, 42, 40, 42, 42, 43, 45, 45, 46, 45, 48
OFFSET
0,3
COMMENTS
Define three sequence a, b, c by: a[0]:=1; b[0]:=0; c[0]:=0; for n >= 1, b[n]:=n-c[b[n-1]]; a[n]:=n-b[a[n-1]]; c[n]:=n-a[c[n-1]].
LINKS
Th. Stoll, On Hofstadter's married functions, Fib. Q., 46/47 (2008/2009), 62-67.
MAPLE
M:=130;
a[0]:=1; b[0]:=0; c[0]:=0;
for n from 1 to M do
b[n]:=n-c[b[n-1]];
a[n]:=n-b[a[n-1]];
c[n]:=n-a[c[n-1]];
od:
A:=[seq(a[n], n=0..M)];
B:=[seq(b[n], n=0..M)];
C:=[seq(c[n], n=0..M)];
CROSSREFS
Sequence in context: A360923 A123621 A370592 * A049786 A282611 A187498
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, May 30 2009
STATUS
approved