Mathematics · 1st year

Relations and Functions (Class 12): Equivalence, One-one and Onto, Inverse

EAPCET · JEE9 min read10 practice questions

NCERT Class 12 Maths, Chapter 1. JEE Main 2027 syllabus, unit 1.

1. Who likes which curry

Sunday morning. Before she starts cooking, Amma asks everyone at home: “Which curry do you like?”

Nanna likes brinjal. Little sister likes okra. Little brother likes both.

Amma writes the answers on a paper as pairs: (Nanna, brinjal), (sister, okra), (brother, brinjal), (brother, okra).

This list of pairs tells us who is linked to what. In maths, such a list is called a relation.

So a relation is just a set of pairs. In symbols: a relation R from A to B is any subset of A × B. If (a, b) is in R, we write a R b.

In this chapter we mostly take one set A and pairs from A to A, so R ⊆ A × A.

2. Three questions to ask a relation

Take the children of one class and the relation “born in the same month”.

Question one: is everyone related to themselves? Ravi is born in the same month as Ravi. That is true for anyone. When (a, a) is in R for every a in A, R is reflexive.

Question two: does it work the other way round? If Ravi and Sita are born in the same month, then Sita and Ravi are too. When (a, b) in R always brings (b, a) in R, R is symmetric.

Question three: does the chain close? Ravi and Sita share a month. Sita and Anil share a month. Then Ravi and Anil share it too. When (a, b) and (b, c) in R always bring (a, c) in R, R is transitive.

Not every relation says yes three times. Look at “is taller than”. Nobody is taller than himself, so it is not reflexive. If Ravi is taller than Sita, Sita is not taller than Ravi, so it is not symmetric. But if Ravi is taller than Sita and Sita is taller than Anil, Ravi is taller than Anil. So it is transitive.

“Is a friend of” is symmetric. But your friend’s friend need not be your friend, so it need not be transitive.

3. Equivalence relation: sorting into tins

A relation that says yes to all three questions is an equivalence relation. “Born in the same month” is one.

Think of the kitchen shelf. Rice goes in one tin, toor dal in another, sugar in a third. Grains of the same kind go into the same tin. Every grain sits in some tin. No grain sits in two tins.

An equivalence relation sorts a set in exactly this way. Things related to each other go into the same tin. Each tin is called an equivalence class. The tin that holds a is written [a].

For “born in the same month” there is one tin for each month, so 12 tins.

Now a question for you. Can one child sit in two tins at once?

(Stop for a moment. Think.)

No. Each child is born in only one month. Equivalence classes always behave like this: together they make the whole set, and no two of them overlap.

On the integers, “a − b is divisible by 3” is also an equivalence relation. Its tins are the numbers that leave remainder 0, 1 or 2 on division by 3, so there are 3 tins.

4. Function: one answer for each person

Early morning Amma asks: “Tea, coffee or milk?” Each person at home gives exactly one answer. Nobody may say “both”. Nobody may stay silent. Two people may give the same answer; that is fine.

A relation in which every element of the first set has exactly one partner in the second set is called a function. We write f: A → B, and the partner of a is f(a).

  • A is the domain: here, the people at home.
  • B is the codomain: here, {tea, coffee, milk}.
  • The set of answers actually given is the range. If everyone says tea, the range is just {tea}.

With 3 people and 3 choices each, there are 3 × 3 × 3 = 27 different functions. In general, if n(A) = m and n(B) = n, there are nᵐ functions from A to B.

5. Bus seats: one-one and onto

Picture the school bus. Each child is given a seat. That is a function too: children → seats.

One child per seat. If no two children are given the same seat, the function is one-one. In symbols: f(a₁) = f(a₂) only when a₁ = a₂.

No empty seat. If every seat gets somebody, the function is onto. In symbols: range = codomain.

Both at once. Then every seat has exactly one child. Such a function is bijective (a bijection). For finite sets, the number of children then equals the number of seats.

How many one-one ways are there? The first child has n seats to choose from, the next n − 1, the next n − 2, and so on, one factor for each child.

For real functions: f(x) = x² on R is not one-one, because f(-2) = f(2) = 4. It is not onto R either, because x² is never negative, so −1 is never an output.

