What is the number of injective functions from a set of size $n$ into a set of size $m$, with $n\le m$?

250 Views Asked by At

What is the number of injective functions from a set of size $n$ into a set of size $m$, with $n\le m$?

I am thinking along the lines of, let a set $A = \{1,\dotsc,n\}$ and set $B = \{1,\dotsc,m\}$.

Then $f(1)$ can take $m$ values, $f(2)$ can take $m-1$ values, …, $f(n)$ can take $m-n-1$ values.

Or am I thinking about this incorrectly?

2

There are 2 best solutions below

2
On

You're absolutely on the right track. Now you just need to combine $m, m-1,\ldots,m-(n-1)$ in the right way, and you're done.

0
On

This is $P^m_n=\frac{m!}{(m-n)!}$, the number of permutations of $n$ objects from $m$ objects.