Maths Olympiad Prep

Library / /10 of 16

Number theory Difficulty 8.7 Shortlist Prove it IMO

Find all positive integers nn such that there exists a sequence of positive integers a1,a2,,ana_{1}, a_{2}, \ldots, a_{n} satisfying
ak+1=ak2+1ak1+11 a_{k+1}=\frac{a_{k}^{2}+1}{a_{k-1}+1}-1
for every kk with 2kn12 \leq k \leq n-1.

Solutions — 2

Solution 1

Such a sequence exists for n=1,2,3,4n=1,2,3,4 and no other nn. Since the existence of such a sequence for some nn implies the existence of such a sequence for all smaller nn, it suffices to prove that n=5n=5 is not possible and n=4n=4 is possible.

Assume first that for n=5n=5 there exists a sequence of positive integers a1,a2,,a5a_{1}, a_{2}, \ldots, a_{5} satisfying the conditions
a22+1=(a1+1)(a3+1),a32+1=(a2+1)(a4+1),a42+1=(a3+1)(a5+1). \begin{aligned} & a_{2}^{2}+1=\left(a_{1}+1\right)\left(a_{3}+1\right), \\ & a_{3}^{2}+1=\left(a_{2}+1\right)\left(a_{4}+1\right), \\ & a_{4}^{2}+1=\left(a_{3}+1\right)\left(a_{5}+1\right) . \end{aligned}
Assume a1a_{1} is odd, then a2a_{2} has to be odd as well and as then a22+12mod4,a3a_{2}^{2}+1 \equiv 2 \bmod 4, a_{3} has to be even. But this is a contradiction, since then the even number a2+1a_{2}+1 cannot divide the odd number a32+1a_{3}^{2}+1.

Hence a1a_{1} is even.
If a2a_{2} is odd, a32+1a_{3}^{2}+1 is even (as a multiple of a2+1a_{2}+1 ) and hence a3a_{3} is odd, too. Similarly we must have a4a_{4} odd as well. But then a32+1a_{3}^{2}+1 is a product of two even numbers (a2+1)(a4+1)\left(a_{2}+1\right)\left(a_{4}+1\right) and thus is divisible by 4 , which is a contradiction as for odd a3a_{3} we have a32+12mod4a_{3}^{2}+1 \equiv 2 \bmod 4.

Hence a2a_{2} is even. Furthermore a3+1a_{3}+1 divides the odd number a22+1a_{2}^{2}+1 and so a3a_{3} is even. Similarly, a4a_{4} and a5a_{5} are even as well.

Now set x=a2x=a_{2} and y=a3y=a_{3}. From the given condition we get (x+1)(y2+1)(x+1) \mid\left(y^{2}+1\right) and (y+1)(x2+1)(y+1) \mid\left(x^{2}+1\right). We will prove that there is no pair of positive even numbers (x,y)(x, y) satisfying these two conditions, thus yielding a contradiction to the assumption.

Assume there exists a pair ( x0,y0x_{0}, y_{0} ) of positive even numbers satisfying the two conditions (x0+1)(y02+1)\left(x_{0}+1\right) \mid\left(y_{0}^{2}+1\right) and (y0+1)(x02+1)\left(y_{0}+1\right) \mid\left(x_{0}^{2}+1\right).
Then one has (x0+1)(y02+1+x021)\left(x_{0}+1\right) \mid\left(y_{0}^{2}+1+x_{0}^{2}-1\right), i.e., (x0+1)(x02+y02)\left(x_{0}+1\right) \mid\left(x_{0}^{2}+y_{0}^{2}\right), and similarly (y0+1)(x02+y02)\left(y_{0}+1\right) \mid\left(x_{0}^{2}+y_{0}^{2}\right). Any common divisor dd of x0+1x_{0}+1 and y0+1y_{0}+1 must hence also divide the number (x02+1)+(y02+1)(x02+y02)=2\left(x_{0}^{2}+1\right)+\left(y_{0}^{2}+1\right)-\left(x_{0}^{2}+y_{0}^{2}\right)=2. But as x0+1x_{0}+1 and y0+1y_{0}+1 are both odd, we must have d=1d=1. Thus x0+1x_{0}+1 and y0+1y_{0}+1 are relatively prime and therefore there exists a positive integer kk such that
k(x+1)(y+1)=x2+y2 k(x+1)(y+1)=x^{2}+y^{2}
has the solution (x0,y0)\left(x_{0}, y_{0}\right). We will show that the latter equation has no solution (x,y)(x, y) in positive even numbers.

