login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A098077 a(n) = n^2*(n+1)*(2*n+1)/3. 10
2, 20, 84, 240, 550, 1092, 1960, 3264, 5130, 7700, 11132, 15600, 21294, 28420, 37200, 47872, 60690, 75924, 93860, 114800, 139062, 166980, 198904, 235200, 276250, 322452, 374220, 431984, 496190, 567300, 645792, 732160, 826914, 930580, 1043700 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
Sum of all matrix elements M(i,j) = i^2 + j^2 (i,j = 1,...,n).
From Torlach Rush, Jan 05 2020: (Start)
a(n) = n * A006331(n).
tr(M(n)) = A006331(n).
The sum of the antidiagonal of M(n) equals tr(M(n)).
M(n) = M(n)' (Symmetric).
M(1,) = M(,1) = A002522(n), n > 0.
M(2,) = M(,2) = A087475(n), n > 0.
M(3,) = M(,3) = A189834(n), n > 0.
M(4,) = M(,4) = A241751(n), n > 0.
(End)
Consider the partitions of 2n into two parts (p,q) where p <= q. Then a(n) is the total volume of the family of rectangular prisms with dimensions p, p and p+q. - Wesley Ivan Hurt, Apr 15 2018
LINKS
FORMULA
a(n) = Sum_{j=1..n} Sum_{i=1..n} (i^2 + j^2).
G.f.: 2*x*(1 + 5*x + 2*x^2)/(1-x)^5. - Colin Barker, May 04 2012
E.g.f.: (1/3)*exp(x)*x*(6 + 24*x + 15*x^2 + 2*x^3) . - Stefano Spezia, Jan 06 2020
a(n) = a(n-1) + (8*n^3 - 3*n^2 + n)/3. - Torlach Rush, Jan 07 2020
From Amiram Eldar, May 31 2022: (Start)
Sum_{n>=1} 1/a(n) = Pi^2/2 + 24*log(2) - 21.
Sum_{n>=1} (-1)^(n+1)/a(n) = Pi^2/4 - 6*Pi - 6*log(2) + 21. (End)
From G. C. Greubel, Apr 09 2023: (Start)
a(n) = (1/4)*A100431(n-1).
a(n) = 2*A108678(n-1). (End)
EXAMPLE
a(2) = (1^2 + 1^2) + (1^2 + 2^2) + (2^2 + 1^2) + (2^2 + 2^2) = 2 + 5 + 5 + 8 = 20.
MATHEMATICA
Table[ Sum[i^2 + j^2, {i, n}, {j, n}], {n, 35}]
LinearRecurrence[{5, -10, 10, -5, 1}, {2, 20, 84, 240, 550}, 40] (* Vincenzo Librandi, Apr 16 2018 *)
PROG
(PARI) a(n)=n^2*(n+1)*(2*n+1)/3 \\ Charles R Greathouse IV, Oct 07 2015
(Magma) [n^2*(n+1)*(2*n+1)/3: n in [1..40]]; // G. C. Greubel, Apr 09 2023
(SageMath) [n^2*(n+1)*(2*n+1)/3 for n in range(1, 41)] # G. C. Greubel, Apr 09 2023
CROSSREFS
Sequence in context: A135188 A161007 A331760 * A279264 A063663 A071253
KEYWORD
nonn,easy
AUTHOR
Alexander Adamchuk, Oct 24 2004
EXTENSIONS
More terms from Robert G. Wilson v, Nov 01 2004
New definition from Ralf Stephan, Dec 01 2004
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 09:23 EDT 2024. Contains 371782 sequences. (Running on oeis4.)