login
Solution of the complementary equation a(n) = a(n-1) + a(n-2) + b(0) + b(1) + ... + b(n-1), where a(0) = 1, a(1) = 2, b(0) = 3, and (a(n)) and (b(n)) are increasing complementary sequences.
34

%I #5 Nov 18 2017 20:54:07

%S 1,2,10,24,52,101,186,329,568,962,1608,2662,4377,7162,11679,18999,

%T 30855,50051,81124,131415,212802,344505,557621,902467,1460457,2363322,

%U 3824207,6187988,10012686,16201198,26214442,42416233,68631304,111048203

%N Solution of the complementary equation a(n) = a(n-1) + a(n-2) + b(0) + b(1) + ... + b(n-1), where a(0) = 1, a(1) = 2, b(0) = 3, and (a(n)) and (b(n)) are increasing complementary sequences.

%C The increasing complementary sequences a() and b() are uniquely determined by the titular equation and initial values. Guide to related sequencres:

%C A295053: a(n) = a(n-1) + a(n-2) + b(0) + b(1) + ... + b(n-1), a(0) = 1, a(1) = 2, b(0) = 3

%C A295054: a(n) = a(n-1) + a(n-2) + b(1) + b(2) + ... + b(n-1), a(0) = 1, a(1) = 2, b(0) = 3

%C A295055: a(n) = a(n-2) + b(1) + b(2) + ... + b(n-1), a(0) = 1, a(1) = 2, b(0) = 3

%C A295056: a(n) = 2*a(n-1) + b(n-1), a(0) = 1, a(1) = 4, b(0) = 2, b(1) = 3

%C A295057: a(n) = 2*a(n-1) + b(n-1), a(0) = 2, a(1) = 5, b(0) = 1

%C A295058: a(n) = 2*a(n-1) - b(n-1), a(0) = 3, a(1) = 5, b(0) = 1

%C A295059: a(n) = 2*a(n-1) + b(n-2), a(0) = 1, a(1) = 4, b(0) = 2, b(1) = 3

%C A295060: a(n) = 2*a(n-1) - b(n-2), a(0) = 3, a(1) = 5, b(0) = 1, b(1) = 2

%C A295061: a(n) = 4*a(n-1) + b(n-1), a(0) = 1, a(1) = 3, b(0) = 2

%C A295062: a(n) = 4*a(n-2) + b(n-2), a(0) = 1, a(1) = 3, b(0) = 2, b(1) = 4

%C A295063: a(n) = 4*a(n-2) + b(n-1) + b(n-2), a(0) = 1, a(1) = 3, b(0) = 2

%C A295064: a(n) = 8*a(n-3) + b(n-1), a(0) = 1, a(1) = 3, a(2) = 5, b(0) = 2

%C A295065: a(n) = 8*a(n-3) + b(n-2), a(0) = 1, a(1) = 3, a(2) = 5, b(0) = 2

%C A295066: a(n) = 2*a(n-2) + b(n-1), a(0) = 1, a(1) = 3, b(0) = 2

%C A295067: a(n) = 2*a(n-2) + b(n-2), a(0) = 1, a(1) = 3, b(0) = 2

%C A295068: a(n) = 2*a(n-2) - b(n-1) + n, a(0) = 3, a(1) = 4, b(0) = 1

%C A295069: a(n) = 2*a(n-2) - b(n-2) + n, a(0) = 3, a(1) = 4, b(0) = 1

%C A295070: a(n) = a(n-2) + b(n-1) + b(n-2), a(0) = 3, a(1) = 2, b(0) = 3

%C A295133: a(n) = 3*a(n-1) + b(n-1), a(0) = 1, a(1) = 2, b(0) = 3

%C A295134: a(n) = 3*a(n-1) + b(n-1) - 1, a(0) = 1, a(1) = 2, b(0) = 3

%C A295135: a(n) = 3*a(n-1) + b(n-1) - 2, a(0) = 1, a(1) = 2, b(0) = 3

%C A295136: a(n) = 3*a(n-1) + b(n-1) - 3, a(0) = 1, a(1) = 2, b(0) = 3

%C A295137: a(n) = 3*a(n-1) + b(n-1) - n, a(0) = 1, a(1) = 2, b(0) = 3

%C A295138: a(n) = 3*a(n-2) + b(n-1), a(0) = 1, a(1) = 2, b(0) = 3

%C A295139: a(n) = 3*a(n-1) + b(n-2), a(0) = 1, a(1) = 2, b(0) = 3, b(1) = 4

%C A295140: a(n) = 3*a(n-1) - b(n-2) + 4, a(0) = 1, a(1) = 3, b(0) = 2, b(1) = 4

%C A295141: a(n) = 2*a(n-1) + a(n-2) + b(n-2), a(0) = 1, a(1) = 2, b(0) = 3, b(1) = 4

%C A295142: a(n) = 2*a(n-1) + a(n-2) + b(n-2), a(0) = 1, a(1) = 3, b(0) = 2, b(1) = 4

%C A295143: a(n) = 2*a(n-1) + a(n-1) + b(n-1), a(0) = 1, a(1) = 2, b(0) = 3, b(1) = 4

%C A295144: a(n) = 2*a(n-1) + a(n-2) + b(n-1), a(0) = 1, a(1) = 3, b(0) = 2, b(1) = 4

%C A295145: a(n) = a(n-1) + 2*a(n-2) + b(n-2), a(0) = 1, a(1) = 2, b(0) = 3, b(1) = 4

%C A295146: a(n) = a(n-1) + 2*a(n-2) + b(n-2), a(0) = 1, a(1) = 3, b(0) = 2, b(1) = 4

%C A295147: a(n) = a(n-1) + 2*a(n-2) + b(n-1), a(0) = 1, a(1) = 2, b(0) = 3, b(1) = 4

%C A295148: a(n) = a(n-1) + 2*a(n-2) + b(n-1), a(0) = 1, a(1) = 3, b(0) = 2, b(1) = 4

%H Clark Kimberling, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL10/Kimberling/kimberling26.html">Complementary equations</a>, J. Int. Seq. 19 (2007), 1-13.

%e a(0) = 1, a(1) = 2, b(0) = 3

%e b(1) = 4 (least "new number")

%e a(2) = a(1) + a(0) + b(0) + b(1) = 10

%e Complement: (b(n)) = (3, 4, 5, 6, 7, 8, 9, 11, 12, 13, 14, ...)

%t mex := First[Complement[Range[1, Max[#1] + 1], #1]] &;

%t a[0] = 1; a[1] = 2; b[0] = 3;

%t a[n_] := a[n] = a[n - 1] + a[n - 2] + Sum[b[k], {k, 0, n - 1}];

%t b[n_] := b[n] = mex[Flatten[Table[Join[{a[n]}, {a[i], b[i]}], {i, 0, n - 1}]]];

%t Table[a[n], {n, 0, 18}] (* A295053 *)

%t Table[b[n], {n, 0, 10}]

%Y Cf. A294860.

%K nonn,easy

%O 0,2

%A _Clark Kimberling_, Nov 18 2017