# Binomial Coefficient of Prime

## Theorem

Let $p$ be a prime number.

Then:

$\forall k \in \Z: 0 < k < p: \dbinom p k \equiv 0 \pmod p$

where $\dbinom p k$ is defined as a binomial coefficient.

## Proof 1

Because:

$\dbinom p k = \dfrac {p \left({p - 1}\right) \left({p - 2}\right) \cdots \left({p - k + 1}\right)} {k!}$

is an integer, we have that:

$k! \mathrel \backslash p \left({p - 1}\right) \left({p - 2}\right) \cdots \left({p - k + 1}\right)$

But because $k < p$ it follows that:

$k! \mathop \perp p$

that is, that:

$\gcd \left\{{k!, p}\right\} = 1$

So by Euclid's Lemma:

$k! \mathrel \backslash \left({p - 1}\right) \left({p - 2}\right) \cdots \left({p - k + 1}\right)$

Hence:

$\dbinom p k = p \dfrac {\left({p - 1}\right) \left({p - 2}\right) \cdots \left({p - k + 1}\right)} {k!}$

Hence the result.

$\blacksquare$

## Proof 2

Lucas' Theorem gives:

$\dbinom n k \equiv \dbinom {\left \lfloor {n / p} \right \rfloor} {\left \lfloor {k / p} \right \rfloor} \dbinom {n \bmod p} {k \bmod p} \pmod p$

So, substituting $p$ for $n$:

$\dbinom p k \equiv \dbinom {\left \lfloor {p / p} \right \rfloor} {\left \lfloor {k / p} \right \rfloor} \dbinom {p \bmod p} {k \bmod p} \pmod p$

But $p \bmod p = 0$ by definition.

Hence, if $0 < k < p$, we have that:

$k \bmod p \ne 0$

and so:

$\dbinom {p \bmod p} {k \bmod p} = \dbinom 0 {k \bmod p} = 0$

The result follows immediately.

$\blacksquare$

## Proof 3

By the definition of binomial coefficient:

 $\displaystyle \binom p k$ $=$ $\displaystyle \frac {p!} {k! \paren {n - k}!}$ $\displaystyle \leadstoandfrom \ \$ $\displaystyle p!$ $=$ $\displaystyle k! \paren {p - k}! \binom p k$

Now, $p$ divides the left hand side by Divisors of Factorial.

So $p$ must also divide the right hand side.

By hypothesis $k < p$.

We have that:

$k! = k \paren {k - 1} \dotsm \paren 2 \paren 1$

We also have that $p$ is prime, and each factor is less than $p$.

Thus $p$ is not a factor of $k!$.

Similarly:

$\paren {p - k}! = \paren {p - k} \paren {p - k - 1} \dotsm \paren 2 \paren 1$

It follows, by the same reasoning as above, that $p$ is also not a factor of $\paren {p - k}!$.

The result then follows from Euclid's Lemma.

$\blacksquare$