OFFSET
1,3
COMMENTS
a(n) is the number of n-digit numbers in A366966.
LINKS
Index entries for linear recurrences with constant coefficients, signature (27,-242,720).
FORMULA
a(n) = 9*10^(n-1) - 17*9^(n-1) + 8^n.
a(n) = 27*a(n-1) - 242*a(n-2) + 720*a(n-3) for n > 3.
O.g.f.: x^2*(1 + 8*x)/((1 - 8*x)*(1 - 9*x)*(1 - 10*x)).
E.g.f.: (81*exp(10*x) - 170*exp(9*x) + 90*exp(8*x) - 1)/90.
MATHEMATICA
LinearRecurrence[{27, -242, 720}, {0, 1, 35}, 21]
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
Stefano Spezia, Nov 11 2023
STATUS
approved