Assignment Solution - INMO - Invariance

Download as pdf or txt
Download as pdf or txt
You are on page 1of 5

Mathematics INMO Basics

1. 23 Friends want to play soccer. For this they choose a referee and the other split into two teams of 11
persons each. They want to do this so that the total weight of each team is the same. We know that
they all have integer weights and that, regardless of who is the referee, it is possible to make the two
teams. Prove that they all have the same weight.
Solution:
Let a1, a2, ....., a23 denote the weights of the persons.
Let S = a1 + a2 + …. + a23. The condition tells us that if we remove the person with weight ai, the rest
can be split into two teams of weight X. Thus S – ai = 2X. This tells us that ai and S have the same
parity. Since this can be done for any ai, they are all even or all odd. We are going to generate another
list b1, b2, …., b23 of new weights that still satisfies the conditions of the problem. If the ai a r e e v e n
a
we replace each one by b i = i . If they are odd, we replace each one by b i = a i – 1.
2
It is clear that the new list of weights satisfies the conditions of the original problem, and that bi ≥ 0
for all i. If the ai were not all 0, then the sum of the weights bi is stricity smaller.
If we keep repeating this step we are always reducing the sum of the weights, so eventually we reach a
list of only zeros. Since we are able to do this, we conclude the numbers in the original list were all
equal.

2. A maze consists of a finite grid of squares where the boundary and some internal edge are “walls” that
cannot be crossed. For example”

Two mazes are given, each with a robot in the top - left square. You may give a list of directions (up,
down, left or right) to the robots. Both robots will independently follow the same list of directions. For
each direction, the robot will move one square in that direction if it can, or do nothing if there is a wall
in the way. It will then proceed to the next direction, and repeat until it has gone through the whole
list. Suppose that there is a list of direction that will get each robot individually from the top - left
corner to the bottom - right corner of its maze. Prove there is also a list of directions that will get both
robots to the bottom - right corner at the same time.
In the example mazes above, you could give directions ‘Right’, ‘Right’, ‘Down’, ‘Down’, ‘Down’,
‘Right’, Down’, ’Down’, ‘Left’, ‘Down’, Right’.

Solution:
The following algorithm works:
1. Give a minimal list of directions that will get robot 1 to the bottom right corner from its current
position.
2. If Robot 2 is not also in the bottom - right corner, give a minimal list of directions that will get it to
the bottom right corner from its current position.
3. If Robot 1 is no longer in the bottom - right corner, repeat from Step 1.
After each phase of the algorithm, we will have one robot R at the bottom - right corner whistle the
other robot R’ is x steps away for some x. During the next phase of the algorithm, we will take exactly
x steps and move R’ to the bottom - right corner. Note that R’ will end up below or right of where it
started.
Let’s consider what happened to R during this time. It started at the bottom - right corner and
attempted x steps. If it never hit a wall, then it would have moved the same amount right and down as
R’ did and so in particular, it would also need to end up below or right of where it started. However,
that is impossible since it started in the bottom - right corner. Thus, R must have successfully taken at
most x – 1 steps during this phase, and so must now be at most x – 1 steps from the bottom - right
corner.
Thus x goes down during each phase. Since it is a non - negative integer, it must eventually reach 0
and we are done.

3. Several stones are placed on an infinite (in both directions) strip of squares. As long as there are at
least two stones on a single square, you may pick up two such stones, then move one to the preceding
square and one to the following square. It is possible to return to the starting configuration after a
finite sequence of such moves?

Solution:
Label the strip with consecutive integers, and let ni denote the label of the square containing stone i.
Let X =  n i2 and consider what happens to X each time we do a move. First X decreases by 2t2 as
i

we remove two stones from some square t.


Next, X increases by (t – 1)2 + (t + 1)2 = 2t2 + 2 as we replace the stones in squares t – 1 and t + 1.
Therefore, every move causes X to increase by exactly 2.
In particular, after any sequence of moves, X will always be higher than where it began, so we could
not possibly be in the same position we began in

4. A teacher wrote down three positive real numbers on the blackboard and told Dima to decrease one of
them by 3%, decreases another by 4% and increase the last by 5%. Dima wrote down the results in his
notebook. It turned out that he wrote down the same three numbers that are on the blackboard, just in
different order. Prove that Dima must have made a mistake.

Solution:
If the initial numbers are x, y and z, the correct solutions are 0.97x, 0.96y and 1.05z, so their product
changes from xyz to 0.97776xyz. Therefore the answer can never be the same as the original numbers
in a different order.

5. At a party, some pairs of people shake hands. We call a person odd who has shaken hands with an odd
number of other guests. Prove that there is an even number of odd people at the party.

Solution:
The total number of ordered pairs of people who have shaken hands is even: each handshake between
A and B produce two ordered pairs(A, B) and (B, A). We can also find this total by adding up the
number of times each guest has shaken hands. If the total is even, an even number of the summands
are odd.
6. Seven squares of an 8 × 8 grid are shaded. At each step, we shade in each unshaded square that has at
least two shaded neighboring squares (horizontally or vertically). Prove that this process cannot end in
the entire grid being shaded.

