Number theoryDifficulty 6.1National OlympiadProve itJBMO
Problem: Let a, b be two co-prime positive integers. A number is called good if it can be written in the form ax+by for non-negative integers x, y. Define the function f:Z→Z as f(n)=n−na−nb, where st represents the remainder of s upon division by t. Show that an integer n is good if and only if the infinite sequence n,f(n),f(f(n)),… contains only non-negative integers.
Solution
Solution: If n is good then n=ax+by. Also na=(by)a and nb=(ax)b so f(n)=ax−(ax)b+by−(by)a=by′+ax′ 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 n is good. Because the sequence is non-increasing, the sequence will become constant from some point onwards. But f(k)=k implies that k is a multiple of ab, thus some term of the sequence is good. We are done if we prove the following:
Lemma: f(n) is good implies n is good.
Proof of Lemma: n=2n−na−nb−f(n)=ax′+by′−ax−by=a(x′−x)+b(y′−y) and x′≥x because n≥f(n)⇒n−na≥f(n)−f(n)a⇒ax′≥ax+by−(by)a≥ax. Similarly y′≥y.
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.