[Math] Binomial coefficients and “missing primes”

nt.number-theory

Define the following two subsets of prime numbers
$$\Pi_n:=\{p: \text{$p$ is prime, $p\leq n$}\}$$
and
$$B_n:=\{p: \text{$p$ is prime, $p$ divides $\binom{n}k$ for some $0< k< n$}\}.$$
Denote their respective cardinalities by $\pi(n):=\vert\Pi_n\vert$ and $\,b(n):=\vert B_n\vert$.

QUESTIONS. Experimental evidence suggest that

(a) $\pi(n)-b(n)=0$ or $1$.

(b) If $\pi(n)-b(n)=1$, then the missing prime is the largest prime divisor of $n+1$.

Are these true statements?

Best Answer

Suppose that $p $ is a prime satisfying $p\le n$ and $p\nmid \binom{n}{k}$ for all $k=1,\ldots,n-1.$ Then from Kummer's theorem it follows that the base-$p$ representation of $n$ is $n=(a,p-1,\ldots,p-1)_p$ with $1\le a\le p-1$. So $n=(a+1)p^r-1$, where $r$ is the number of base-$p$ digits in $n$. Then $n+1 = (a+1)p^r$ with $a+1 \leq p$, so any prime factor of $n+1$ besides $p$ is a prime factor of $a+1$, so it has to be less than $p$.

Here is a second solution, using Lucas's theorem: writing $n = n_0+n_1p+\cdots +n_rp^r$, where $0 \leq n_i \leq p-1$ and $n_r \geq 1$, each $k$ in $\{0,1,\ldots,n\}$ has base-$p$ representation $k_0+k_1p+\cdots +k_rp^r$ where $0 \leq k_i \leq p-1$ (maybe $k_r = 0$ if $k$ is much smaller than $n$). Then Lucas' theorem says $$ \binom{n}{k} \equiv \binom{n_0}{k_0}\binom{n_1}{k_1}\cdots \binom{n_r}{k_r} \bmod p. $$ For digits $n_i$ and $k_i$, which are in $\{0,1,\ldots,p-1\}$, we have $\binom{n_i}{k_i} \equiv 0 \bmod p$ if and only if $n_i < k_i$ (otherwise the factors in $\binom{n_i}{k_i} = \frac{n_i(n_i-1)\cdots(n_i-(k_i-1))}{k_i!}$ are all nonzero modulo $p$). Thus we have $\binom{n}{k} \not\equiv 0 \bmod p$ for all $k$ from $0$ to $n$ (let's allow $k=0$ and $k=n$ since those cases are not divisible by $p$) if and only if every $k \leq n$ has $k_i \leq n_i$ for $i < r$ and $k_r \leq n_r$, and that's equivalent to $n_i = p-1$ for $i < r$ (if some $n_i < p-1$ then at $k = (p-1)p^i$ we have $\binom{n}{k} \equiv 0 \bmod p$). Such $n$ have the form $(p-1)+(p-1)p\cdots+(p-1)p^{r-1} + n_rp^r = (n_r+1)p^r-1$. If $r = 0$ then $n = n_r \leq p-1$. If $r \geq 1$ then $p \mid (n+1)$, and the first solution shows easily in this case why $p$ has to be the largest prime factor of $n+1$. In summary, every prime that is $\leq n$ divides some $\binom{n}{k}$ for $1 \leq k \leq n-1$ except when $n = mp^r-1$ where $r \geq 1$, $p$ is prime, and $2 \leq m \leq p$, in which case the prime $p$ divides no $\binom{n}{k}$.

Related Question