Maths Olympiad Prep

Library / Annual Harvard-MIT Mathematics Tournament /9 of 72

Annual Harvard-MIT Mathematics Tournament

Number theory Difficulty 4.6 AIME Find the answer United States

Problem:
Compute the remainder when
∑k=130303kk \sum_{k=1}^{30303} k^{k}
is divided by 101101.

A number or a short expression. Fractions can be typed as 3/2, and spacing doesn't matter.

Solution

Solution:
The main idea is the following lemma:

Lemma. For any non-negative integer nn and prime pp, ∑k=n+1n+p2−pkk≡1(modp).\sum_{k=n+1}^{n+p^{2}-p} k^{k} \equiv 1 \pmod{p}.

Proof. Note that aba^{b} depends only on the value of a(modp)a \pmod{p} and the value of b(modp−1)b \pmod{p-1}. Since pp and p−1p-1 are relatively prime, the Chinese Remainder Theorem implies that any p2−pp^{2}-p consecutive integers will take on each possible pair of a residue  mod  p\bmod\ p and a residue  mod  p−1\bmod\ p-1. In other words, if we let (a,b)=(k mod p,k mod p−1)(a, b) = (k \bmod p, k \bmod p-1), then as kk ranges through p2−pp^{2}-p consecutive integers, (a,b)(a, b) will range through all p2−pp^{2}-p ordered pairs of residues  mod  p\bmod\ p and residues  mod  p−1\bmod\ p-1. This implies that
∑k=n+1n+p2−pkk≡∑b=1p−1∑a=1pab. \sum_{k=n+1}^{n+p^{2}-p} k^{k} \equiv \sum_{b=1}^{p-1} \sum_{a=1}^{p} a^{b} .
It is well-known that ∑a=1pab={−1p−1∣b0p−1∤b\sum_{a=1}^{p} a^{b} = \begin{cases} -1 & p-1 \mid b \\ 0 & p-1 \nmid b \end{cases}. We will sketch a proof here. When p−1∣bp-1 \mid b, the result follows from Fermat's Little Theorem. When p−1∤bp-1 \nmid b, it suffices to consider the case when b∣p−1b \mid p-1, since the bbth powers  mod  p\bmod\ p are the same as the gcd⁡(b,p−1)\gcd(b, p-1)th powers  mod  p\bmod\ p, and there are an equal number of every non-zero bbth power. But in this case, the bbth powers are just the solutions to xp−1b−1x^{\frac{p-1}{b}} - 1, which add up to zero by Vieta's formulas.

Now, using the formula for ∑ab\sum a^{b}, we get that
∑b=1p−1∑a=1pab≡−1(modp) \sum_{b=1}^{p-1} \sum_{a=1}^{p} a^{b} \equiv -1 \pmod{p}
which completes the lemma.

We now apply the lemma with p=101p=101 and n=3,10103n=3, 10103, and 2010320103 to get that ∑k=130303kk≡(∑k=13kk)−3\sum_{k=1}^{30303} k^{k} \equiv \left(\sum_{k=1}^{3} k^{k}\right) - 3. But ∑k=13kk=11+22+33=1+4+27=32\sum_{k=1}^{3} k^{k} = 1^{1} + 2^{2} + 3^{3} = 1 + 4 + 27 = 32, so the answer is 32−3=2932 - 3 = 29.

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.