login
A353098
a(1) = 6; for n>1, a(n) = 7 * a(n-1) + 7 - n.
7
6, 47, 333, 2334, 16340, 114381, 800667, 5604668, 39232674, 274628715, 1922401001, 13456807002, 94197649008, 659383543049, 4615684801335, 32309793609336, 226168555265342, 1583179886857383, 11082259208001669, 77575814456011670, 543030701192081676
OFFSET
1,1
FORMULA
G.f.: x * (6 - 7 * x)/((1 - x)^2 * (1 - 7 * x)).
a(n) = 9*a(n-1) - 15*a(n-2) + 7*a(n-3).
a(n) = 5 * A014830(n) + n.
a(n) = (5*7^(n+1) + 6*n - 35)/36.
a(n) = Sum_{k=0..n-1} (7 - n + k)*7^k.
E.g.f.: exp(x)*(35*(exp(6*x) - 1) + 6*x)/36. - Stefano Spezia, May 29 2023
MATHEMATICA
LinearRecurrence[{9, -15, 7}, {6, 47, 333}, 21] (* Amiram Eldar, Apr 23 2022 *)
PROG
(PARI) my(N=30, x='x+O('x^N)); Vec(x*(6-7*x)/((1-x)^2*(1-7*x)))
(PARI) a(n) = (5*7^(n+1)+6*n-35)/36;
(PARI) b(n, k) = sum(j=0, n-1, (k-n+j)*k^j);
a(n) = b(n, 7);
KEYWORD
nonn,easy
AUTHOR
Seiichi Manyama, Apr 23 2022
STATUS
approved