|
|
A287837
|
|
Number of words over the alphabet {0,1,...,10} such that no two consecutive terms have distance 7.
|
|
0
|
|
|
1, 11, 113, 1163, 11969, 123179, 1267697, 13046507, 134268161, 1381821131, 14221015793, 146355621323, 1506219260609, 15501259470059, 159531252482417, 1641816303234347, 16896756789790721, 173893016807610251, 1789620438445474673, 18417883434877577483
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,2
|
|
COMMENTS
|
In general, the number of sequences on {0,1,...,10} such that no two consecutive terms have distance 6+k for k in {0,1,2,3,4} has generating function (-1 - x)/(-1 + 10*x + (2*k+1)*x^2).
|
|
LINKS
|
|
|
FORMULA
|
For n>2, a(n) = 10*a(n-1) + 3*a(n-2), a(0)=1, a(1)=11, a(2)=113.
G.f.: (-1 - x)/(-1 + 10*x + 3*x^2).
|
|
MATHEMATICA
|
LinearRecurrence[{10, 3}, {1, 11, 113}, 20]
|
|
PROG
|
(Python)
def a(n):
.if n in [0, 1, 2]:
..return [1, 11, 113][n]
.return 10*a(n-1) + 3*a(n-2)
|
|
CROSSREFS
|
Cf. A040000, A003945, A083318, A078057, A003946, A126358, A003946, A055099, A003947, A015448, A126473. A287804-A287819. A287825-A287839.
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|