|
EXAMPLE
|
Consider n = 3; then the multiset {0} has 0 as the sum of any subset; {1} has a subset with sum 0 (the empty set) and one with sum 1; {2} has one with sum 0 and one with sum 2; {1,1} has sums 0, 1, and 2 represented. Thus {0}, {0,1}, {0,2}, {0,1,2} are possible values for the set of subset sums (mod 3). Conversely, any S has a subset whose sum is 0 (viz. the empty set), so these are all the possible sets of subset sums; there are 4 of them.
Note that n = 6 is the smallest value for which there exists a subset of Z/nZ, containing 0, which is not a set of subset sums.
|