|
|
A240949
|
|
Number of partitions of n with the property that if two summands have the same parity, then their frequencies have the same parity.
|
|
1
|
|
|
1, 1, 2, 3, 5, 6, 11, 11, 21, 20, 38, 31, 67, 51, 107, 83, 172, 126, 263, 192, 399, 299, 584, 437, 857, 648, 1218, 941, 1743, 1351, 2438, 1912, 3399, 2708, 4672, 3750, 6439, 5193, 8712, 7113, 11815, 9678, 15836, 13056, 21186, 17609, 28080, 23438, 37210, 31181, 48819, 41182, 64039, 54188, 83374, 70923, 108364, 92587
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
COMMENTS
|
The parities of all even parts must be equal and the parities of all odd parts must be equal.
|
|
LINKS
|
|
|
EXAMPLE
|
For example: for n=5 the partition 3,1,1 is not counted, because 3 and 1 have the same parity, but the frequency of 3 and the frequency of 1 have different parity.
|
|
MATHEMATICA
|
<<Combinatorica`;
For[n=1, n<=66, n++, Print[]; Print["n= ", n];
p={n};
count=1;
For[k=1, k<=PartitionsP[n]-1, k++,
p=NextPartition[p];
tallyp=Tally[p];
condition=True;
For[i=1, i<=Length[tallyp]-1, i++,
For[j=i+1, j<=Length[tallyp], j++,
If[(Mod[tallyp[[i]][[1]], 2]==Mod[tallyp[[j]][[1]], 2])&&(Mod[tallyp[[i]][[2]], 2]!= Mod[tallyp[[j]][[2]], 2]), condition=False]]]
If[condition, count++]];
Print[count]];
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|