f: A → B is a partial function if Domain(f) ⊆ A. Number of such partial…
f: A → B is a partial function if Domain(f) ⊆ A. Number of such partial functions when |A| = m and |B| = n is:
Answer: C. (n+1)m — Concept: A partial function from a set X to a set Y need not be defined at every element of X — its domain can be any subset of X. This is equivalent to…
- A.
nm
- B.
mn
- C.
(n+1)m
- D.
(m+1)n
Attempted by 43 students.
Show answer & explanation
Correct answer: C
Concept: A partial function from a set X to a set Y need not be defined at every element of X — its domain can be any subset of X. This is equivalent to treating it as a TOTAL function from X into an augmented target set formed by adding one extra ‘undefined’ symbol to Y, so every element of X gets exactly one outcome: some element of Y, or ‘undefined’. In general, if |X| = p and |Y| = q, the number of such partial functions is (q + 1)p, since each of the p elements of X independently has q + 1 possible outcomes.
Application:
Here the source set is A (size m) and the codomain is B (size n), so p = m and q = n.
Since |B| = n, the augmented target set (B plus one ‘undefined’ symbol) has size n + 1.
Each of the m elements of A is independently assigned one outcome from this augmented set of size n + 1 — an element of B, or ‘undefined’.
By the multiplication rule, the total number of ways to make these m independent choices is (n + 1) multiplied by itself m times, i.e. (n+1)m.
Cross-check: Take m = 1, n = 1, so A = {a}, B = {b}. The partial functions are: f(a) = b, or f leaving a undefined — exactly 2 partial functions. The formula gives (1+1)1 = 2, which matches. This also distinguishes the result from the count of TOTAL functions, nm, which would apply only if every element of A were required to have an output (no ‘undefined’ choice allowed).
Hence, the number of partial functions from a set of size m to a set of size n is (n+1)m.