OFFSET
1,5
COMMENTS
A partition [x(1),x(2),...,x(k)] of n has constant reversal sums if x(1) + x(k) = x(2) + x(k-1) = ... = x(k) + x(1). and nonconstant reversal sums otherwise. It is assumed that x(1) <= x(2) <= ... <= x(k).
LINKS
Giovanni Resta, Table of n, a(n) for n = 1..1000
FORMULA
a(n) = p(n) - sum of C(floor(n/d)+floor(d/2)-1,floor(d/2)) where C(n,k) denotes the binomial coefficient and d ranges among the divisors of 2*n. - Giovanni Resta, Jan 24 2014
EXAMPLE
Of the 11 partitions of 6, the 3 nonconstant reversal sums are listed here: [1,1,4] + [4,1,1] = [5,2,5];
[1,1,1,3] + [3,1,1,1] = [4,2,2,4];
[1,1,1,1,2] + [2,1,1,1,1] = [3,2,2,2,3].
The remaining 8 partitions of 6 have constant reversal sums.
MATHEMATICA
u = Map[Length[Select[Map[DeleteDuplicates, Map[Reverse, #] + #], Length[#] == 1 &] &[IntegerPartitions[#]]] &, Range[40]] (*A236129*)
Table[PartitionsP[n] - u[[n]], {n, 1, 40}] (*A236170*)
(* Peter J. C. Moses, Jan 19 2014 *)
a[n_] := PartitionsP[n] - Sum[ Binomial[Floor[n/d] + Floor[d/2] - 1, Floor[d/2]], {d, Divisors[2*n]}] (* Giovanni Resta, Jan 24 2014 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Jan 19 2014
STATUS
approved