Q.
Let A={1, 2, 3, .... n] and B={a, b}. Then the number of surjections from A into B is
2473
183
Relations and Functions - Part 2
Report Error
Solution:
If f : A→B is a function, the f(1) can be chosen in two ways, f(2) can be chosen in two ways, ..., f(n) can be chosen in two ways.
Hence, f can be chosen in 2×2×...×2=2n ways
In total there are 2n functions possible. Out of these two functions f1 and f2, defined as f1(i)=a∀i=1, 2, ..., n and f2(i)=b∀i=1, 2, ..., n are not surjective as range of f1 is {a}=B and f2 is {b}=B.
Hence, the number of surjections from A to B is 2n−2.