Maths Olympiad Prep

Library / /1 of 3

Algebra Difficulty 7.5 National Olympiad, round 2 Prove it Middle European Mathematical Olympiad (MEMO)

Problem:

A finite sequence x1,x2,,xrx_{1}, x_{2}, \ldots, x_{r} of positive integers is a palindrome if xi=xr+1ix_{i}=x_{r+1-i} for all integers 1ir1 \leq i \leq r.
Let a1,a2,a_{1}, a_{2}, \ldots be an infinite sequence of positive integers. For a positive integer j2j \geq 2, denote by a[j]a[j] the finite subsequence a1,a2,,aj1a_{1}, a_{2}, \ldots, a_{j-1}. Suppose that there exists a strictly increasing infinite sequence b1,b2,b_{1}, b_{2}, \ldots of positive integers such that for every positive integer nn, the subsequence a[bn]a\left[b_{n}\right] is a palindrome and bn+2bn+1+bnb_{n+2} \leq b_{n+1}+b_{n}. Prove that there exists a positive integer TT such that ai=ai+Ta_{i}=a_{i+T} for every positive integer ii.

Solutions — 4

Solution 1

Solution:

Define a break point to be a positive integer kk such that a[k]a[k] is a palindrome. Let c1<c2<c_{1}<c_{2}<\ldots be a strictly increasing sequence of all break points. Then cn+2cn+1+cnc_{n+2} \leq c_{n+1}+c_{n} also holds whenever cn+2>b2c_{n+2}>b_{2}. Namely, if bj1<cn+2bjb_{j-1}<c_{n+2} \leq b_{j}, then cn+1bj1c_{n+1} \geq b_{j-1} and cnbj2c_{n} \geq b_{j-2}.
For positive integers pp and qq, let pqp \sim q denote the fact that ap=aqa_{p}=a_{q}.
Let x,x+yx, x+y and x+y+zx+y+z be three consecutive break points greater than b2b_{2}. From the condition, we have zxz \leq x. Consider any positive integer r<xr<x.
Since xx is a break point, rxrr \sim x-r.
Since x+yx+y is a break point, xrx+y(xr)=y+rx-r \sim x+y-(x-r)=y+r.
Since x+y+zx+y+z is a break point, y+rx+zry+r \sim x+z-r.
Hence, rx+zrr \sim x+z-r for all r<xr<x. This implies that x+zx+z is also a break point, which means y=zy=z since we considered consecutive break points. Repeating this argument for the next three break points, we can conclude that there exists an arithmetic sequence of break points with common difference zz.
Let (x+nz)n(x+n z)_{n} be an arithmetic sequence of break points. Consider any positive integer rr. Let nn be a positive integer such that x+nz>rx+n z>r.
Since x+nzx+n z is a break point, rx+nzrr \sim x+n z-r.
Since x+(n+1)zx+(n+1) z is a break point, x+nzrx+(n+1)z(x+nzr)=z+rx+n z-r \sim x+(n+1) z-(x+n z-r)=z+r.
Hence, the sequence (an)n\left(a_{n}\right)_{n} is periodic with period zz, which proves the claim.

Solution 2

Solution:

Similarly to the first solution, xyx \sim y denotes that ax=aya_{x}=a_{y}. If we know that aa** is palindromic, then xbxx \sim b-x for all 0<x<b0<x<b. The notation a[x,y]a[x, y] denotes (ax,ax+1,,ay1)\left(a_{x}, a_{x+1}, \ldots, a_{y-1}\right). Throughout the proof, all variables denote integers.
We show that the sequence is periodic with b2b1b_{2}-b_{1}. Note that to show this, it suffices to show that a[bn]a\left[b_{n}\right] is periodic with b2b1b_{2}-b_{1} for all nn. So the problem statement follows from the following proposition.

Main proposition. a[bn+k]a\left[b_{n+k}\right] is periodic with bn+1bnb_{n+1}-b_{n} for all n,k1n, k \geq 1.
We prove the proposition by induction on kk.

The case k=1k=1. If 0<x<bn0<x<b_{n} then by palindromeness of a[bn]a\left[b_{n}\right] and a[bn+1]a\left[b_{n+1}\right], we have xbnxbn+1(bnx)=x+(bn+1bn)x \sim b_{n}-x \sim b_{n+1}-\left(b_{n}-x\right)=x+\left(b_{n+1}-b_{n}\right), so a[bn+1]a\left[b_{n+1}\right] is periodic with bn+1bnb_{n+1}-b_{n}.

