login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A025112
a(n) = s(1)s(n) + s(2)s(n-1) + ... + s(k)s(n-k+1), where k = floor(n/2), s = (odd natural numbers).
0
3, 5, 22, 30, 73, 91, 172, 204, 335, 385, 578, 650, 917, 1015, 1368, 1496, 1947, 2109, 2670, 2870, 3553, 3795, 4612, 4900, 5863, 6201, 7322, 7714, 9005, 9455, 10928, 11440, 13107, 13685, 15558, 16206, 18297, 19019, 21340, 22140, 24703, 25585, 28402, 29370, 32453
OFFSET
2,1
COMMENTS
Sum of the areas of all rectangles with distinct odd side lengths r and s such that r + s = 2n. - Wesley Ivan Hurt, Apr 21 2020
FORMULA
a(n) = n*(4*n^2 - 3*n + 2 + 3*n*(-1)^n)/12. - Luce ETIENNE, Jan 07 2015
G.f.: x^2*(3 + 2*x + 8*x^2 + 2*x^3 + x^4)/((1+x)^3*(1-x)^4). - Robert Israel, Jan 13 2015
a(n) = Sum_{i=1..n-1} i * (2*n-i) * (i mod 2). - Wesley Ivan Hurt, Apr 21 2020
EXAMPLE
For n=2, k=1, and a(n) = s(1)*s(2) = 1*3 = 3.
MAPLE
seq( n*(4*n^2 - 3*n + 2 + 3*n*(-1)^n)/12, n=2..30); # Robert Israel, Jan 13 2015
PROG
(PARI) vector(40, n, sum(k=1, n\2, (2*k-1)*(2*(n-k+1)-1))) \\ Michel Marcus, Jan 07 2015
(PARI) a(n)=n*(2*n^2 - n%2*3*n + 1)/6 \\ Charles R Greathouse IV, Jan 15 2015
CROSSREFS
Sequence in context: A147442 A370580 A025093 * A203192 A025098 A025117
KEYWORD
nonn,easy
EXTENSIONS
Offset corrected by Michel Marcus, Jan 13 2015
STATUS
approved