Courses
Courses for Kids
Free study material
Offline Centres
More
Store Icon
Store

What Is the Difference Between Injective and Surjective Functions?

ffImage
hightlight icon
highlight icon
highlight icon
share icon
copy icon
SearchIcon
widget title icon
Latest Updates

widget icon
Start Your JEE Practice Here :
JEE Test Series 2026

How to Identify Injective and Surjective Functions with Simple Examples

Understanding the Difference Between Injective And Surjective Function is crucial in higher mathematics, especially for Classes 11–12 and JEE aspirants. Comparing injective and surjective functions deepens comprehension of function behavior, which is foundational for tackling topics in algebra, calculus, and set theory.


Understanding Injective Functions in Mathematics

An injective function, also called a one-to-one function, is defined such that each element in the domain maps to a unique element in the codomain. No two different elements in the domain have the same image in the codomain.


Mathematically, a function $f : A \to B$ is injective if $f(x_1) = f(x_2)$ implies $x_1 = x_2$ for all $x_1, x_2 \in A$. For more details, refer to Functions And Its Types.


$f(x_1) = f(x_2)\implies x_1 = x_2$


Mathematical Meaning of Surjective Functions

A surjective function, or onto function, is defined such that every element of the codomain has at least one pre-image in the domain. This ensures the function’s range is equal to its codomain, fully covering all possible outputs.


Formally, a function $f : A \to B$ is surjective if for every $y \in B$, there exists at least one $x \in A$ such that $f(x) = y$. The concept is further elaborated in the Difference Between Onto And Into Functions article.


$\forall\ y \in B,\ \exists\ x \in A : f(x) = y$


Comparative View of Injective and Surjective Functions

Injective Function Surjective Function
Each domain element maps to a unique codomain elementEvery codomain element is the image of at least one domain element
Also known as one-to-one functionAlso called onto function
No two domain elements share the same imageImages can have more than one pre-image
Inverse exists only on the rangeInverse may not exist for all domain elements
Range can be proper subset of codomainRange equals codomain
Graph never shows output repetition for different inputsGraph may show outputs repeating for different inputs
Function may “miss” codomain elementsNo codomain elements are missed
For all $x_1, x_2$, $f(x_1) = f(x_2) \implies x_1 = x_2$For all $y$ in codomain, $\exists$ $x$ in domain: $f(x)=y$
$f(x) = 2x$, $f : \mathbb{R} \to \mathbb{R}$ is injective$f(x) = x^3$, $f : \mathbb{R} \to \mathbb{R}$ is surjective
Not every injective function is surjectiveNot every surjective function is injective
Used in establishing one-to-one correspondencesUsed to ensure full coverage of codomain
Every element in codomain has zero or one pre-imageEvery codomain element has at least one pre-image
Key property: uniqueness of imagesKey property: completeness of range
Identity function is both injective and surjectiveIdentity function is both injective and surjective
Helpful in cardinality arguments in set theoryEssential for mapping surjective images in algebra
Not necessarily a solution for every codomain elementEvery codomain element has at least one solution
Examples: $f(x) = x+1$ on integersExamples: $f(x) = x^3$ on reals
Not necessarily covers the entire codomainAlways covers the entire codomain
Relevant for one-to-one encryption mappingsRelevant for ensuring all potential outputs are used
Focus: uniquenessFocus: coverage

Important Differences

  • Injective ensures distinct inputs have distinct outputs

  • Surjective ensures every codomain element is “hit” at least once

  • Injective may not cover the entire codomain

  • Surjective may not have unique pre-images for each output

  • Injective focuses on uniqueness, surjective on coverage

  • Only bijective functions are both injective and surjective

Simple Numerical Examples

Consider $f: \mathbb{N} \to \mathbb{N}$ defined by $f(x) = 2x$. This function is injective because distinct $x$ yield distinct $2x$, but not surjective as no odd numbers appear in the range.


Consider $g: \mathbb{R} \to \mathbb{R}$ defined by $g(x) = x^3$. This is surjective since every real number is the cube of some real, but it is also injective as $x^3$ is strictly increasing. For further practice, see Difference Between Relation And Function.


