Maths Olympiad Prep

Library / China Team Selection Test /46 of 92

China Team Selection Test

Number theory Difficulty 8.0 Shortlist Find the answer

For any positive integer dd, prove there are infinitely many positive integers nn such that d(n!)−1d(n!)-1 is a composite number.

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

Solution

For any positive integer d d , we aim to prove that there are infinitely many positive integers n n such that d(n!)−1 d(n!) - 1 is a composite number.

### Case 1: d=1 d = 1

Assume for the sake of contradiction that for all sufficiently large n∈N n \in \mathbb{N} , n!−1 n! - 1 is prime. Define pn=n!−1 p_n = n! - 1 to be this prime for all n≥N n \geq N for some N∈N N \in \mathbb{N} . Notice that pn>n p_n > n . Consider n=pn−kn n = p_n - k_n for some kn∈N k_n \in \mathbb{N} .

In Fpn \mathbb{F}_{p_n} , by Wilson's Theorem, we have:
1=(pn−kn)!=(pn−1)!(pn−1)(pn−2)⋯(pn−kn+1)=−1(−1)kn−1⋅(kn−1)!=(−1)kn⋅1(kn−1)! 1 = (p_n - k_n)! = \frac{(p_n - 1)!}{(p_n - 1)(p_n - 2) \cdots (p_n - k_n + 1)} = \frac{-1}{(-1)^{k_n - 1} \cdot (k_n - 1)!} = (-1)^{k_n} \cdot \frac{1}{(k_n - 1)!}
Thus,
(kn−1)!≡(−1)kn(modpn) (k_n - 1)! \equiv (-1)^{k_n} \pmod{p_n}
If we pick n≡1(mod2) n \equiv 1 \pmod{2} , then kn≡pn−n≡0(mod2) k_n \equiv p_n - n \equiv 0 \pmod{2} as pn p_n is odd, and therefore pn∣(kn−1)!−1 p_n \mid (k_n - 1)! - 1 .

Since kn>C k_n > C for all sufficiently large n∈N n \in \mathbb{N} for any C∈N C \in \mathbb{N} , and considering the pigeonhole principle, we conclude that pn=(kn−1)!−1 p_n = (k_n - 1)! - 1 . Hence, pn=n!−1 p_n = n! - 1 implies pn−n−1=kn−1=n p_n - n - 1 = k_n - 1 = n , which means pn=2n+1 p_n = 2n + 1 . This implies 2n+1=n!−1 2n + 1 = n! - 1 for infinitely many n∈N n \in \mathbb{N} , which is impossible for large n n . Therefore, n!−1 n! - 1 cannot be prime for all sufficiently large n n .

### General Case: d≥2 d \geq 2

Assume for the sake of contradiction that there exists some N∈N N \in \mathbb{N} such that for all n∈N,n≥N n \in \mathbb{N}, n \geq N , d⋅n!−1 d \cdot n! - 1 is prime. Define the function f:N∖[d]→N f: \mathbb{N} \setminus [d] \to \mathbb{N} as:
f(m)=(d−1)!⋅(d+1)(d+2)⋯(m−1)⋅m+(−1)m f(m) = (d-1)! \cdot (d+1)(d+2) \cdots (m-1) \cdot m + (-1)^m

Let pm p_m be the smallest prime divisor of f(m) f(m) . For m≥2d m \geq 2d , pm>m p_m > m because gcd⁡(m!,f(m)−1)∣d \gcd(m!, f(m) - 1) \mid d but d∣f(m) d \mid f(m) implies gcd⁡(f(m)−1,d)=1 \gcd(f(m) - 1, d) = 1 . Thus, pm∣f(m)+(−1)m p_m \mid f(m) + (-1)^m , meaning:
0≡d(f(m)+(−1)m)≡m!+d(−1)m(modpm) 0 \equiv d(f(m) + (-1)^m) \equiv m! + d(-1)^m \pmod{p_m}

Using Wilson's Theorem in Fpm \mathbb{F}_{p_m} :
(pm−m−1)!=(pm−1)!(pm−1)(pm−2)⋯(pm−m)=−1(−1)m⋅m!=−1(−1)m(−(−1)m)⋅d=1d (p_m - m - 1)! = \frac{(p_m - 1)!}{(p_m - 1)(p_m - 2) \cdots (p_m - m)} = \frac{-1}{(-1)^m \cdot m!} = \frac{-1}{(-1)^m (-(-1)^m) \cdot d} = \frac{1}{d}
Thus,
pm∣d(pm−m−1)!−1 p_m \mid d(p_m - m - 1)! - 1

For sufficiently large m m , pm=d⋅(pm−m−1)!−1 p_m = d \cdot (p_m - m - 1)! - 1 . By the pigeonhole principle, km=pm−m k_m = p_m - m can appear finitely many times. Therefore, km≥N+1 k_m \geq N + 1 implies d⋅(pm−m−1)!−1 d \cdot (p_m - m - 1)! - 1 is prime, leading to a contradiction.

Hence, for any positive integer d d , there are infinitely many positive integers n n such that d(n!)−1 d(n!) - 1 is a composite number.

The answer is: There\boxed{\text{There}} are infinitely many positive integers } n \text{} such that } d(n!) - 1 \text{} is a composite number.}}

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: Omni-MATH, licensed Apache-2.0. Statement reproduced verbatim; metadata (topic, difficulty) added by this project.