login
A393406
Sum of the middle parts in the partitions of n into 3 parts whose largest part is odd.
2
0, 0, 0, 1, 0, 1, 2, 6, 5, 9, 9, 18, 18, 27, 29, 45, 42, 58, 63, 88, 87, 112, 114, 150, 152, 188, 194, 243, 240, 289, 300, 364, 365, 429, 435, 516, 522, 603, 615, 715, 714, 814, 833, 954, 959, 1080, 1092, 1236, 1248, 1392, 1412, 1581, 1584, 1753, 1782, 1978, 1989, 2185, 2205, 2430, 2450, 2675, 2705, 2961, 2970, 3226, 3267
OFFSET
0,7
FORMULA
a(n) = Sum_{j=1..floor(n/3)} Sum_{k=j..floor((n-j)/2)} k * ((n-j-k) mod 2).
a(n) = a(n-1) - a(n-2) + a(n-3) + a(n-4) - a(n-5) + 3*a(n-6) - 3*a(n-7) + 2*a(n-8) - 2*a(n-9) - 2*a(n-10) + 2*a(n-11) - 3*a(n-12) + 3*a(n-13) - a(n-14) + a(n-15) + a(n-16) - a(n-17) + a(n-18) - a(n-19).
a(n) + A393403(n) + A309692(n) = n*A026923(n). - Wesley Ivan Hurt, Feb 17 2026
a(n) ~ 5*n^3/432. - Charles R Greathouse IV, May 31 2026
EXAMPLE
a(11) = 18; There are 6 partitions of 11 into 3 parts whose largest part is odd: (9,1,1), (7,3,1), (5,5,1), (7,2,2), (5,4,2) and (5,3,3). The sum of the middle parts of these partitions is 1+3+5+2+4+3 = 18.
MATHEMATICA
Table[Sum[Sum[k*Mod[n - j - k, 2], {k, j, Floor[(n - j)/2]}], {j, Floor[n/3]}], {n, 0, 100}]
LinearRecurrence[{1, -1, 1, 1, -1, 3, -3, 2, -2, -2, 2, -3, 3, -1, 1, 1, -1, 1, -1}, {0, 0, 0, 1, 0, 1, 2, 6, 5, 9, 9, 18, 18, 27, 29, 45, 42, 58, 63}, 100]
PROG
(PARI) a(n)=(5*n^3+(-6+n%2*12)*n^2+[0, -27, 0, 81, -48, -75, 0, 81, 0, -27, -48, 33][n%12+1]*n+16*[0, 1, -1, 0, -2, 2, 0, 1, -1, 0, -2, 2][n%12+1])/432 \\ Charles R Greathouse IV, May 31 2026
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Wesley Ivan Hurt, Feb 13 2026
STATUS
approved