Maths Olympiad Prep

Library / Silk Road Mathematics Competition competition problems /22 of 25

Silk Road Mathematics Competition competition problems

Number theory Difficulty 6.9 National Olympiad Prove it Silk Road Mathematics Competition

The numbers 22, 33, 55, …\ldots, 20032003 are written on the board (here listed all prime numbers from the segment [2;2007][2; 2007]). By operation of simplification we call a changing of two numbers aa, bb by maximal prime number not exceeding a2−ab+b2\sqrt{a^2 - ab + b^2}. At the beginning student removes the number qq, 2<q<20032 < q < 2003, and then repeats the simplification operation until the board contains at least two numbers. Find the maximal and minimal possible values of the number which he obtain at the end. How these values depend on qq?

Solution

Note that a<a2−ab+b2<ba < \sqrt{a^2 - ab + b^2} < b if a<ba < b. That's why simplification of two successive prime numbers is equivalent to removing the maximal (from that two) number. If between prime numbers a<ba < b there is exactly one prime number cc, then operation of simplification to pair (a,b)(a, b) gives aa or cc. Hence, the "hole" between aa and bb can vanish or move down to one "step".

The maximal possible value is 19991999, and this value doesn't depend on first removed number 2<q<20032 < q < 2003. The algorithm of getting this number can be described as a repeating the operation of simplification to the maximal numbers of the set, except the number 20032003. Before the last operation board will have a pair 22, 20032003 or 33, 20032003. And last simplification gives 19991999.

Algorithm of getting the minimal number can be described as a repeating the operation of simplification to the maximal numbers of the set. If the "hole" obtained by removing the number qq disappear at some step, then we get the minimal number 22, else 33.

It is easy to see that the "hole" vanishes if q≥17q \ge 17. In that case the minimal number is equal to 22. On the other hand, if 3≤q≤133 \le q \le 13 then easy analysis shows that it vanishes for all steps of student; in this case, the minimal number is equal to 33.

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

Source: MathNet, licensed CC-BY-4.0. Statement reproduced verbatim; metadata (topic, difficulty) added by this project.