Nobody left out
Onto (surjective) functions.
Is everyone hit?
f : N → N, f(x) = 2x. The images are 2, 4, 6, 8, …
Is there an x with f(x) = 1?
What this lesson covers
The idea
f : X → Y is onto if every element of Y is the image of some element of X, i.e. for every y ∈ Y there is x ∈ X with f(x) = y; f is onto if and only if range of f = Y.
Is everyone hit?
f : N → N, f(x) = 2x. The images are 2, 4, 6, 8, …
Is there an x with f(x) = 1?
- Yes
- No
Hit every element
Element 3 of Y is never hit. Move arrows so that every element of Y is hit.
Onto
f : X → Y is onto (surjective) if every element of Y is the image of some element of X: for every y ∈ Y there is x ∈ X with f(x) = y. f is onto if and only if range of f = Y.
f(x) = 2x on N is not onto: 1 is never hit. The book's f(1) = f(2) = 1, f(x) = x − 1 for x > 2 is onto, though not one-one.
Notes
Onto: every y ∈ Y is f(x) for some x. Equivalently, range of f = Y.
Check yourself
f : R → R, f(x) = 2x. Is f onto?
f : R → R, f(x) = x². Is f onto?
The range of f : X → Y is {a, b} and Y = {a, b, c}. Which is true?
- No: odd numbers are missed. That happens on N. On R, f(1/2) = 1, so 1 is hit.
- Yes: for any y, x = y/2 gives f(x) = y — correct. Right. Every real y is hit by the real number y/2.
- No: negative numbers are missed. f(−3) = −6, so negatives are hit too.
- Yes. x² is never negative, so −1 (and every negative number) is missed.
- No, −1 is never hit — correct. Right. x² ≥ 0, so no real x has x² = −1.
- f is onto. Range ≠ Y: c is never hit.
- f is not onto — correct. Yes. Onto needs range = Y, and c is missing.
- f is not a function. It can still be a function. It just leaves c out.