Applications in Mathematics

  • Injective functions used in coding and cryptography

  • Surjective functions used in solving equations for all possible outputs

  • Injective mappings important for set cardinality arguments

  • Surjective functions needed for defining quotient spaces in algebra

  • Both properties vital in constructing bijective transformations

  • Understanding function types aids JEE mathematics preparation

Summary in One Line

In simple words, an injective function produces unique outputs for different inputs, whereas a surjective function ensures every output is used at least once.


Competitive Exams after 12th Science
tp-imag
bottom-arrow
tp-imag
bottom-arrow
tp-imag
bottom-arrow
tp-imag
bottom-arrow
tp-imag
bottom-arrow
tp-imag
bottom-arrow

FAQs on What Is the Difference Between Injective and Surjective Functions?

1. What is the difference between injective and surjective functions?

Injective and surjective functions differ based on how elements from the set map to each other:

  • Injective (One-to-one): Every element in the domain maps to a unique element in the codomain. No two different inputs have the same output.
  • Surjective (Onto): Every element in the codomain is the output of at least one element from the domain. The function "covers" the codomain completely.
In summary, injective relates to uniqueness, while surjective relates to completeness of mapping.

2. How can you tell if a function is injective?

A function is injective if each input maps to a unique output.

  • If f(a) = f(b), then a = b
  • No two different domain values have the same image
  • The graph passes the horizontal line test
For example, f(x) = 2x + 3 is injective because each value of x produces a distinct result.

3. How can you identify a surjective function?

A function is surjective if every element in the codomain is the image of at least one element in the domain.

  • For every y in the codomain, there is at least one x in the domain such that f(x) = y
  • All output values are "used"
  • Example: f(x) = x3 maps every real number to every real number, making it surjective on ℝ → ℝ

4. What is an example of a function that is injective but not surjective?

A function like f(x) = ex from ℝ to ℝ is injective but not surjective.

  • No two different x produce the same result (injective)
  • However, negative real numbers are never outputs, so it's not surjective
Thus, f(x) = ex is a clear example of this case.

5. What is an example of a surjective but not injective function?

The function f(x) = x2 defined from ℝ to [0, ∞) is surjective but not injective.

  • Every non-negative number has a pre-image (surjective)
  • Both positive and negative x values map to the same output (e.g., f(2) = f(-2))
This means uniqueness (injectivity) fails, but every codomain value is achieved (surjectivity).

6. What does it mean for a function to be bijective?

A function is bijective if it is both injective and surjective.

  • Every output is mapped by one and only one input
  • Combines one-to-one correspondence and full codomain coverage
  • Examples: f(x) = x + 3 on ℝ → ℝ
Bijective functions are invertible, with each output having exactly one input.

7. How are one-to-one, onto, and bijective functions relevant in CBSE syllabus?

Understanding one-to-one (injective), onto (surjective), and bijective functions is crucial for classifying and solving function-related questions in the CBSE syllabus.

  • Helps in identifying function types for questions on sets and relations
  • Essential for inverse function topics
  • Forms the basis for mapping and real-life mathematical problems in board exams

8. Is every injective function also surjective?

No, not every injective function is surjective.

  • Injective means each input gives unique output, but not all codomain elements are necessarily mapped
  • An injective function can leave some elements of the codomain unused
For a function to be both, it must be bijective.

9. What are the practical uses of injective and surjective functions?

Both injective and surjective functions have important applications:

  • Injective: Used in encryption, uniqueness in assignments, and information theory
  • Surjective: Useful in coding theory and covering all possibility scenarios
  • Bijective: Key in reversible processes and establishing equivalence between sets

10. Can a function be neither injective nor surjective?

Yes, a function can be neither injective nor surjective.

  • For example, f(x) = x2 from ℝ to ℝ is neither, as it maps multiple x values to the same y and does not cover negative numbers in the codomain
Such functions are common in standard syllabus problems involving mappings.