Maths Olympiad Prep

Library / /1175 of 1394

, 2016

Number theory Difficulty 5.7 AIME, harder Prove it United States

Problem:

Call a positive integer N2N \geq 2 "special" if for every kk such that 2kN2 \leq k \leq N, NN can be expressed as a sum of kk positive integers that are relatively prime to NN (although not necessarily relatively prime to each other). How many special integers are there less than 100100?

Solution

Solution:

We claim that all odd numbers are special, and the only special even number is 22. For any even N>2N > 2, the numbers relatively prime to NN must be odd. When we consider k=3k = 3, we see that NN can't be expressed as a sum of 33 odd numbers.

Now suppose that NN is odd, and we look at the binary decomposition of NN, so write N=2a1+2a2++2ajN = 2^{a_{1}} + 2^{a_{2}} + \ldots + 2^{a_{j}} as a sum of distinct powers of 22. Note that all these numbers only have factors of 22 and are therefore relatively prime to NN. We see that j<log2N+1j < \log_{2} N + 1.

We claim that for any kjk \geq j, we can write NN as a sum of kk powers of 22. Suppose that we have NN written as N=2a1+2a2++2akN = 2^{a_{1}} + 2^{a_{2}} + \ldots + 2^{a_{k}}. Suppose we have at least one of these powers of 22 even, say 2a12^{a_{1}}. We can then write N=2a11+2a11+2a2++2akN = 2^{a_{1}-1} + 2^{a_{1}-1} + 2^{a_{2}} + \ldots + 2^{a_{k}}, which is k+1k+1 powers of 22. The only way this process cannot be carried out is if we write NN as a sum of ones, which corresponds to k=Nk = N. Therefore, this gives us all k>log2Nk > \log_{2} N.

Now we consider the case k=2k = 2. Let 2a2^{a} be the largest power of 22 such that 2a<N2^{a} < N. We can write N=2a+(N2a)N = 2^{a} + (N - 2^{a}). Note that since 2a2^{a} and NN are relatively prime, so are N2aN - 2^{a} and NN. Note that a<log2Na < \log_{2} N. Now similar to the previous argument, we can write 2a2^{a} as a sum of kk powers of 22 for 1<k<2a1 < k < 2^{a}, and since 2a>N22^{a} > \frac{N}{2}, we can achieve all kk such that 2k<N2+12 \leq k < \frac{N}{2} + 1.

Putting these together, we see that since N2+1>log2N\frac{N}{2} + 1 > \log_{2} N for N3N \geq 3, we can achieve all kk from 22 through NN, where NN is odd.

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.