Ma · Mathematics

Show That the Identity Function on Any Set Is a Bijection

Published By the 9to5Science editorial team

At a glance

  1. 1. Define the map

    For a set A, the identity function maps A to itself and sends every element to itself.

  2. 2. Check injectivity

    If two inputs have the same output, they must be the same element.

  3. 3. Check surjectivity

    Every element of the codomain is reached by choosing that element as the input.

  4. 4. Include the empty set

    When A is empty, both properties hold vacuously, so the identity map is still bijective.

For any set AA, the identity function on AA is the map from AA to itself that leaves every element unchanged. To prove that it is a bijection, show that it is both injective and surjective. These arguments do not depend on whether AA is finite, infinite, or empty.

Define the identity function

The identity function on AA is written id⁡A\operatorname{id}_A and defined by

id⁡A:A→A,id⁡A(x)=x.\operatorname{id}_A:A\to A,\qquad \operatorname{id}_A(x)=x.

A function is injective if distinct inputs always have distinct outputs. It is surjective if every element of its codomain is the output of at least one input. A function that has both properties is bijective.

The fact that the domain and codomain here are both AA matters: the identity function is specifically a map from a set to itself.

Proof of injectivity

Take any x,y∈Ax,y\in A and suppose their images under the identity function are equal. By its definition,

id⁡A(x)=id⁡A(y)⟹x=y.\operatorname{id}_A(x)=\operatorname{id}_A(y) \quad\Longrightarrow\quad x=y.

Therefore, whenever two inputs have the same output, they are equal. This is exactly the definition of injectivity, so id⁡A\operatorname{id}_A is injective.

Proof of surjectivity

Take any element yy in the codomain AA. To show that yy is reached by the function, choose x=yx=y. This is a valid input because y∈Ay\in A, and

id⁡A(x)=id⁡A(y)=y.\operatorname{id}_A(x)=\operatorname{id}_A(y)=y.

Thus every element of the codomain has a preimage, so id⁡A\operatorname{id}_A is surjective.

Since it is both injective and surjective, id⁡A\operatorname{id}_A is a bijection.

Worked example

Let A={1,2,3}A=\{1,2,3\}. The identity function sends each element to itself:

Input xxOutput id⁡A(x)\operatorname{id}_A(x)
11
22
33

No two different inputs have the same output, so the function is injective. Each element in the codomain {1,2,3}\{1,2,3\} appears as an output, so the function is surjective. Hence it is bijective.

The same proof works if AA contains infinitely many elements. It uses only the rule id⁡A(x)=x\operatorname{id}_A(x)=x, not the number of elements in the set.

What if the set is empty?

The result includes A=∅A=\varnothing. There are no elements to map, so the identity function is the empty function ∅→∅\varnothing\to\varnothing.

It is injective because there are no two inputs that could violate injectivity. It is surjective because there are no elements in the codomain that need preimages. These are sometimes called vacuous conditions: no counterexample exists because there are no elements to check. Therefore, the identity function on the empty set is also bijective.

The inverse is the identity itself

A bijection has an inverse function. For the identity function, applying the map and then applying it again changes nothing:

id⁡A(id⁡A(x))=xfor every x∈A.\operatorname{id}_A\bigl(\operatorname{id}_A(x)\bigr)=x \qquad\text{for every }x\in A.

Consequently, its inverse is itself:

(id⁡A)−1=id⁡A.(\operatorname{id}_A)^{-1}=\operatorname{id}_A.

This gives another way to recognize that the identity function is bijective: it has a two-sided inverse, namely itself.

Common mistakes

  • Checking only that outputs belong to AA. That confirms the map is well-defined as a function A→AA\to A, but it does not by itself prove injectivity or surjectivity. Check both properties explicitly.
  • Confusing the identity map with an inclusion. If AA is a subset of a larger set BB, the inclusion map A→BA\to B sends each element to itself too, but it need not be surjective onto BB. For example, the inclusion {1}→{1,2}\{1\}\to\{1,2\} misses 22. The identity map on AA has codomain AA, so every element of its codomain is reached.
  • Assuming the set must be nonempty. The empty set is allowed, and its identity function is a bijection by the definitions of injectivity and surjectivity.

Spotted an error? Send a correction. Read how we write and check articles in our editorial policy.