The three-element subsets of a seven-element set are colored. If the intersection of two sets is empty then they have different colors. What is the minimum number of colors needed?
Solutions — 2
Solution 1
Let . Two colors are not enough because the sets in the following sequence of three-element subsets of should have alternating colors: , , , , , , , .
With three colors we can color, for example, the three-element subsets of as follows: we use
- the first color for all the subsets containing the element ;
- a second color for all the subsets that do not contain the element and for which the sum of their elements is even;
- a third color for all the remaining subsets.
Solution 2
We prove that the minimum number is . Assuming that a coloring with two colors was possible, let be the set of the three-element subsets colored with the first color, and be the set of the three-element subsets colored with the second color. For every subset there are subsets of that have to be in . If we represent the set of the three-element subsets as a graph in which we join two vertices (representing two three-element subsets of ) if they are disjoint, then every element of is joined with exactly elements of , and vice-versa. It follows that the total number of edges, i.e. the numbers of pairs of disjoint three-element subsets, is , hence . But then should be even, while in fact it is , which is odd, contradiction.
A coloring with three colors can be found as follows: we choose two arbitrary elements . We color the three-element subsets that do not contain neither nor with the first color, those that contain but do not contain with the second color, and finally the subsets that contain with the third color.