TITLE: "Binomiable" numbers
QUESTION [19 upvotes]: Is there a nice criterion to determine whether a given natural $m$ can be written as a binomial number $\binom{n}{k}$ with $1 < k < n-1$?
I've been thinking on this problem with a friend and all we concluded is that primes aren't "binomiables".

CLAIM 1. Primes aren't "binomiables".
Proof. Let $p$ a prime and suppose $p = \binom{n}{k}$.

If $n$ is prime, then $n$ must be equals $p$, because $n\mid \binom{n}{k}$. But, in this case, $n\mid\mid \binom{n}{k}$, so $k=1$. (This would work to prime powers too.)
If $n$ is composed, note that $\binom{n}{k} = p$ implies, a fortiori, that $p\mid \binom{n}{k}$ and consequently $p\leqslant n$. But under our conditions, $\binom{n}{k} > n$, contradiction. $\square$


Also, I've already saw in Proofs from THE BOOK the problem "Binomial coefficients are (almost) never powers", and although it is highly related, it doesn't provide much insight towards this problem (at least as far as I understood).

EDIT: Prime powers aren't binomiables too!
Let's state three results first:

Lemma. Let $p$ a prime. If $p\mid n$ and $0<k<p$, then $p\mid \binom{n}{k}$.
Proof. Let $n= pm$ and assume $0<k<p$. Consider the Vandermonde's identity:
$$\binom{pm}{k} = \sum_{j=0}^k \binom{p}{j}\binom{p(m-1)}{k-j}.$$
It follows that $\binom{pm}{k}\equiv \binom{p(m-1)}{k} \mod{p}$ (the
term $j=0$ in the sum). Repeating it $m$ times, we conclude
$\binom{pm}{k}\equiv \binom{p}{k} \mod{p}$, and from $p\mid
    \binom{p}{k}$ follows our statement. $\square$
Bertrand's postulate. If $n\geqslant 2k$, then the binomial $\binom{n}{k}$ has a prime factor $q > k$.
Theorem. [Erdös] The binomial $\binom{n}{k}$ is never a perfect power for $4\leqslant k\leqslant n-4$.
(This is the paragraph I mentioned in Proofs from THE BOOK.)

So there is only two cases to analyse, $k=2$ and $k=3$. In both cases we can assume $n \geqslant 6$.

CLAIM 2. Prime powers aren't "binomiables".
Proof. Let $p$ a prime, $m>1$, and suppose $p^m = \binom{n}{k}$.

If $k=2$, then $p^m = \frac{n(n-1)}{2}$. By Bertrand's postulate, $p\neq 2$. Now observe that $\gcd(n, n-1) = 1$, so
  $$ p^m \mid n\quad \text{xor}\quad p^m\mid n-1. $$
  Then:
  $$2 =\frac{n(n-1)}{p^m} \geqslant n-1 \implies n \leqslant 3,$$
  that contradicts $n\geqslant 6$.
If $k=3$, then $p^m = \frac{n(n-1)(n-2)}{6}$. Bertrand's postulate allows us to take $p\neq 2,3$. Hence, similarly to the previous case, we can deduce:
  $$p^m \mid n \quad \text{xor}\quad p^m\mid n-1 \quad \text{xor} \quad p^m\mid n-2.$$
  But then:
  $$ 6 = \frac{n(n-1)(n-2)}{p^m} \geqslant (n-1)(n-2) \implies n \leqslant 4,$$
  a contradiction. $\square$



EDIT 2: I've just realized that I didn't use the Lemma at all. Anyway, I think I'll let it here, it may be useful someday hahaha

REPLY [2 votes]: I don't think theres a single simple criterion, but one could construct an algorithm for determining it with time complexity of $O((\ln c)^2)$ binomial coefficients or $O((\ln c)^3)$ multiplicaitons. Besides it may be unknown or hard to determine totally certainly whether the number is actually prime or not.
What we can use is to estimate the coefficients:
$$\binom{n}{k} 
= {\prod_0^k (n-j)\over\prod_0^k j} 
= {\prod_0^k (n-(k/2)+k/2-j)\over\prod_0^k j} \\
= \begin{cases}
{(n-k/2)\prod_0^{(k-1)/2} (n-(k/2)-k/2+j)(n-(k/2)+k/2-j)\over\prod_0^k j} =
{(n-k/2)\prod_0^{(k-1)/2} (n-(k/2))^2-(k/2+j)^2\over\prod_0^k j} 
& \text{ if } k \text{ is odd } \\
{\prod_0^{k/2} (n-(k/2))^2-(k/2+j)^2\over\prod_0^k j} 
& \text{ if } k \text{ is even } \\
\end{cases} \\
\le {(n-k/2)^k\over k!}$$
We also can estimate it from below:
$${(n-k)^k\over k!} \le \binom{n}{k} \le {(n-k/2)^k\over k!}$$
So given $k$ we have an estimate for $n$
$$(k!c)^{1/k} \le n \le (k!c)^{1/k} + k/2$$
Also since we only have to consider $2k<n$ we can use the estimate:
$$\binom{n}{k} \ge \binom{2k}{k} = {(2k)!\over k!k!}$$
So we don't have to consider $k$ with $(2k)!/(k!)^2 > c$ and since it's increasing we can terminate the algorithm once it happens.

Take for example the numbers $8008$ and $8009$ (the later being prime)
We have the ranges of $n$ depending on $k$ as:
$$\begin{matrix}
k & n_{min} & n_{max} & \binom{2k}{k} \\
\hline
2 & 127 & 127 & 6\\
3 & 37 & 37 & 20 \\
4 & 21 & 22 & 70 \\
5 & 16 & 18 & 252 \\
6 & 14 & 16 & 924 \\
7 & 13 & 15 & 3432 \\
8 & & & 12870
\end{matrix}$$
That is we only have to consider
$\binom{127}{2}$,
$\binom{37}{3}$,
$\binom{21}{4}$,
$\binom{22}{4}$,
$\binom{16}{5}$,
$\binom{17}{5}$,
$\binom{18}{5}$,
$\binom{14}{6}$,
$\binom{15}{6}$,
$\binom{16}{6}$,
$\binom{13}{7}$,
$\binom{14}{7}$ and
$\binom{15}{7}$. Calculating these reveals that $8008 = \binom{16}{6}$ and $8009$ is none of them.
The time complexity is due to stirlings formula for the termination condition:
$$\ln{(2k)!\over (k!)^2} = (2k \ln (2k) - 2k + O(\ln 2k))-2(k\ln k - k+O(\ln k)) \\
= 2k(\ln 2+\ln k) - 2k - 2k\ln k + 2k + O(\ln k) 
= 2k\ln 2 + O(ln k) < \ln(c)$$
So we have to consider $O(\ln(c))$  values of $k$ and for each of those $k/2$ values of $n$ making it $O((\ln(c))^2)$ binomial coefficients.