Find Number of Onto Functions from \(A\) to \(B\)

📝 Question

Let:

\[ A=\{1,2,3,4\}, \quad B=\{a,b\} \]

Find the total number of onto (surjective) functions from \(A\) to \(B\).


✅ Solution

🔹 Step 1: Total number of functions

\[ \text{Total functions} = 2^4 = 16 \] —

🔹 Step 2: Subtract non-onto functions

Non-onto functions are those where all elements map to only one element of \(B\).

Cases:

  • All map to \(a\)
  • All map to \(b\)

So, number of such functions = 2

🔹 Step 3: Find onto functions

\[ \text{Onto functions} = 16 – 2 \] :contentReference[oaicite:0]{index=0} —

🎯 Final Answer

\[ \boxed{14} \]


🚀 Exam Shortcut

  • Total = \(n^m\)
  • Subtract functions missing at least one element
  • For 2 elements: \(2^n – 2\)
Spread the love

Leave a Comment

Your email address will not be published. Required fields are marked *