Maths Olympiad Prep

Library / /30 of 34

Number theory Difficulty 7.5 National Olympiad, round 2 Prove it United States

Let pp be a fixed prime and let a2a \ge 2 and e1e \ge 1 be fixed integers. Given a function f:Z/aZZ/peZf: \mathbb{Z}/a\mathbb{Z} \to \mathbb{Z}/p^e\mathbb{Z} and an integer k0k \ge 0, the kkth finite difference, denoted Δkf\Delta^k f, is the function from Z/aZ\mathbb{Z}/a\mathbb{Z} to Z/peZ\mathbb{Z}/p^e\mathbb{Z} defined recursively by
Δ0f(n)=f(n)Δkf(n)=Δk1f(n+1)Δk1f(n)for k=1,2, \begin{aligned} \Delta^0 f(n) &= f(n) \\ \Delta^k f(n) &= \Delta^{k-1} f(n+1) - \Delta^{k-1} f(n) \quad \text{for } k = 1, 2, \dots \end{aligned}
Determine the number of functions ff such that there exists some k1k \ge 1 for which Δkf=f\Delta^k f = f.

Solution

Let d=νp(a)d = \nu_p(a), so a=pdba = p^d \cdot b with pbp \nmid b. We call a function f:Z/aZZ/peZf: \mathbb{Z}/a\mathbb{Z} \to \mathbb{Z}/p^e\mathbb{Z} essential if Δkf=f\Delta^k f = f for some k1k \ge 1.

Claim (Characterization of essential functions):
A function ff is essential if and only if
f(x)+f(x+pd)++f(x+(b1)pd)=0(1) f(x) + f(x + p^d) + \dots + f(x + (b-1)p^d) = 0 \tag{1}
for all xx.

Proof that essential implies the equation:
Suppose ff is essential, with ΔNf=f\Delta^N f = f. Then ff is in the image of Δk\Delta^k for any kk, because ΔmNf=f\Delta^{mN} f = f for any mm. The following lemma will be useful.

Lemma:
Let g:Z/aZZ/peZg: \mathbb{Z}/a\mathbb{Z} \to \mathbb{Z}/p^e\mathbb{Z} be any function, and let h=Δpdgh = \Delta^{p^d} g. Then
h(x)+h(x+pd)++h(x+(b1)pd)0(modp) h(x) + h(x + p^d) + \dots + h(x + (b-1)p^d) \equiv 0 \pmod{p}
for all xx.

