An Extension to a problem of IMO 1986

187 Views Asked by At

To each vertex of a pentagon, we assign an integer $x_i$ with sum $$s=\sum x_i>0$$ If $x$, $y$, $z$ are the numbers assigned to three successive vertices and if $y<0$ , then we replace $(x, y, z)$ by $(x+y, -y, z+y)$. This step is repeated as long as there is a $y<0$. Decide if the algorithm always stop .

I know this question is already asked, but my question is, how much steps are needed until stop??

2

There are 2 best solutions below

3
On

Consider a finite miultiset $S$ of all sums defined by $$s(i, j)= \sum_{k=i}^{j-1}x_k,$$ where $1≤i≤5$ and $j>i$.

A multiset is a set which can have equal elements.

In this set, all elements, except for one, either remain invariant or are switched with others. Only $s(4, 5)=x_4$; however, if $x_4<0$ then we have $s(4, 5) = -x_4$. Thus, exactly one negative element of $S$ becomes positive for each step. Since $s > 0$, $S$ contains only finitely many negative elements. The number of steps until stop is equal to the number of negative elements of $S$. We see that the $x_i$ need not be integers.

6
On

Consider $M$ to be the sum of squares of the difference across diagonals (I believe it is more elegant than the one proposed here by @Batominovski), i.e., $$ M(x)=(x_1-x_3)^2+(x_2-x_4)^2+(x_3-x_5)^2+(x_4-x_1)^2+(x_5-x_2)^2 $$ Then $M(x)\in\mathbb{N}$, and if $(x'_{i-2},x'_{i-1},x'_i,x'_{i+1},x'_{i+2})=(x_{i-2},x_{i-1}+x_i,-x_i,x_{i+1}+x_i,x_{i+2})$ (subscripts interpreted mod 5) we have $$ M(x')=M(x)+2sx_i $$ (see the solution by @IvanLoh as @MartinR linked in the comments for details) so for $x_i<0$ this process strictly decreases $M$. So at most $\lfloor M/(2s)\rfloor$ steps are needed.