OFFSET
0,2
LINKS
Colin Barker, Table of n, a(n) for n = 0..1000
M. M. Ahmed, Algebraic Combinatorics of Magic Squares, math.CO/0405476, p73.
R. P. Stanley, Examples of Magic Labelings, Unpublished Notes, 1973 [Cached copy, with permission]
Index entries for linear recurrences with constant coefficients, signature (6,-14,14,0,-14,14,-6,1).
FORMULA
G.f.: (1+2*x+6*x^2+2*x^3+x^4)/((1-x)^7*(1+x)). [Stanley] - N. J. A. Sloane, Jul 07 2014
From Colin Barker, Jan 13 2017: (Start)
a(n) = (15*(31+(-1)^n) + 1152*n + 1216*n^2 + 720*n^3 + 250*n^4 + 48*n^5 + 4*n^6) / 480.
a(n) = 6*a(n-1) - 14*a(n-2) + 14*a(n-3) - 14*a(n-5) + 14*a(n-6) - 6*a(n-7) + a(n-8) for n>7.
(End)
MAPLE
a := proc(r) local r2 ; r2 := r^6/120+r^5/10+25*r^4/48+3*r^3/2+38*r^2/15+12*r/5 ; if r mod 2 = 0 then r2+1 ; else r2+15/16 ; fi ; end: for n from 0 to 40 do printf("%d ", a(n)) ; od;
MATHEMATICA
(1 + 2*x + 6*x^2 + 2*x^3 + x^4)/((1 - x)^7*(1 + x)) + O[x]^40 // CoefficientList[#, x]& (* Jean-François Alcover, Apr 01 2018 *)
PROG
(PARI) Vec((1+2*x+6*x^2+2*x^3+x^4)/((1-x)^7*(1+x)) + O(x^40)) \\ Colin Barker, Jan 13 2017
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
R. J. Mathar, Jan 25 2007
EXTENSIONS
Stanley reference added by N. J. A. Sloane, Jul 07 2014
STATUS
approved