OFFSET
0,3
COMMENTS
Szeged index of cycle of length n.
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..1000
Janez Žerovnik, Szeged index of symmetric graphs, J. Chem. Inf. Comput. Sci., 39 (1999), 77-80; alternative link.
Index entries for linear recurrences with constant coefficients, signature (1,3,-3,-3,3,1,-1).
FORMULA
a(n) = (n*(1-(-1)^n+2*(-1+(-1)^n)*n+2*n^2))/8. G.f.: x^2*(x^4+x^3+7*x^2+x+2) / ((x-1)^4*(x+1)^3). - Colin Barker, Sep 20 2013
a(n) = n*A008794(n). - R. J. Mathar, Mar 04 2018
Sum_{n>=2} 1/a(n) = zeta(3)/2 + zeta(2) + 4*(log(2)-1). - Amiram Eldar, May 15 2024
MATHEMATICA
Table[n Floor[n/2]^2, {n, 0, 50}] (* or *) LinearRecurrence[ {1, 3, -3, -3, 3, 1, -1}, {0, 0, 2, 3, 16, 20, 54}, 50] (* Harvey P. Dale, May 31 2014 *)
PROG
(Magma) [n*Floor(n/2)^2: n in [0..50]]; // Vincenzo Librandi, May 31 2014
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
N. J. A. Sloane, Sep 22 2006
STATUS
approved