Maths Olympiad Prep

Library / /3 of 4

Combinatorics Difficulty 6.5 National Olympiad Prove it Italy

Problem:
A museum has a square floor plan and is divided into n2n^{2} identical square rooms (with n>1n>1). Every pair of adjacent rooms (i.e., sharing a common wall) communicates by means of a door (as shown in the example alongside for n=4n=4). The night watchman wants to organize his inspection tour so as to respect the following rules: the watchman starts from a certain room, where he stays for one minute, at the end of which he moves to an adjacent room, where he stays for another minute; the path
Figure 1
continues connecting adjacent rooms, in each of which the watchman stays for exactly one minute before moving on.
It is allowed to pass through the same room more than once, but at the end of the path (which is not necessarily in the starting room) the watchman must have been in each of the n2n^{2} rooms for exactly kk minutes.
Determine for which positive integers nn and kk it is possible to organize the path while respecting these rules.

Solution

Solution:
If nn is even, it is possible to construct the path for any kk. Indeed, one can exhibit a closed path that passes once through each room, and by making kk loops one obtains the watchman's journey.
Let us assume for convenience that the museum is oriented along the cardinal points. One way to construct this path is as follows: the watchman starts from the room in the south-west corner and proceeds along the south side until reaching the south-east corner.
Figure 2
At this point he still has to cross the rooms of an (n1)×n(n-1) \times n rectangle, which he traverses in a serpentine manner. He moves north for n1n-1 rooms (see example above for n=4n=4), then he shifts west and goes back south for n2n-2 rooms. At this point he has crossed the two easternmost rows of rooms. If he shifts west and repeats the procedure, since nn is even, he crosses all the rows of rooms in pairs and can eventually return to the room from which he started.
If instead nn is odd, the problem has a solution only for k=1k=1. In this case it is easy to find the path, which however does not return to the starting point, by making a serpentine in the manner described above. To see that in the other cases there is no solution, let us think of coloring the rooms white and black, as on a chessboard, with black in the corners. It is easy to see that in this way the black rooms are one more than the white ones. Consequently, if the watchman could make a path that passes kk times through each room, he should have visited kk black rooms more than white ones. However he can
Figure 3
move from one room only to another of a different color, so the difference between black and white rooms visited can be at most 1 during the journey, and for k>1k>1 there is no solution.

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: MathNet, licensed CC-BY-4.0. Statement translated into English from it; metadata (topic, difficulty) added by this project.