Proof of Lemma. By definition,
h(x)=Δpdg(x)=k=0pd(1)k(pdk)g(x+pdk). h(x) = \Delta^{p^d} g(x) = \sum_{k=0}^{p^d} (-1)^k \binom{p^d}{k} g(x + p^d - k).
However, it is known that (pdk)\binom{p^d}{k} is a multiple of pp if 1kpd11 \le k \le p^d - 1, so
h(x)g(x+pd)+(1)pdg(x)(modp). h(x) \equiv g(x + p^d) + (-1)^{p^d} g(x) \pmod{p}.
Using this, we easily obtain
h(x)+h(x+pd)++h(x+(b1)pd){0p>22(g(x)+g(x+pd)++g(x+(b1)pd))p=20(modp), \begin{aligned} & h(x) + h(x + p^d) + \dots + h(x + (b-1)p^d) \\ & \equiv \begin{cases} 0 & p > 2 \\ 2(g(x) + g(x + p^d) + \dots + g(x + (b-1)p^d)) & p = 2 \end{cases} \\ & \equiv 0 \pmod{p}, \end{aligned}
so the lemma is proved.

Corollary:
Let g:Z/aZZ/peZg: \mathbb{Z}/a\mathbb{Z} \to \mathbb{Z}/p^e\mathbb{Z} be any function, and let h=Δepdgh = \Delta^{ep^d}g. Then
h(x)+h(x+pd)++h(x+(b1)pd)=0 h(x) + h(x + p^d) + \dots + h(x + (b-1)p^d) = 0
for all xx.

This immediately settles this direction, since ff is in the image of Δepd\Delta^{ep^d}.

Proof the equation implies essential:
Let SS be the set of all functions satisfying (1); then it's easy to see that Δ\Delta is a function on SS. To show that all functions in SS are essential, it's equivalent to show that Δ\Delta is a permutation on SS.

We will show that Δ\Delta is injective on SS. Suppose otherwise, and consider two functions ff, gg in SS with Δf=Δg\Delta f = \Delta g. Then, we obtain that ff and gg differ by a constant; say g=f+λg = f + \lambda. However, then
g(0)+g(pd)++g((b1)pd)=(f(0)+λ)+(f(pd)+λ)++(f((b1)pd)+λ)=(f(0)+f(pd)++f((b1)pd))+bλ. \begin{aligned} & g(0) + g(p^d) + \dots + g((b-1)p^d) \\ &= (f(0) + \lambda) + (f(p^d) + \lambda) + \dots + (f((b-1)p^d) + \lambda) \\ &= (f(0) + f(p^d) + \dots + f((b-1)p^d)) + b\lambda. \end{aligned}
This should also be zero. Since pbp \nmid b, we obtain λ=0\lambda = 0, as desired.

Counting:
Finally, we can count the essential functions: all but the last pdp^d entries can be chosen arbitrarily, and then each remaining entry has exactly one possible choice. This leads to a count of
papd p^{a-p^d}
for the number of essential functions when e=1e = 1.

---

Second solution (by Daniel Zhu):

There are two parts to the proof: solving the e=1e = 1 case, and using the e=1e = 1 result to solve the general problem by induction on ee. These parts are independent of each other.

**The case e=1e=1:**
Represent functions ff as elements
αf:=kZ/aZf(k)xkFp[x]/(xa1) \alpha_f := \sum_{k \in \mathbb{Z}/a\mathbb{Z}} f(-k)x^k \in \mathbb{F}_p[x]/(x^a - 1)
Then, since αΔf=(x1)αf\alpha_{\Delta f} = (x-1)\alpha_f, we wish to find the number of αFp[x]/(xa1)\alpha \in \mathbb{F}_p[x]/(x^a - 1) such that (x1)mα=α(x-1)^m\alpha = \alpha for some mm.

Now, make the substitution y=x1y = x - 1 and let P(y)=(y+1)a1P(y) = (y+1)^a - 1; we want to find αFp[y]/(P(y))\alpha \in \mathbb{F}_p[y]/(P(y)) such that ymα=αy^m\alpha = \alpha for some mm.

If we write P(y)=ydQ(y)P(y) = y^dQ(y) with Q(0)0Q(0) \neq 0, then by the Chinese Remainder Theorem we have the ring isomorphism
Fp[y]/(P(y))Fp[y]/(yd)×Fp[y]/(Q(y)). \mathbb{F}_p[y]/(P(y)) \cong \mathbb{F}_p[y]/(y^d) \times \mathbb{F}_p[y]/(Q(y)).
Note that yy is nilpotent in the first factor, while it is a unit in the second factor. So the α\alpha that work are exactly those that are zero in the first factor; thus there are padp^{a-d} such α\alpha. We can calculate d=pvp(a)d = p^{v_p(a)} (via, say, Lucas's Theorem), so we are done.

The general problem:
The general idea is as follows: call a f:Z/aZZ/peZf: \mathbb{Z}/a\mathbb{Z} \to \mathbb{Z}/p^e\mathbb{Z} e-good if Δmf=f\Delta^m f = f for some mm. Our result above allows us to count the 1-good functions. Then, if e1e \ge 1, every (e+1)(e+1)-good function, when reduced mod pep^e, yields an e-good function, so we count (e+1)(e+1)-good functions by counting how many reduce to any given e-good function.

Formally, we use induction on ee, with the e=1e=1 case being treated above. Suppose now we have solved the problem for a given e1e \ge 1, and we now wish to solve it for e+1e+1. For any function g:Z/aZZ/pe+1Zg: \mathbb{Z}/a\mathbb{Z} \to \mathbb{Z}/p^{e+1}\mathbb{Z}, let gˉ:Z/aZZ/peZ\bar{g}: \mathbb{Z}/a\mathbb{Z} \to \mathbb{Z}/p^e\mathbb{Z} be its reduction mod pep^e. For a given e-good ff, let n(f)n(f) be the number of (e+1)(e+1)-good gg with gˉ=f\bar{g} = f. The following two claims now finish the problem:

Claim 1: If ff is e-good, then n(f)>0n(f) > 0.

Proof. Suppose mm is such that Δmf=f\Delta^m f = f. Pick any gg with gˉ=f\bar{g} = f, and consider the sequence of functions
g,Δmg,Δ2mg, g, \Delta^m g, \Delta^{2m} g, \dots
Since there are finitely many functions Z/aZZ/pe+1Z\mathbb{Z}/a\mathbb{Z} \to \mathbb{Z}/p^{e+1}\mathbb{Z}, there must exist a<ba < b such that Δamg=Δbmg\Delta^{am}g = \Delta^{bm}g. We claim Δamg\Delta^{am}g is the desired (e+1)(e+1)-good function. To see this, first note that since Δkg=Δkgˉ\overline{\Delta^k g} = \Delta^k \bar{g}, we must have Δamg=Δamf=f\overline{\Delta^{am}g} = \Delta^{am}f = f. Moreover,
Δ(ba)m(Δamg)=Δbmg=Δamg, \Delta^{(b-a)m}(\Delta^{am}g) = \Delta^{bm}g = \Delta^{am}g,
so Δamg\Delta^{am}g is (e+1)(e+1)-good. \square

Claim 2: If ff is e-good, and n(f)>0n(f) > 0, then n(f)n(f) is exactly the number of 1-good functions, i.e. papvp(a)p^{a-p^{v_p(a)}}.

Proof. Let gg be any (e+1)(e+1)-good function with gˉ=f\bar{g} = f. We claim that the (e+1)(e+1)-good g1g_1 with gˉ1=f\bar{g}_1 = f are exactly the functions of the form g+pehg + p^e h for any 1-good hh. Since these functions are clearly distinct, this characterization will prove the claim.

To show that this condition is sufficient, note that g+peh=gˉ=f\overline{g + p^e h} = \bar{g} = f. Moreover, if Δmg=g\Delta^m g = g and Δmh=h\Delta^{m'} h = h, then
Δmm(g+peh)=Δmmg+peΔmmh=g+peh. \Delta^{mm'}(g + p^e h) = \Delta^{mm'}g + p^e \Delta^{mm'}h = g + p^e h.
To show that this condition is necessary, let g1g_1 be any (e+1)(e+1)-good function such that gˉ1=f\bar{g}_1 = f. Then g1gg_1 - g is also (e+1)(e+1)-good, since if Δmg=g\Delta^m g = g, Δmg1=g1\Delta^{m'} g_1 = g_1, we have
Δmm(g1g)=Δmmg1Δmmg=g1g. \Delta^{mm'}(g_1 - g) = \Delta^{mm'}g_1 - \Delta^{mm'}g = g_1 - g.
On the other hand, we also know that g1gg_1 - g is divisible by pep^e. This means that it must be pehp^e h for some function h:Z/aZZ/pZh: \mathbb{Z}/a\mathbb{Z} \to \mathbb{Z}/p\mathbb{Z}, and it is not hard to show that g1gg_1 - g being (e+1)(e+1)-good means that hh is 1-good. \square

Final answer:

The number of functions f:Z/aZZ/peZf: \mathbb{Z}/a\mathbb{Z} \to \mathbb{Z}/p^e\mathbb{Z} such that Δkf=f\Delta^k f = f for some k1k \ge 1 is
pe(apvp(a)) p^{e(a-p^{v_p(a)})}

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.