Assume there is a solution. Pick the solution (x1,y1)\left(x_{1}, y_{1}\right) with the smallest sum x1+y1x_{1}+y_{1} and assume x1y1x_{1} \geq y_{1}. Then x1x_{1} is a solution to the quadratic equation
x2k(y1+1)x+y12k(y1+1)=0 x^{2}-k\left(y_{1}+1\right) x+y_{1}^{2}-k\left(y_{1}+1\right)=0
Let x2x_{2} be the second solution, which by Vieta's theorem fulfills x1+x2=k(y1+1)x_{1}+x_{2}=k\left(y_{1}+1\right) and x1x2=y12k(y1+1)x_{1} x_{2}=y_{1}^{2}-k\left(y_{1}+1\right). If x2=0x_{2}=0, the second equation implies y12=k(y1+1)y_{1}^{2}=k\left(y_{1}+1\right), which is impossible, as y1+1>1y_{1}+1>1 cannot divide the relatively prime number y12y_{1}^{2}. Therefore x20x_{2} \neq 0.

Also we get (x1+1)(x2+1)=x1x2+x1+x2+1=y12+1\left(x_{1}+1\right)\left(x_{2}+1\right)=x_{1} x_{2}+x_{1}+x_{2}+1=y_{1}^{2}+1 which is odd, and hence x2x_{2} must be even and positive. Also we have x2+1=y12+1x1+1y12+1y1+1y1x1x_{2}+1=\frac{y_{1}^{2}+1}{x_{1}+1} \leq \frac{y_{1}^{2}+1}{y_{1}+1} \leq y_{1} \leq x_{1}. But this means that the pair ( x,yx^{\prime}, y^{\prime} ) with x=y1x^{\prime}=y_{1} and y=x2y^{\prime}=x_{2} is another solution of k(x+1)(y+1)=x2+y2k(x+1)(y+1)=x^{2}+y^{2} in even positive numbers with x+y<x1+y1x^{\prime}+y^{\prime}<x_{1}+y_{1}, a contradiction.

Therefore we must have n4n \leq 4.
When n=4n=4, a possible example of a sequence is a1=4,a2=33,a3=217a_{1}=4, a_{2}=33, a_{3}=217 and a4=1384a_{4}=1384.

Solution 2

It is easy to check that for n=4n=4 the sequence a1=4,a2=33,a3=217a_{1}=4, a_{2}=33, a_{3}=217 and a4=1384a_{4}=1384 is possible.

Now assume there is a sequence with n5n \geq 5. Then we have in particular
a22+1=(a1+1)(a3+1),a32+1=(a2+1)(a4+1),a42+1=(a3+1)(a5+1). \begin{aligned} & a_{2}^{2}+1=\left(a_{1}+1\right)\left(a_{3}+1\right), \\ & a_{3}^{2}+1=\left(a_{2}+1\right)\left(a_{4}+1\right), \\ & a_{4}^{2}+1=\left(a_{3}+1\right)\left(a_{5}+1\right) . \end{aligned}
Also assume without loss of generality that among all such quintuples (a1,a2,a3,a4,a5)\left(a_{1}, a_{2}, a_{3}, a_{4}, a_{5}\right) we have chosen one with minimal a1a_{1}.

One shows quickly the following fact:
 If three positive integers x,y,z fulfill y2+1=(x+1)(z+1) and if y is even, then x and z are even as well and either x<y<z or z<y<x holds.  \begin{align*} & \text{ If three positive integers } x, y, z \text{ fulfill } y^{2}+1=(x+1)(z+1) \text{ and if } y \text{ is even, then } \\ & x \text{ and } z \text{ are even as well and either } x<y<z \text{ or } z<y<x \text{ holds. } \tag{1} \end{align*}
