OFFSET
0,2
COMMENTS
a(n) is the number of words of length n defined on 5 letters that contain zero or one a's, zero or one b's, zero or one c's, and any number of d's and e's.
LINKS
Index entries for linear recurrences with constant coefficients, signature (8,-24,32,-16).
FORMULA
E.g.f.: exp(2*x)*(1+x)^3.
G.f.: (1 - 3*x + 6*x^2 - 2*x^3)/(1 - 2*x)^4. - Stefano Spezia, Jul 03 2025
EXAMPLE
a(1) = 5 since the words are a, b, c, d, e.
a(2) = 22 since the words are ab, ba, ac, ca, ad, da, ae, ea, bc, cb, bd, db, be, eb, cd, dc, ce, ec, de, ed, dd, ee.
MATHEMATICA
LinearRecurrence[{8, -24, 32, -16}, {1, 5, 22, 86}, 30] (* Amiram Eldar, Jul 03 2025 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Enrique Navarrete, Jul 03 2025
STATUS
approved
