Interactive · 1 question
Let's say that there are four children in a group: Arya, Bran, Rob, and Jon. They are standing in front of three very large piles of swords. Each child can take as many swords as he or she wants from a SINGLE* pile; this includes taking the whole pile for themselves!
*If they take swords from more than one pile, then the relationship between the children and the swords cannot be a function! Why? Check out the Horizontal Line Test!
Now, a few scenarios will be presented. See if you can determine what a surjection is using the clues from the scenarios!
Scenario 1: Arya and Bran split the first pile between them. Rob takes the entire second pile. Jon takes the entire third pile. This is a surjection.
Scenario 2: Arya takes the entire first pile. Bran does not take any swords. Rob and Jon split the second pile. This is not a surjection.
Scenario 3: Arya does not take any swords. Bran takes the second pile. Rob takes the first pile. Jon takes the third pile. This is a surjection.
Scenario 4: Arya and Jon share the second pile. Rob takes the third pile. Bran takes the first pile. This is a surjection.
Scenario 5: Arya and Rob share the third pile. Bran and Jon share the second pile. This is not a surjection.
What properties does a surjection seem to have?
If you got the correct answers, you're ready to learn the mathematical definition of a surjection!
Let's call the children the domain and the swords the co-domain. Let's also call the domain and co-domain A and B respectively. A surjection occurs when: For every element , there is AT LEAST ONE such that . Saying that a function is surjective is saying that all the elements in the co-domain must have at least one value of the domain that, when put through that function, comes out equaling that value in the co-domain.
Here's what a surjection looks like:

This type of diagram is known as an 'onto function'. The values from the left map onto the values from the right. **Notice that this is Scenario 1 from above!