6. One after the other: composition

Before cooking rice we wash it. Call washing f and cooking g. First f, then g. We write this as g∘f, and (g∘f)(x) = g(f(x)).

The name shows g first, but the work starts with f. The inside bracket is done first.

What if we swap the order? Cook first and then wash, and the rice is spoilt. With functions too, g∘f and f∘g are usually different.

7. Going back: the inverse

If the bus seating is a bijection, you can look at any seat number and say who sits there. This return rule, from seat back to child, is the inverse function f⁻¹.

If two children shared a seat, whom should that seat point to? An empty seat points to nobody. That is why only a bijection has an inverse.

f⁻¹(f(x)) = x. To find f⁻¹, write y = f(x) and solve for x in terms of y.

Key formulas

Idea Formula
Relation on A any subset of A × A
Reflexive (a, a) ∈ R for every a ∈ A
Symmetric (a, b) ∈ R ⇒ (b, a) ∈ R
Transitive (a, b), (b, c) ∈ R ⇒ (a, c) ∈ R
Equivalence reflexive + symmetric + transitive
Relations on a set with n elements 2n²
Reflexive relations on it 2n² − n
Functions, n(A) = m, n(B) = n nᵐ
One-one functions (m ≤ n) n(n − 1)(n − 2)… (m factors)
Onto functions from m elements onto 2 2ᵐ − 2
Composition (g∘f)(x) = g(f(x))
Inverse exists only for a bijection; f⁻¹(f(x)) = x

Worked examples

Example 1. On A = {a, b, c, d}, R = {(a, a), (b, b), (c, c), (d, d), (a, c), (c, a), (b, d), (d, b)}. Which statement about R is true?

  1. Reflexive? (a, a), (b, b), (c, c), (d, d) are all in R. Yes.
  2. Symmetric? (a, c) comes with its reverse (c, a), and (b, d) with (d, b). Yes.
  3. Transitive? A chain can run only inside {a, c} or inside {b, d}, and R holds every pair within each of these. For example, (a, c) and (c, a) give (a, a), which is in R. Yes.
  4. All three hold. R sorts A into the classes {a, c} and {b, d}.

Answer: R is an equivalence relation

Example 2. On A = {1, 2, …, 40}, a R b means that a and b have the same sum of digits. How many elements are in the equivalence class [15]?

  1. The digits of 15 add up to 1 + 5 = 6. So [15] holds every b in A whose digits add up to 6.
  2. [15] = {6, 15, 24, 33}.
  3. Count = 4. (A splits into 12 classes in all, one for each digit sum; that is a different number.)

Answer: 4

Example 3. A has 3 elements and B has 5 elements. How many one-one functions are there from A to B?

  1. The first element of A can go to any of the 5 elements of B.
  2. The second must go somewhere else: 4 choices. The third: 3 choices.
  3. Total = 5 × 4 × 3 = 60. (All functions would be 5³ = 125.)

Answer: 60

Example 4. f(x) = 2x + 1 and g(x) = x². Find (g∘f)(3).

  1. (g∘f)(3) = g(f(3)): f works first.
  2. f(3) = 2 × 3 + 1 = 7.
  3. g(7) = 7² = 49. (The other order, f(g(3)) = 2 × 9 + 1 = 19, is a different number.)

Answer: 49

Example 5. f: R → R, f(x) = 3x − 5 is a bijection. Find f⁻¹(10).

  1. Write y = 3x − 5 and solve for x: x = (y + 5) / 3. So f⁻¹(y) = (y + 5) / 3.
  2. f⁻¹(10) = (10 + 5) / 3 = 15 / 3 = 5.
  3. Check: f(5) = 3 × 5 − 5 = 10. Correct.

Answer: 5

Common mistakes

  • Doing g first in g∘f. In g(f(x)) the inside, f, works first.
  • Counting 2ⁿ relations. A relation picks from the n² pairs of A × A, so there are 2n².
  • Mixing up the count of all functions and of one-one functions. nᵐ counts all functions; the one-one count drops by one choice at each step.
  • Thinking symmetric and transitive together force reflexive. They do not, when some element has no pair at all.
  • Reading f⁻¹(x) as 1/f(x). The inverse undoes f; it is not a reciprocal.
  • Ignoring the codomain. x² is not onto R, but it is onto [0, ∞).

