OFFSET
0,1
COMMENTS
Summation of n^2 taken 4 at a time. - Al Hakanson (hawkuu(AT)gmail.com), May 20 2009
Terms are congruent to (2,0,0) mod 6. - Ezhilarasu Velayutham, Apr 04 2019
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..1000
Patrick De Geest, Palindromic Sums of Squares of Consecutive Integers.
Index entries for linear recurrences with constant coefficients, signature (3,-3,1).
FORMULA
a(n) = 4*n^2 + 12*n + 14. - Al Hakanson (hawkuu(AT)gmail.com), May 20 2009
a(n) = a(n-1) + 8*(n+1) for n>0, a(0)=14. - Vincenzo Librandi, Nov 19 2010
G.f.: 2*(7-6*x+3*x^2)/(1-x)^3. - Colin Barker, Feb 17 2012
From Jean-Christophe Hervé, Nov 11 2015: (Start)
a(n) = (2*n+3)^2 + 5 = A016754(n+1) + 5, hence a(n) is never square.
The last formula defines a(n) for n < 0; then we have a(-n) = a(n-3) for all n. (End)
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3). - Wesley Ivan Hurt, Apr 16 2021
E.g.f.: 2*(7 + 8*x + 2*x^2)*exp(x). - G. C. Greubel, Aug 25 2022
Sum_{n>=0} 1/a(n) = tanh(sqrt(5)*Pi/2)*Pi/(4*sqrt(5)) - 1/6. - Amiram Eldar, Sep 15 2022
MATHEMATICA
Table[n^2 + (n + 1)^2 + (n + 2)^2 + (n + 3)^2, {n, 0, 42}] (* Alonso del Arte, Feb 17 2012 *)
Table[Total[Range[n, n+3]^2], {n, 0, 50}] (* or *) LinearRecurrence[{3, -3, 1}, {14, 30, 54}, 50] (* Harvey P. Dale, Jan 23 2017 *)
Total/@Partition[Range[0, 50]^2, 4, 1] (* Harvey P. Dale, Feb 08 2020 *)
PROG
(Sage) [i^2+(i+1)^2+(i+2)^2+(i+3)^2 for i in range(0, 50)] # Zerinvary Lajos, Jul 03 2008
(PARI) vector(100, n, n--; n^2+(n+1)^2+(n+2)^2+(n+3)^2) \\ Altug Alkan, Nov 11 2015
(Magma) [2*(2*n^2 +6*n +7): n in [0..50]]; // G. C. Greubel, Aug 25 2022
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved