Browse · MathNet
Print67th NMO Selection Tests for JBMO
Romania counting and probability
Problem
We are given an grid and three colors. We wish to color each segment of the grid with one of the three colors so that each unit square has two sides of one color and two sides of a second color. How many such colorings are possible?
Solution
We label the lines from top to bottom and the columns from left to right. The leftmost side of the unit square in the upper-left corner can be colored in ways. Subsequently, there are ways of choosing the side of this unit square that is to receive the same color as the first side. The remaining two sides of the square have to be colored with the same color. This color can be chosen in ways. In conclusion, the unit square in the upper-left corner can be colored in ways.
Next, we successively color the unit squares in the first line, from left to right. Every time, the leftmost side of the square has already been colored. Thus, there are ways of coloring each of these squares. We proceed similarly on the first column. We color the unit squares from top to bottom and for each of these squares there are ways of coloring.
Now we move on to color the squares situated on rows and columns . We color them from top to bottom, from left to right. Thus, when in turn to be colored, each unit square has already two sides colored: the upper side and the leftmost side. If these sides have received different colors, then the colors of this square have already been decided; there are ways of coloring the remaining sides with these two colors. If the two sides that are already colored have the same color, then the remaining sides will receive the same color. This color can be chosen in ways. Therefore, for each of these squares, there are ways of coloring.
In conclusion, there are ways of coloring.
Next, we successively color the unit squares in the first line, from left to right. Every time, the leftmost side of the square has already been colored. Thus, there are ways of coloring each of these squares. We proceed similarly on the first column. We color the unit squares from top to bottom and for each of these squares there are ways of coloring.
Now we move on to color the squares situated on rows and columns . We color them from top to bottom, from left to right. Thus, when in turn to be colored, each unit square has already two sides colored: the upper side and the leftmost side. If these sides have received different colors, then the colors of this square have already been decided; there are ways of coloring the remaining sides with these two colors. If the two sides that are already colored have the same color, then the remaining sides will receive the same color. This color can be chosen in ways. Therefore, for each of these squares, there are ways of coloring.
In conclusion, there are ways of coloring.
Final answer
3^{m+n} * 2^{mn}
Techniques
Coloring schemes, extremal argumentsRecursion, bijection