Recap: three lines to remember

  1. A relation is a list of pairs. Reflexive, symmetric and transitive together make an equivalence relation, which sorts a set into tins that never overlap.
  2. A function gives each input exactly one answer. One child per seat is one-one; no empty seat is onto; both together is a bijection.
  3. (g∘f)(x) = g(f(x)): f works first. Only a bijection has an inverse f⁻¹.

References

Practice questions

Question language

Choose an answer, then press Check: you see at once whether it is right, and why.

If the English and Telugu versions of a question differ, go by the English text, and please tell us about the difference.

  1. Question 1

    A = {a, b} and B = {1, 2, 3, 4}. How many relations from A to B have exactly two ordered pairs?A = {a, b}, B = {1, 2, 3, 4}. A నుంచి B కి సరిగ్గా రెండు క్రమ జతలు ఉండే సంబంధాలు ఎన్ని?

    Choose an answer first.

    Show answer and explanation

    Report an error

  2. Question 2

    How many reflexive relations are there on A = {1, 2, 3}?A = {1, 2, 3} మీద రిఫ్లెక్సివ్‌ సంబంధాలు ఎన్ని?

    Choose an answer first.

    Show answer and explanation

    Report an error

  3. Question 3

    On A = {2, 4, 6, 8}, R = {(2, 4), (2, 6), (4, 6), (8, 8)}. Which statement about R is true?A = {2, 4, 6, 8} మీద R = {(2, 4), (2, 6), (4, 6), (8, 8)}. R గురించి ఏది సరైనది?

    Choose an answer first.

    Show answer and explanation

    Report an error

  4. Question 4

    On A = {5, 6, 7, 8}, R = {(5, 6), (6, 7)}. What is the smallest number of ordered pairs that must be added to R to make it an equivalence relation?A = {5, 6, 7, 8} మీద R = {(5, 6), (6, 7)}. R ను తుల్యతా సంబంధంగా మార్చాలంటే కనీసం ఎన్ని క్రమ జతలు కలపాలి?

    Choose an answer first.

    Show answer and explanation

    Report an error

  5. Question 5

    How many functions are there from A = {a, b, c} to B = {1, 2}?A = {a, b, c} నుంచి B = {1, 2} కి ఎన్ని ప్రమేయాలు ఉంటాయి?

    Choose an answer first.

    Show answer and explanation

    Report an error

  6. Question 6

    How many onto functions are there from A = {1, 2, 3, 4} to B = {x, y}?A = {1, 2, 3, 4} నుంచి B = {x, y} కి ఆన్‌టు ప్రమేయాలు ఎన్ని?

    Choose an answer first.

    Show answer and explanation

    Report an error

  7. Question 7

    f: {12, 25, 32, 45, 52} → {2, 5} gives each number its last digit. Which is true?f: {12, 25, 32, 45, 52} → {2, 5}; ప్రతి సంఖ్యకూ దాని చివరి అంకెను f ఇస్తుంది. ఏది సరైనది?

    Choose an answer first.

    Show answer and explanation

    Report an error

  8. Question 8

    f: N → N is given by f(n) = n + 3, where N = {1, 2, 3, …}. Which is true?N = {1, 2, 3, …}. f: N → N, f(n) = n + 3. ఏది సరైనది?

    Choose an answer first.

    Show answer and explanation

    Report an error

  9. Question 9

    f(x) = (2x + 3)/(x − 1), x ≠ 1, is one-one. Find f⁻¹(3).f(x) = (2x + 3)/(x − 1), x ≠ 1 వన్‌-వన్‌ ప్రమేయం. f⁻¹(3) ఎంత?

    Choose an answer first.

    Show answer and explanation

    Report an error

  10. Question 10

    f(x) = x + 2 and g(x) = 3x. Find (f∘g)(x) − (g∘f)(x).f(x) = x + 2, g(x) = 3x. (f∘g)(x) − (g∘f)(x) ఎంత?

    Choose an answer first.

    Show answer and explanation

    Report an error

Practise more Mathematics questions

Back to top

In this lesson