OFFSET
1,1
COMMENTS
Take an n X n square grid and add unit squares along each side except for the corners --> do this repeatedly along each side with the same restriction until no squares can be added. a(n) gives the number of vertices in each figure (see example and cf. A255840).
LINKS
Colin Barker, Table of n, a(n) for n = 1..1000
Index entries for linear recurrences with constant coefficients, signature (2,0,-2,1).
FORMULA
EXAMPLE
_
_|_|_
_ _ _ _|_|_|_|_
_|_|_ _|_|_|_ _|_|_|_|_|_|_
_ _ _|_|_|_|_ _|_|_|_|_|_ _|_|_|_|_|_|_|_|_
_ |_|_| |_|_|_|_|_| |_|_|_|_|_|_| |_|_|_|_|_|_|_|_|_|
|_| |_|_| |_|_|_| |_|_|_|_|_|_| |_|_|_|_|_|_|_|
|_| |_|_|_|_| |_|_|_|_|_|
|_|_| |_|_|_|
|_|
n=1 n=2 n=3 n=4 n=5
MATHEMATICA
CoefficientList[Series[(3 x^3 - 6 x^2 - x - 4)/((x + 1) (x - 1)^3), {x, 0, 50}], x]
PROG
(Magma) [(4*n^2 + 4*n - 3 - 3*(-1)^n)/2 : n in [1..50]];
(PARI) vector(100, n, (4*n^2 + 4*n - 3 - 3*(-1)^n)/2) \\ Derek Orr, Mar 09 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Wesley Ivan Hurt, Mar 08 2015
STATUS
approved