Maths Olympiad Prep

Library / /36 of 57

, 2007

Number theory Difficulty 6.1 National Olympiad Prove it JBMO

Problem:
Let aa, bb be two co-prime positive integers. A number is called good if it can be written in the form ax+bya x + b y for non-negative integers xx, yy. Define the function f:ZZf: \mathbb{Z} \rightarrow \mathbb{Z} as f(n)=nnanbf(n) = n - n_{a} - n_{b}, where sts_{t} represents the remainder of ss upon division by tt. Show that an integer nn is good if and only if the infinite sequence n,f(n),f(f(n)),n, f(n), f(f(n)), \ldots contains only non-negative integers.

Solution

Solution:
If nn is good then n=ax+byn = a x + b y. Also na=(by)an_{a} = (b y)_{a} and nb=(ax)bn_{b} = (a x)_{b} so
f(n)=ax(ax)b+by(by)a=by+ax f(n) = a x - (a x)_{b} + b y - (b y)_{a} = b y' + a x'
is also good, thus the sequence contains only good numbers which are non-negative.

Now we have to prove that if the sequence contains only non-negative integers then nn is good. Because the sequence is non-increasing, the sequence will become constant from some point onwards. But f(k)=kf(k) = k implies that kk is a multiple of aba b, thus some term of the sequence is good. We are done if we prove the following:

Lemma: f(n)f(n) is good implies nn is good.

Proof of Lemma: n=2nnanbf(n)=ax+byaxby=a(xx)+b(yy)n = 2 n - n_{a} - n_{b} - f(n) = a x' + b y' - a x - b y = a(x' - x) + b(y' - y) and xxx' \geq x because nf(n)nnaf(n)f(n)aaxax+by(by)aaxn \geq f(n) \Rightarrow n - n_{a} \geq f(n) - f(n)_{a} \Rightarrow a x' \geq a x + b y - (b y)_{a} \geq a x. Similarly yyy' \geq y.

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.