Solution:
Our invariant here is total perimeter of the shaded squares (not counting borders between two shaded
squares). Initially , this is at most 7 × 4 = 28. When a square is shaded by the given rules, the total
perimeter cannot increase: the newly shaded square is adjacent to at least 2 already shaded squares, so
we lose at least 2 borders and gain at most 2.
We cannot end with the entire grid being shaded, because then the total perimeter would have
increased to 32, which cannot happen.

7. Let S be a finite set of at least two points in the plane. Assume that no three points of S are collinear.
A windmill is a process that starts with a line l going through a single P ∈ S. The line rotates
clockwise about the pivot P until the first time that the line meets some other point belonging to S.
This point Q, takes over as the new pivot, and the line now rotates clockwise about Q until it meets a
point of S. This process continues indefinitely. Show that we can choose a point P in S and a line l
going through P such that the resulting windmill uses each point of S infinitely many times.

Solution:
Choose a coordinate system so that all points in S have distinct x - coordinates. Number the points
Pi = (xi, yi) of S by increasing x - coordinates: x1 < x2 < …. < xN.
In order to divide the set S into two halves, define n so that N = 2n + 1 + d where d = 0 for an odd
number of points and d = 1 for an even number of points
Start the “windmill” process with the line ℓ going vertically through the point Pn + 1. Attach a down -
up direction to this line so that we can color all points as follows. Points to the left ℓ (with lower x -
coordinates) are blue, the pivot point on ℓ is white and point to the right of ℓ (with higher x –
coordinates) are red. We have now n blue points, one white point and n + d red points.
After processing the “windmill” by 180 degrees, the line ℓ goes vertically up - down.
Now, points with lower x - coordinates are to the right of ℓ and colored red; points with higher x -
coordinates are to the left of ℓ and colored blue.
Note that at each pivot exchange, the old pivot point enters the same side of ℓ where the new pivot
point came from. This means that throughout the “windmill” process, the number of blue points and
the number of red points stay constant, respectively. We still have n blue points, one white points and
n + d red points. This means that the current pivot points is Pn + d.
Note that all blue and all red points changed their color from the start of the “windmill” process.
This implies that every point was a pivot at some stage of the rotation.
For every 180 degree of “windmill” rotation, the same argument applies all colored points must
change their color and hence be a pivot at some stage. Infinitely many rotations imply infinitely many
color changes. This complete the proof.
8 We assign an integer to each vertex of a regular pentagon, so that the sum of all is positive. If three
consecutive vertices have assigned numbers x, y, z, respectively we are allowed to change the
numbers (x, y, z) to (x + y, –y, z + y). This transformation is made as long as one of the numbers is
negative. Decide if this process always comes to an end.

Solution:
Let S be the sum of the absolute value of each set of adjacent vertices, so if the integers are
a, b, c, d, e, then S = |a| + |b| + |c| + |d| + |e| + |a + b| + |b + c| + |c + d| + |d + e| + |e + a| + |a + b + c| + |b
+ c + d| + |c + d + e| + |d + e + a| + |e + a + b| + |a + b + c + d| + |b + c + d + e| + |c + d + e + a| + |d +
e + a + b| + |e + a + b + c| + |a + b + c + d + e|. Then the operation reduces S, but S is a greater than
zero, so the process must terminate in a finite number of steps. So see that S is reduced, we can simply
write out all the terms. Suppose the integers are a, b, c, d, e before the operation and
a + b, –b, b + c, d, e after it. We find that we mostly get the same terms before and after (although not
in the same order), so that the sum S’ after the operation is S – |a + c + d + e| + |a + 2b + c + d + e|.
Certainly a + c + d + e > a – 2b + c + d + e since b is negative ,and a + c + d + e > – (a + 2b + c + e)
because a + b + c + d + e > 0.
S is not the only expression we can use.
If we take T = (a – c)2 + (b – d)2 + (c – e)2 + (d – a)2 + (e – b)2, then after replacing
a, b, c, by a + b, –b, b + c we get T’ = T + 2b (a + b + c + d + e) < T.

9. 2017 card, each having one red side and one white side, are arranged in row. Initially all cards show
their red sides. Two players play a game with alternating moves. Each move consists of choosing a
block of 50 consecutive cards, the leftmost of which is showing red, and turning them all over, so
those which showed red now show white and vice - versa. The last player who can make a legal move
wins.
(a) Does the game necessarily end?
(b) Does there exist a winning strategy for the starting player?

Solution:
Given a game position, let’s define its “size” to be the 2017 - digit number obtained by reading cards
from left - to - right and writing down a 1 for each red card and a 0 for each white card. A move will
cause a 1 in the size to switch to a 0, and the next 49 digit will swap between 0 and 1. Since the
leftmost digit goes down, the overall size is guaranteed to decrease every turn. The size is always a
positive integer that is less than 102017, so there will be at most 102017 turns and hence the game will
end.
(b) Let’s define a card to be “cool” if it is exactly 50n spots from the right - most end for some n.
Given a game position let’s define its “cool count” to be the number of cool cards that are red. Each
sequence of 50 consecutive cards contains one and only one cool card. Therefore, a position’s cool
count either decreases by one or increases by one each turn. In particular, its parity changes.

The cool count starts at 40 – an even number – and so it will always be odd on the second player’s
turn. This means that there will be at least one red cool card and so the second player always has at
least one legal move. Since this is always true, it’s impossible for the second player to lose and so, no
the first player does not have a winning strategy.

You might also like