Onto Mappings
An onto mapping in Combinatorics is a function where every element of the codomain is hit by at least one element from the domain. It is also called a surjective function and often shows up in counting problems with no empty groups.
What is Onto Mappings?
An onto mapping is a function in Combinatorics where every element in the codomain is matched by at least one element from the domain. Another name for this is a surjective function. The big idea is simple: nothing on the output side is left unused.
That detail matters because a function can be a valid mapping without being onto. If some codomain element never gets chosen, then the function is not surjective. So when you see an onto-mapping problem, you are really checking whether every target gets covered.
A quick way to think about it is through assignments or distributions. If you are assigning tasks to workers and each worker must get at least one task, that is an onto setup. If you are placing objects into labeled boxes and every box has to contain something, you are also working with an onto condition.
There is a size restriction built in too. If the domain has fewer elements than the codomain, an onto mapping is impossible, because there are not enough inputs to cover all outputs. So if you are mapping a set of size m onto a set of size n, you need m >= n before the problem even has a chance.
Counting onto mappings is where this term really shows up in combinatorics. One common method is to count all functions first and then subtract the ones that miss at least one codomain element. That is where the Principle of Inclusion-Exclusion comes in. Another standard result is the count n! times S(m, n), where S(m, n) is a Stirling number of the second kind, which counts partitions of m objects into n nonempty groups.
A compact example makes the condition feel less abstract. Suppose you map a 3-element domain onto a 2-element codomain. Every codomain element has to receive at least one arrow, so the only possible distributions are 2 and 1. The impossible case is 3 and 0, because that leaves one codomain element unused. The onto condition is really about avoiding those empty outputs.
Why Onto Mappings matters in COMBINATORICS
Onto mappings matter because they turn counting problems into structure problems. Instead of only asking how many functions exist, combinatorics often asks how many functions satisfy a restriction, and surjectivity is one of the most common restrictions.
This shows up any time a problem says every category, bin, person, color, or label must be used. If you are distributing items into boxes and no box can be empty, you are counting onto mappings. If you are assigning m objects to n labeled groups and each group must appear at least once, the same idea is hiding underneath.
Onto mappings also connect directly to other core topics in the course. They sit next to inclusion-exclusion because the cleanest counting strategy is often to count all functions and subtract the ones that leave at least one codomain element unused. They also connect to Stirling numbers, since partitions into nonempty subsets are exactly the internal structure behind many onto-counting formulas.
You will also see onto mappings used to recognize when a setup is impossible. If the codomain is larger than the domain, no onto mapping can exist, so the answer is zero right away. Catching that early saves a lot of work on problem sets and exam-style counting questions.
Keep studying COMBINATORICS Unit 5
Official unit cheatsheet
open one-pagerHow Onto Mappings connects across the course
Injective Function
An injective function goes the other direction conceptually: different domain elements must land on different codomain elements. For onto mappings, the question is whether every codomain element gets used. For injective functions, the question is whether any two domain elements collide. Many problems ask you to tell these apart before you count.
Bijective Function
A bijection is both injective and onto, so it hits every codomain element exactly once. In combinatorics, bijections are especially useful because they let you match one counting problem to another with the same size. If an onto mapping also has no repeated outputs, you have a one-to-one correspondence.
Counting Derangements
Derangements are a special counting problem where nothing stays in its original position. They often use inclusion-exclusion, just like onto mappings do. The shared skill is tracking which outcomes are forbidden and subtracting the cases that miss a condition. Both topics train you to count by excluding bad arrangements.
Cardinality
Cardinality tells you how many elements are in a set, and it gives the first quick check for whether an onto mapping is even possible. If the domain is smaller than the codomain, the mapping cannot be onto. So cardinality sets the basic size test before you move to actual counting.
Is Onto Mappings on the COMBINATORICS exam?
A problem set question on onto mappings usually asks you to count functions with no empty codomain elements, or to decide whether such a function can exist at all. The move is to check the sizes first, then choose a counting method. If the problem is about labeled groups, you may use inclusion-exclusion or the formula n! times S(m, n). If it is asking for a yes or no, the fastest answer is often the size comparison: a smaller domain cannot map onto a larger codomain.
You may also need to explain your reasoning in words, not just write a final number. That means naming the empty-output issue clearly, especially when the problem is framed as assignments, seating, or distribution.
Onto Mappings vs Bijective Function
Onto means every element of the codomain is hit at least once. Bijective means onto and injective at the same time, so every codomain element is hit exactly once. A function can be onto without being bijective if two domain elements share the same output.
Key things to remember about Onto Mappings
An onto mapping, or surjective function, uses every element of the codomain at least once.
If the domain has fewer elements than the codomain, an onto mapping cannot exist.
Counting onto mappings often means counting all functions and subtracting the ones that miss one or more outputs.
In combinatorics, onto mappings show up in distribution problems where no group, box, or category is allowed to be empty.
The formula n! times S(m, n) is a common way to count onto mappings from an m-element set to an n-element set.
Frequently asked questions about Onto Mappings
What is Onto Mappings in Combinatorics?
An onto mapping in Combinatorics is a function where every element in the codomain gets hit by at least one element from the domain. It is the same as a surjective function. You usually see it in counting problems about assignments, distributions, or partitions with no empty output group.
How do you know if a mapping is onto?
Check whether every codomain element has at least one preimage. If even one output value is never used, the function is not onto. A fast size check also helps: if the domain is smaller than the codomain, the function cannot be onto.
How do you count onto mappings?
A common method is inclusion-exclusion: count all functions first, then subtract the ones that miss one or more codomain elements. Another standard formula is n! times S(m, n), where S(m, n) is a Stirling number of the second kind. Which method you use depends on how the problem is written.
What is the difference between onto and one-to-one?
Onto means every codomain element is used. One-to-one, or injective, means no two domain elements land on the same output. These are different conditions, and a function can have one without the other. A bijection has both.