OFFSET
0,2
COMMENTS
Define sequences a(n) and b(n) recursively, starting with a(0) = 1, b(0) = 2:
b(n) = least new;
a(n) = 3*a(n-1) + x(0)*b(n) + x(1)*b(n-1) + ... + x(n)b(0),
where "least new k" means the least positive integer not yet placed, and x(k) = (-1)^k for k >= 0.
***
It appears that a(n)/a(n-1) -> 3 and that {a(n) - 3*a(n-1), n >= 1} is unbounded.
EXAMPLE
b(1) = least not in {a(0),b(0)} = 3;
a(1) = 3*a(0) + b(1) - b(0) = 3*1 + 3 - 2 = 4.
MATHEMATICA
mex[list_, start_] := (NestWhile[# + 1 &, start, MemberQ[list, #] &]);
c = 3; a = {1}; b = {2}; x = {-1};
Do[AppendTo[b, mex[Flatten[{a, b}], 1]];
AppendTo[x, -Last[x]];
AppendTo[a, c Last[a] - (Reverse[x] b // Total)], {25}]
Grid[{Join[{"n"}, Range[0, # - 1]], Join[{"a(n)"}, Take[a, #]],
Join[{"b(n)"}, Take[b, #]], Join[{"x(n)"}, Take[-x, #]]},
Alignment -> ".",
Dividers -> {{2 -> Red, -1 -> Blue}, {2 -> Red, -1 -> Blue}}] &[10]
(* Peter J. C. Moses, May 10 2018 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, May 12 2018
STATUS
approved