Indeed, the first part is obvious and from x<yx<y we conclude
z+1=y2+1x+1y2+1y>y z+1=\frac{y^{2}+1}{x+1} \geq \frac{y^{2}+1}{y}>y
and similarly in the other case.

Now, if a3a_{3} was odd, then (a2+1)(a4+1)=a32+12mod4\left(a_{2}+1\right)\left(a_{4}+1\right)=a_{3}^{2}+1 \equiv 2 \bmod 4 would imply that one of a2a_{2} or a4a_{4} is even, this contradicts (1). Thus a3a_{3} and hence also a1,a2,a4a_{1}, a_{2}, a_{4} and a5a_{5} are even. According to (1), one has a1<a2<a3<a4<a5a_{1}<a_{2}<a_{3}<a_{4}<a_{5} or a1>a2>a3>a4>a5a_{1}>a_{2}>a_{3}>a_{4}>a_{5} but due to the minimality of a1a_{1} the first series of inequalities must hold.

Consider the identity
(a3+1)(a1+a3)=a321+(a1+1)(a3+1)=a22+a32=a221+(a2+1)(a4+1)=(a2+1)(a2+a4). \left(a_{3}+1\right)\left(a_{1}+a_{3}\right)=a_{3}^{2}-1+\left(a_{1}+1\right)\left(a_{3}+1\right)=a_{2}^{2}+a_{3}^{2}=a_{2}^{2}-1+\left(a_{2}+1\right)\left(a_{4}+1\right)=\left(a_{2}+1\right)\left(a_{2}+a_{4}\right) .
Any common divisor of the two odd numbers a2+1a_{2}+1 and a3+1a_{3}+1 must also divide ( a2+1a_{2}+1 )( a4+1)(a3+1)(a31)=2a_{4}+ 1)-\left(a_{3}+1\right)\left(a_{3}-1\right)=2, so these numbers are relatively prime. Hence the last identity shows that a1+a3a_{1}+a_{3} must be a multiple of a2+1a_{2}+1, i.e. there is an integer kk such that
a1+a3=k(a2+1). \begin{equation*} a_{1}+a_{3}=k\left(a_{2}+1\right) . \tag{2} \end{equation*}
Now set a0=k(a1+1)a2a_{0}=k\left(a_{1}+1\right)-a_{2}. This is an integer and we have
(a0+1)(a2+1)=k(a1+1)(a2+1)(a21)(a2+1)=(a1+1)(a1+a3)(a1+1)(a3+1)+2=(a1+1)(a11)+2=a12+1 \begin{aligned} \left(a_{0}+1\right)\left(a_{2}+1\right) & =k\left(a_{1}+1\right)\left(a_{2}+1\right)-\left(a_{2}-1\right)\left(a_{2}+1\right) \\ & =\left(a_{1}+1\right)\left(a_{1}+a_{3}\right)-\left(a_{1}+1\right)\left(a_{3}+1\right)+2 \\ & =\left(a_{1}+1\right)\left(a_{1}-1\right)+2=a_{1}^{2}+1 \end{aligned}
Thus a00a_{0} \geq 0. If a0>0a_{0}>0, then by (1) we would have a0<a1<a2a_{0}<a_{1}<a_{2} and then the quintuple ( a0,a1,a2,a3,a4a_{0}, a_{1}, a_{2}, a_{3}, a_{4} ) would contradict the minimality of a1a_{1}.

Hence a0=0a_{0}=0, implying a2=a12a_{2}=a_{1}^{2}. But also a2=k(a1+1)a_{2}=k\left(a_{1}+1\right), which finally contradicts the fact that a1+1>1a_{1}+1>1 is relatively prime to a12a_{1}^{2} and thus cannot be a divisior of this number.

Hence n5n \geq 5 is not possible.

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 and solution reproduced as published; topic and difficulty added by this site.