OFFSET
1,3
FORMULA
a(n) = Sum_{i=2..n} sign( c(i-1) + c(i+1) + c(2*n-i-1) + c(2*n-i+1) ), where c is the square characteristic (A010052).
EXAMPLE
a(6) = 4; There are 6 partitions of 2*6 = 12 into two parts, (11,1), (10,2), (9,3), (8,4), (7,5) and (6,6). Since 10-1 = 9 (square), 3+1 = 4 (square), 8+1 = 9 (square), and 5-1 = 4 (square), then a(6) = 4.
MATHEMATICA
Table[Sum[Sign[(Floor[Sqrt[i - 1]] - Floor[Sqrt[i - 2]]) + (Floor[Sqrt[2 n - i - 1]] - Floor[Sqrt[2 n - i - 2]]) + (Floor[Sqrt[i + 1]] - Floor[Sqrt[i]]) + (Floor[Sqrt[2 n - i + 1]] - Floor[Sqrt[2 n - i]])], {i, 2, n}], {n, 100}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Wesley Ivan Hurt, Sep 19 2020
STATUS
approved