Definition
A function is surjective (or onto) if every element in the codomain is mapped to by at least one element in the domain . That is, for every , there exists an such that: How to read: “f of x equals y.” Meaning / when to use: The image of the domain under equals the entire codomain (Range = Codomain).
Why It Matters
Surjectivity ensures that no potential target output in the system is unreachable or left out. For example, in database mappings or communication protocols, a surjective mapping guarantees that all possible statuses or codes can actually be generated by the inputs.
Core Concepts
- Range vs. Codomain: In a general function, the range (actual outputs) can be a subset of the codomain (possible output types). For a surjective function, they are exactly equal.
- Solving for Input: To prove a function is surjective, one must show that for any arbitrary , the equation has at least one solution for in the domain.
- Many-to-One Allowed: Surjectivity does not require uniqueness; multiple inputs are allowed to map to the same output.