How many injective and surjective functions are there from $A$ to $B$?

5.4k Views Asked by At

This is an old practice exam question in my calculus class and I would love to understand it before my exam, so any help would be great!

Consider the sets $A = \{a,b\}$ and $B=\{a,c,d,e,f\}$.

a) How many functions are there from $A$ to $B$?

b) How many injective functions are there from $A$ to $B$?

c) How many surjective functions are there from $A$ to $B$?

I know what injective and surjective means, but I have only applied it in linear algebra and I'm not sure how to do these.

2

There are 2 best solutions below

0
On BEST ANSWER

Consider the sets A={a,b} and B={a,c,d,e,f}.

a) How many functions are there from A to B?

The answer is $5^2 =25$ because you have $5$ choices for each $a$ or $b.$

b) How many injective functions are there from A to B?

The answer is $5\times 4 =20$.you have $5$ choices for $a$ and only $4$ choices for $b$

c) How many surjective functions are there from A to B?

The answer is $0$. You can not cover $5$ elements with just $a$ and $b$

3
On

Hints: a) Think about defining a function from $A \to B$. How many functions can you think of? How many choices do you need to make to define such a function?

b) Thinking about the functions above - how many are not injective? How can such a function fail to be injective? So, how many injections are there?

c) I'll leave to you - but think along similar lines as to b).