The case k=2k=2. We prove the following helpful lemma:

Lemma. Suppose that t1t \geq 1 and 0<x<y0<x<y. If a[x]a[x] is periodic with tt, and a[y]a[y] is palindromic, and 2xyt2 x-y \geq t, then a[y]a[y] is periodic with tt too.

Proof of lemma. Since a[x]a[x] is periodic with tt, by palindromeness of a[y]a[y] we have that a[yx,y]a[y-x, y] is periodic with tt too. If the two segments a[x]a[x] and a[yx,y]a[y-x, y] overlap in at least tt elements, this means that all pairs of distance tt in a[y]a[y] will be contained in at least one of the segments, so a[y]a[y] is also periodic with tt. Here, the overlap is x(yx)=2xytx-(y-x)=2 x-y \geq t indeed.
To use the lemma here, pick t=bn+1bn,x=bn+1t=b_{n+1}-b_{n}, x=b_{n+1} and y=bn+2y=b_{n+2}. We already know that a[bn+1]a\left[b_{n+1}\right] is periodic with tt (by the k=1k=1 case), and we have 2xytbn+1+bnbn+22 x-y \geq t \Leftrightarrow b_{n+1}+b_{n} \geq b_{n+2} indeed, concluding the k=2k=2 case.

The case k3k \geq 3. To prove this case, we show that if a[bn+k1]a\left[b_{n+k-1}\right] is periodic with bn+1bnb_{n+1}-b_{n} and a[bn+k]a\left[b_{n+k}\right] is periodic with bn+2bn+1b_{n+2}-b_{n+1} (both true by the inductive hypothesis) then a[bn+k]a\left[b_{n+k}\right] is periodic with bn+1bnb_{n+1}-b_{n} too.
Let t=bn+1bnt=b_{n+1}-b_{n} and Δ=bn+2bn+1\Delta=b_{n+2}-b_{n+1}.
Then we can inductively show that a[bn+k1+Δ]a\left[b_{n+k-1}+\ell \Delta\right] is periodic with tt for all 0\ell \geq 0. For =0\ell=0 this is true by the k=1k=1 case. If for 1\ell \geq 1, we know that a[bn+k1+(1)Δ]a\left[b_{n+k-1}+(\ell-1) \Delta\right] is periodic with tt, then by the periodicity of a[bn+k]a\left[b_{n+k}\right] with Δ\Delta, we have that a[Δ,bn+k1+Δ]a\left[\Delta, b_{n+k-1}+\ell \Delta\right] is also periodic with tt. Also, the two tt-periodic intervals overlap in at least tt elements, as bn+k1+(2)Δbn+k1Δ=bn+k1bn+2+bn+1bn+1bnbn+k1+bnbn+2b_{n+k-1}+(\ell-2) \Delta \geq b_{n+k-1}-\Delta=b_{n+k-1}-b_{n+2}+b_{n+1} \geq b_{n+1}-b_{n} \Leftrightarrow b_{n+k-1}+b_{n} \geq b_{n+2}, true since from k3k \geq 3, bn+k1bn+2b_{n+k-1} \geq b_{n+2}. So a[bn+k1+Δ]a\left[b_{n+k-1}+\ell \Delta\right] is also periodic with tt.
Now choose \ell so that dΔbn+k1+Δbn+kd-\Delta \leq b_{n+k-1}+\ell \Delta \leq b_{n+k}, giving that we have some 0uΔ0 \leq u \leq \Delta with a[bn+ku]a\left[b_{n+k}-u\right] being tt-periodic. Now by palindromeness of a[bn+k]a\left[b_{n+k}\right], also a\text{a} is tt-periodic, and the two intervals' overlap is at least t:bn+k2ut2ubn+kbn+1+bnt: b_{n+k}-2 u \geq t \Leftrightarrow 2 u \leq b_{n+k}-b_{n+1}+b_{n}, and 2u2Δ=2bn+22bn+1bn+kbn+1+bn2bn+2bn+k+bn+1+bn2 u \leq 2 \Delta=2 b_{n+2}-2 b_{n+1} \leq b_{n+k}-b_{n+1}+b_{n} \Leftrightarrow 2 b_{n+2} \leq b_{n+k}+b_{n+1}+b_{n}, true since bn+2bn+kb_{n+2} \leq b_{n+k} and bn+2bn+1+bnb_{n+2} \leq b_{n+1}+b_{n}. So a[bn+k]a\left[b_{n+k}\right] is tt-periodic, finishing the proof.

Solution 3

Solution:

We will show that the sequence is periodic with bkbk1b_{k}-b_{k-1} where k2k \geq 2 is so that bkbk1=min1nbnbn1b_{k}-b_{k-1}=\min _{1 \leq n} b_{n}-b_{n-1}. First, we prove that bkb_{k} is periodic with bkbk1b_{k}-b_{k-1} :
xbk1xbkbk1+xx<bk1 x \sim b_{k-1}-x \sim b_{k}-b_{k-1}+x \quad \forall x<b_{k-1}
where we have used that bk1b_{k-1} and bkb_{k} are palindromic.
We will use the lemma from the above solution. Let's recall it.

Lemma. Suppose that t1t \geq 1 and 0<x<y0<x<y. If a[x]a[x] is periodic with tt, and a[y]a[y] is palindromic, and 2xyt2 x-y \geq t, then a[y]a[y] is periodic with tt too.

Let us apply the lemma repeatedly so that t=bkbk1,x=bn1t=b_{k}-b_{k-1}, x=b_{n-1} and y=bny=b_{n} for n=k+1,k+2,k+3,n= k+1, k+2, k+3, \ldots. The two conditions in the first sentence of the lemma are clearly satisfied at such applications, as well as that a[y]a[y] is palindromic.
The condition 2xyt2 x-y \geq t is equivalent to 2bn1bnbkbk12 b_{n-1}-b_{n} \geq b_{k}-b_{k-1}. Since nk2n \geq k \geq 2, we know that bn1+bn2bnb_{n-1}+b_{n-2} \geq b_{n}. Therefore bn1bnbn2b_{n-1}-b_{n} \geq-b_{n-2}. But since we chose kk so that bkbk1b_{k}-b_{k-1} is smallest, we have that 2xyt2 x-y \geq t is also satisfied at each application of the lemma.
The only remaining condition is that a[x]=a[bn1]a[x]=a\left[b_{n-1}\right] is periodic with period tt. However, since the lemma states that a[y]=a[bn]a[y]=a\left[b_{n}\right] is periodic with period tt, at each application of the lemma we get that this condition is also satisfied for the next application. Therefore we get that a[bn]a\left[b_{n}\right] is periodic with period bkbk1b_{k}-b_{k-1} for all nkn \geq k. This finishes the proof.

Solution 4

Solution:

This solution uses the following lemma.

Lemma. If a palindromic, finite sequence (an)n=1n=l\left(a_{n}\right)_{n=1}^{n=l} of length ll is periodic with periods xx and yy with x<yx<y and x+yl+1x+y \leq l+1, it is periodic with period yxy-x.

Proof. For rx1r \leq x-1, we have r+ylr+y \leq l and x<r+yx<r+y, so by periodicity with yy and xx, we have ar=ar+y=ar+yxa_{r}=a_{r+y}=a_{r+y-x}.
For x<rl(yx)x<r \leq l-(y-x), we have 1rxly1 \leq r-x \leq l-y, so by the periodicities we have ar=arx=arx+ya_{r}=a_{r-x}=a_{r-x+y}.
It remains to be proven that ax=aya_{x}=a_{y}. In case x+ylx+y \leq l, the first of the two above arguments works for r=xr=x and shows ax=aya_{x}=a_{y}, proving the lemma.
However, in case x+ylx+y \not l l, by the condition of the lemma we have x+y=l+1x+y=l+1. Then by the palindromic condition, ax=al+1x=aya_{x}=a_{l+1-x}=a_{y}. This finishes the proof of the lemma.

Comment. Via Euler's algorithm, we may use the lemma repeatedly to give that the sequence is periodic with gcd(x,y)\operatorname{gcd}(x, y).

