OFFSET
1,3
COMMENTS
Extended to a(1)-a(2) using the formula/recurrence.
LINKS
Eric Weisstein's World of Mathematics, Barbell Graph
Eric Weisstein's World of Mathematics, Total Dominating Set
Index entries for linear recurrences with constant coefficients, signature (5,-10,10,-5,1).
FORMULA
a(n) = (2 + (n - 3)*n*(n + 1)/4)*n.
G.f.: x*(-1 + 4*x - 11*x^2 + 2*x^3)/(-1 + x)^5.
a(n) = 5*a(n-1) - 10*a(n-2) + 10*a(n-3) - 5*a(n-4) + a(n-5).
E.g.f.: exp(x)*x*(4 - 2*x + 4*x^2 + x^3)/4. - Stefano Spezia, Sep 06 2023
MATHEMATICA
Table[(2 + (n - 3) n (n + 1)/4) n, {n, 20}]
LinearRecurrence[{5, -10, 10, -5, 1}, {1, 1, 6, 28, 85}, 20]
CoefficientList[Series[(-1 + 4 x - 11 x^2 + 2 x^3)/(-1 + x)^5, {x, 0, 20}], x]
PROG
(Magma) [(2 + (n - 3)*n*(n + 1)/4)*n : n in [1..50]]; // Wesley Ivan Hurt, Apr 25 2023
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Eric W. Weisstein, Apr 11 2018
STATUS
approved