Maths Olympiad Prep

Library / Progetto Olimpiadi della Matematica /11 of 28

Progetto Olimpiadi della Matematica

Number theory Difficulty 5.5 AIME, harder Prove it Italy

Problem:

How many are the ordered pairs (x,y)(x, y) of positive integers less than or equal to 20192019 such that x+yx+y and xy+1x y+1 are powers of 22?

Solution

Solution:

The answer is 3737. Suppose x=yx = y. Then we get x2+1x^2 + 1 even, hence xx odd. But 2x2x with xx odd is a power of two if and only if x=1x = 1.

Now we just need to count all the pairs (x,y)(x, y) that satisfy the hypotheses with x<yx < y. This means that there exist two positive integers aa and bb such that x+y=2ax + y = 2^a and xy+1=2bx y + 1 = 2^b. Since (x−1)(y−1)≥0(x-1)(y-1) \geq 0, we have b≥ab \geq a.

From the second equation we deduce that both numbers are odd, so there exists an odd kk such that x=2a−1−kx = 2^{a-1} - k and y=2a−1+ky = 2^{a-1} + k. Substituting into the second equation we obtain 22a−2−k2+1=2b2^{2a-2} - k^2 + 1 = 2^b. Since k=2m+1k = 2m + 1 we have 4m(m+1)=22a−2−2b=2b(22a−2−b−1)4m(m+1) = 2^{2a-2} - 2^b = 2^b (2^{2a-2-b} - 1) which implies m(m+1)=2b−2(22a−2−b−1)m(m+1) = 2^{b-2}(2^{2a-2-b} - 1).

At this point if m=0m = 0 we get that the pairs of the form (2a−1−1,2a−1+1)(2^{a-1} - 1, 2^{a-1} + 1), together with their symmetric counterparts, satisfy the requirements. They number 2⋅10=202 \cdot 10 = 20, because the exponents aa between 22 and 1111 work.

Alternatively we have m≥1m \geq 1. The factors mm and m+1m+1 are coprime, so one of the two is divisible by 2b−22^{b-2}. In both cases we have that m≥2b−2−1m \geq 2^{b-2} - 1. But then 2b−2(22a−2−b−1)=m(m+1)≥2b−2(2b−2−1)2^{b-2}(2^{2a-2-b} - 1) = m(m+1) \geq 2^{b-2}(2^{b-2} - 1) and thus 2a−2−b≥b−22a-2-b \geq b-2 which implies a≥ba \geq b. But we had already observed that b≥ab \geq a, hence a=ba = b, that is (x−1)(y−1)=0(x-1)(y-1) = 0 and so the pairs are of the type (1,2a−1)(1, 2^a - 1), together with their symmetric counterparts. They are 2⋅10−1=192 \cdot 10 - 1 = 19, since the exponents aa between 11 and 1010 work, but we must count (1,1)(1, 1) only once, hence the −1-1.

However we must be careful that we have counted some solutions both in this family and in the previous one, namely (1,3)(1, 3) and (3,1)(3, 1). The total number of pairs satisfying the requirements is therefore 20+19−2=3720 + 19 - 2 = 37.

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 translated into English from it; metadata (topic, difficulty) added by this project.