As in the previous solution, we use that for all n2,a[bn]n \geq 2, a\left[b_{n}\right] is periodic with period bnbn1b_{n}-b_{n-1}. Then as a[bn]a\left[b_{n}\right] is a subsequence for a[bn+1]a\left[b_{n+1}\right], we have that a[bn]a\left[b_{n}\right] is also periodic with period bn+1bnb_{n+1}-b_{n}.
Now let's apply the lemma's remark for a[bn]a\left[b_{n}\right], which we know is palindromic. The two periods are bnbn1b_{n}-b_{n-1} and bn+1bnb_{n+1}-b_{n}. The condition x+yl+1x+y \leq l+1 translates to bn+1bn1bnb_{n+1}-b_{n-1} \leq b_{n} (noting that l=bn1l=b_{n}-1 ). However, this is satisfied by the problem statement, so we get that a[bn]a\left[b_{n}\right] is periodic with period gcd(bnbn1,bn+1bn)\operatorname{gcd}\left(b_{n}-b_{n-1}, b_{n+1}-b_{n}\right).
Recalling that a[bn+1]a\left[b_{n+1}\right] is periodic with period bn+1bnb_{n+1}-b_{n}, which is a multiple of the period we got for a[bn]a\left[b_{n}\right]. Since bn+1bnbn1bn1b_{n+1}-b_{n} \leq b_{n-1} \leq b_{n}-1, an entire larger period is contained in a[bn]a\left[b_{n}\right]. Then each larger period in a[bn+1]a\left[b_{n+1}\right] consists of smaller periods of length gcd(bnbn1,bn+1bn)\operatorname{gcd}\left(b_{n}-b_{n-1}, b_{n+1}-b_{n}\right) from a[bn]a\left[b_{n}\right], so a[bn+1]a\left[b_{n+1}\right] is also periodic with period gcd(bnbn1,bn+1bn)\operatorname{gcd}\left(b_{n}-b_{n-1}, b_{n+1}-b_{n}\right).
Then substituting n+1n+1 by nn, a[bn]a\left[b_{n}\right] is periodic with period gcd(bn1bn2,bnbn1)\operatorname{gcd}\left(b_{n-1}-b_{n-2}, b_{n}-b_{n-1}\right). So by the remark, it is periodic with period gcd(bn1bn2,bnbn1,bn+1bn)\operatorname{gcd}\left(b_{n-1}-b_{n-2}, b_{n}-b_{n-1}, b_{n+1}-b_{n}\right). By repeatedly using the multiple-period argument, substituting n+1n+1 by nn and using the remark, we get that a[bn]a\left[b_{n}\right] is periodic with gcd(b2b1,b3b2,,bn+1bn)\operatorname{gcd}\left(b_{2}-b_{1}, b_{3}-b_{2}, \ldots, b_{n+1}-b_{n}\right).
Since (gcd(b2b1,b3b2,,bn+1bn))n\left(\operatorname{gcd}\left(b_{2}-b_{1}, b_{3}-b_{2}, \ldots, b_{n+1}-b_{n}\right)\right)_{n} is a strictly decreasing positive integer sequence, it has a minimum which it achieves at some n=kn=k. Then for p=gcd(b2b1,b3b2,,bk+1bk)p=\operatorname{gcd}\left(b_{2}-b_{1}, b_{3}-b_{2}, \ldots, b_{k+1}-b_{k}\right), we have that a[bn]a\left[b_{n}\right] is periodic with period pp for all nkn \geq k. This finishes the proof.

Comment. The lemma is true even if the palindromic condition is dropped. This stronger formulation requires a more in-depth, harder proof for the case x+y=l+1x+y=l+1, presented below.

Proof. We repeatedly perform the following moves, starting from index xx. If the current index is at most lxl-x, we increase it by xx. If we cannot perform this move, and the index is at least y+1y+1, we decrease it by yy. If we cannot perform either move, we stop.
If at some point we cannot perform more steps, the index rr we have satisfies lx<r<y+1l-x<r<y+1, so r=yr=y. Since at each step the elements of (an)n=1n=l\left(a_{n}\right)_{n=1}^{n=l} at the old and new index are equal due to periodicity, the elements at the first and last indices in our steps are equal, so ax=aya_{x}=a_{y}.
If we can perform the above steps infinitely many times, there will be an index at which we arrive at least twice. Let r1r_{1} be the first such index. Then let the subsequent indices we get by the above steps from r1r_{1} be (rn)n0\left(r_{n}\right)_{n \geq 0}. Since r1=rk+1r_{1}=r_{k+1} for some index as we arrive at r1r_{1} twice, we know that taking a step from rkr_{k} takes it to r1r_{1}, i.e. r1=rk+xr_{1}=r_{k}+x or r1=rkyr_{1}=r_{k}-y. However, at any index it is clear that we can only arrive by one type of moves, since then 1rxlx1 \leq r-x \leq l-x and lx<r+yll-x<r+y \leq l are both satisfied by rr so 1+xrly1+x \leq r \leq l-y, contradiction as l=x+y1l=x+y-1. So the index preceding r1r_{1} is also repeated at rkr_{k} as they cannot be different. So necessarily all indices repeat. But the index preceding the second time we reach xx cannot be 0=xx0=x-x and also cannot be x+y=l+1x+y=l+1, contradiction. So we can never take infinitely many such steps.

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 reproduced verbatim; metadata (topic, difficulty) added by this project.