Maths Olympiad Prep

Library / /14 of 18

Number theory Difficulty 5.0 AIME Find the answer United States

Let
P(m)=m2+m24+m48+m88. P(m) = \frac{m}{2} + \frac{m^2}{4} + \frac{m^4}{8} + \frac{m^8}{8}.
How many of the values P(2022)P(2022), P(2023)P(2023), P(2024)P(2024), and P(2025)P(2025) are integers?

This was a multiple-choice question, but the options didn't survive into the source we have. The answer given is E, and the solution below works it through.

Solution

Answer (E): Let Q(m)=8P(m)=4m+2m2+m4+m8Q(m) = 8P(m) = 4m + 2m^2 + m^4 + m^8. Because the coefficients of QQ are integers, it follows that if ab(mod8)a \equiv b \pmod{8}, then Q(a)Q(b)(mod8)Q(a) \equiv Q(b) \pmod{8}. It suffices to show that the 8 numbers Q(3)Q(-3), Q(2)Q(-2), Q(1)Q(-1), ..., Q(4)Q(4) are all divisible by 8. If mm is even, then each of the monomials of Q(m)Q(m) is divisible by 8. If m=±1m = \pm 1, then Q(m)=±4+40(mod8)Q(m) = \pm 4 + 4 \equiv 0 \pmod{8}. If m=±3m = \pm 3, then m2=91(mod8)m^2 = 9 \equiv 1 \pmod{8}, which implies that m41(mod8)m^4 \equiv 1 \pmod{8}, and so also that m81(mod8)m^8 \equiv 1 \pmod{8}. Hence Q(±3)±12+2+1+10(mod8)Q(\pm 3) \equiv \pm 12 + 2 + 1 + 1 \equiv 0 \pmod{8}.

Therefore 8P(m)8P(m) is divisible by 8 for all integers mm, which implies that P(m)P(m) is an integer for all mm. In particular, all 4 of the given values of P(m)P(m) are integers.

Let Q(m)Q(m) be defined as in the first solution, and note that Q(m)Q(m) is divisible by 8 if mm is even. To treat odd mm, write
Q(m)=8m+4(m2m)+2m2(m21)+m4(m41)=8m+4m(m1)+2m2(m+1)(m1)+m4(m2+1)(m+1)(m1) \begin{align*} Q(m) &= 8m + 4(m^2 - m) + 2m^2(m^2 - 1) + m^4(m^4 - 1) \\ &= 8m + 4m(m - 1) + 2m^2(m + 1)(m - 1) + m^4(m^2 + 1)(m + 1)(m - 1) \end{align*}
and note that because m+1,m1m+1, m-1, and m2+1m^2+1 are all even, each term has at least three factors of 2. The solution concludes as above.

Another way to see that Q(m)Q(m) is divisible by 8 when mm is odd in the second solution is to apply more general facts from number theory. Fermat's Little Theorem asserts that if pp is prime, then apa(modp)a^p \equiv a \pmod p for all integers aa. In particular, m2m(mod2)m^2 \equiv m \pmod 2. Euler's Totient Theorem asserts that if gcd(a,q)=1\gcd(a, q) = 1, then aϕ(q)1(modq)a^{\phi(q)} \equiv 1 \pmod{q}, where ϕ(q)\phi(q) is the number of positive integers less than qq that are relatively prime to qq. Because ϕ(4)=2\phi(4) = 2, it follows that m21(mod4)m^2 \equiv 1 \pmod{4} when mm is odd. Also, ϕ(8)=4\phi(8) = 4, so m41(mod8)m^4 \equiv 1 \pmod{8} if mm 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.