Class 11Mathematics · Sets & FunctionsFull chapter

Relations and Functions

The whole chapter in one place — read it, then test yourself. Clear notes, formula sheet, a practice quiz, and worked NCERT solutions & PYQs.

Ordered Pairs and the Cartesian Product of Sets

Quick answer An ordered pair (a, b) has a fixed order, and the Cartesian product A × B collects all such pairs formed by taking a from A and b from B.

An ordered pair is a pair of elements written in a fixed order, denoted (a, b), where a is called the first component and b the second component. Unlike a set, order matters here: (2, 3) and (3, 2) are different ordered pairs, whereas {2, 3} and {3, 2} are the same set.

Equality of ordered pairs: Two ordered pairs (a, b) and (c, d) are equal if and only if a = c and b = d.

Given two non-empty sets A and B, the Cartesian product A × B is the set of all ordered pairs (a, b) such that a ∈ A and b ∈ B. In set-builder form, A × B = {(a, b) : a ∈ A, b ∈ B}. If A = ∅ or B = ∅, then A × B = ∅ by definition.

If A and B are finite sets with n(A) = p and n(B) = q, then A × B has exactly pq ordered pairs, so n(A × B) = n(A) × n(B). In general A × B ≠ B × A unless A = B or one of the sets is empty, because the order of components is different. More generally, for three sets A, B, C, the Cartesian product A × B × C consists of ordered triplets (a, b, c).

Worked example. Let A = {1, 2} and B = {3, 4}. Then:

  • A × B = {(1, 3), (1, 4), (2, 3), (2, 4)}
  • B × A = {(3, 1), (3, 2), (4, 1), (4, 2)}

Clearly A × B ≠ B × A, and n(A × B) = n(A) × n(B) = 2 × 2 = 4, which matches the 4 pairs listed.

Ordered pair equality (a, b) = (c, d) ⇔ a = c and b = d
Cartesian product A × B = {(a, b) : a ∈ A, b ∈ B}
Cardinality of A×B n(A × B) = n(A) × n(B)
Distributive law A × (B ∩ C) = (A × B) ∩ (A × C) also holds for union
Remember
  • Ordered pairs preserve order; (a, b) = (c, d) if and only if a = c and b = d.
  • A × B = {(a, b) : a ∈ A, b ∈ B}; if either set is empty, A × B is empty.
  • n(A × B) = n(A) × n(B) for finite sets.
  • In general A × B ≠ B × A.
  • A × (B ∩ C) = (A × B) ∩ (A × C), and the same distributive pattern holds for union.

Relations: Domain, Co-domain and Range

Quick answer A relation from A to B is any subset of A × B; its domain is the set of first elements used and its range is the set of second elements used, while the co-domain is B itself.

A relation R from a non-empty set A to a non-empty set B is defined as any subset of the Cartesian product A × B. If (a, b) ∈ R, we say "a is related to b" and write a R b, where a ∈ A and b ∈ B.

Three sets are associated with a relation R from A to B:

  • Domain of R is the set of all first components of the ordered pairs in R.
  • Co-domain of R is the whole set B, fixed in advance whether or not every element of B is used.
  • Range of R is the set of all second components actually occurring in the ordered pairs of R; the range is always a subset of the co-domain.

If n(A) = p and n(B) = q, the total number of possible relations from A to B equals the number of subsets of A × B, which is 2pq, since A × B itself has pq elements.

Worked example. Let A = {1, 2, 3, 4} and define R = {(x, y) : y = x + 1, x ∈ A, y ∈ A}. Testing each x ∈ A: x = 1 gives y = 2 (valid); x = 2 gives y = 3 (valid); x = 3 gives y = 4 (valid); x = 4 gives y = 5, which is not in A, so it is rejected. Hence R = {(1, 2), (2, 3), (3, 4)}.

Domain of R = {1, 2, 3}, Co-domain of R = A = {1, 2, 3, 4}, and Range of R = {2, 3, 4}. Notice Range ⊆ Co-domain, and here Range ≠ Co-domain since 1 is never a second component.

Relation R ⊆ A × B
Domain Dom(R) = {a : (a, b) ∈ R for some b}
Range Range(R) = {b : (a, b) ∈ R for some a}
Number of relations 2^(n(A) × n(B)) total number of subsets of A × B
Remember
  • A relation R from A to B is any subset of A × B.
  • Domain = set of first elements actually used; Range = set of second elements actually used.
  • Co-domain is the full target set B, fixed by definition; Range ⊆ Co-domain always.
  • A relation may be described in roster form, set-builder form, or by an arrow diagram.
  • The number of relations possible from A to B is 2^(n(A) × n(B)).

Functions as a Special Type of Relation

Quick answer A function from A to B is a relation in which every element of A has exactly one image in B — a relation with an added uniqueness condition.

A function f from a non-empty set A to a non-empty set B is a special relation in which every element of A is associated with exactly one element of B. Formally, f : A → B is a function if:

  1. every a ∈ A has an image in B (nothing in A is left out), and
  2. each a ∈ A has only one image in B (no element of A is related to two or more elements of B).

Since a function is a relation, it also has a domain (= A, and here every element of A must be used), co-domain (= B), and range (the set of actual images, a subset of B). If f(a) = b, then b is called the image of a and a is called a pre-image of b.

Every function is a relation, but a relation is a function only if it satisfies both conditions above; in particular, no element of A may repeat as a first component with two different second components.

Worked example. Let A = {1, 2, 3} and B = {4, 5, 6, 7}.

  • R1 = {(1, 4), (2, 5), (3, 6)} is a function, since every element of A appears exactly once as a first component.
  • R2 = {(1, 4), (1, 5), (2, 6), (3, 7)} is not a function, because 1 is related to both 4 and 5, violating uniqueness of image.
  • R3 = {(1, 4), (2, 5)} is not a function from A to B, because 3 ∈ A has no image at all.

For real functions given by a formula, such as f(x) = x2, the domain is taken to be the largest subset of R for which the formula gives a well-defined real value, unless a smaller domain is explicitly specified.

Function condition ∀ a ∈ A, ∃! b ∈ B such that (a, b) ∈ f exactly one image for every input
Image and pre-image f(a) = b ⇒ b is the image of a, a is a pre-image of b
Remember
  • A function is a relation where every element of the domain has exactly one image.
  • Every function is a relation, but not every relation is a function.
  • f(a) = b means b is the image of a and a is a pre-image of b.
  • The range of a function is always a subset of (and may equal) its co-domain.
  • For a formula-defined real function, the natural domain is the largest subset of R for which the formula is defined.

Domain and Range of Standard Real Functions

Quick answer Identity, constant, polynomial and rational functions are the basic building blocks of real functions, each with a characteristic domain and range.

A real-valued function of a real variable has both its domain and co-domain as subsets of R. The following standard functions form the basic vocabulary used throughout the chapter.

Identity function: f : R → R defined by f(x) = x for every x ∈ R. Domain = R, Range = R. Its graph is the straight line through the origin inclined at 45° to the axes.

Constant function: f : R → R defined by f(x) = c for every x ∈ R, where c is a fixed real number. Domain = R, Range = {c}, a single value.

Polynomial function: f(x) = a0 + a1x + a2x2 + … + anxn, where n is a non-negative integer and a0, a1, …, an are real constants. Every polynomial expression is defined for all real x, so its domain is always R; the range depends on the degree (for example, the range of f(x) = x2 is [0, ∞)).

Rational function: f(x) = g(x)/h(x), where g(x) and h(x) are polynomial functions and h(x) ≠ 0. Its domain is R minus the roots of h(x), i.e. all real x for which the denominator does not vanish.

Worked example. Find the domain of f(x) = (x2 + 2x + 1)/(x2 − 5x + 6). The denominator factors as (x − 2)(x − 3), which is zero when x = 2 or x = 3. So the domain is R − {2, 3}, that is, all real numbers except 2 and 3.

A closely related task is finding the domain of functions involving square roots, such as f(x) = √(x − 3): here the expression under the root must be non-negative, so x − 3 ≥ 0, giving domain [3, ∞).

Identity function f(x) = x domain R, range R
Constant function f(x) = c domain R, range {c}
Polynomial function f(x) = a₀ + a₁x + a₂x² + … + aₙxⁿ domain R
Rational function domain Domain = R − {x : h(x) = 0} for f(x) = g(x)/h(x)
Remember
  • Identity function f(x) = x: domain R, range R.
  • Constant function f(x) = c: domain R, range {c}.
  • Polynomial functions are defined for every real x, so their domain is always R.
  • A rational function g(x)/h(x) has domain R minus the zeros of h(x).
  • For functions containing a square root, the domain requires the radicand to be ≥ 0.

Modulus, Signum and Greatest Integer Functions

Quick answer These three special piecewise-defined real functions are frequently tested for their domain, range and value computations.

Modulus (absolute value) function: f : R → R defined by f(x) = |x|, where |x| = x if x ≥ 0, and |x| = −x if x < 0. It measures the distance of x from 0 on the number line, so it is never negative. Domain = R, Range = [0, ∞).

Signum function: f : R → R defined by f(x) = 1 if x > 0; f(x) = 0 if x = 0; f(x) = −1 if x < 0. It only records the sign of x. Domain = R, Range = {−1, 0, 1}, a set of just three values.

Greatest integer function (floor function): f : R → R defined by f(x) = [x], where [x] denotes the greatest integer less than or equal to x. For example, [4] = 4, [4.7] = 4, [−4] = −4, and [−4.7] = −5, since for negative non-integers the greatest integer function rounds further down, not towards zero. Domain = R, Range = Z, the set of all integers.

Worked example. Evaluate [3.8], [−2.3], sgn(−7) and |−7|.

  • [3.8]: the greatest integer ≤ 3.8 is 3.
  • [−2.3]: the greatest integer ≤ −2.3 is −3, not −2, since −2 > −2.3.
  • sgn(−7) = −1, since −7 < 0.
  • |−7| = 7, since the modulus discards the sign.
Modulus function |x| = x (x ≥ 0), |x| = −x (x < 0) range [0, ∞)
Signum function sgn(x) = 1 (x>0), 0 (x=0), −1 (x<0) range {−1, 0, 1}
Greatest integer function [x] = greatest integer ≤ x range = Z
Remember
  • Modulus function: domain R, range [0, ∞); |x| = x for x ≥ 0 and −x for x < 0.
  • Signum function: domain R, range {−1, 0, 1}, depends only on the sign of x.
  • Greatest integer function [x]: domain R, range Z; gives the greatest integer ≤ x.
  • For negative non-integers, [x] rounds down, e.g. [−2.3] = −3, not −2.
  • These piecewise-defined functions are common sources of CBSE domain/range and evaluation questions.

Algebra of Real Functions

Quick answer Given two real functions with overlapping domains, we can add, subtract, multiply and divide them pointwise, with the quotient additionally requiring the divisor to be non-zero.

Let f and g be two real-valued functions with domains Dom(f) and Dom(g) respectively, both subsets of R. New functions can be built from f and g using ordinary arithmetic, applied pointwise, i.e. one value of x at a time:

  • Sum: (f + g)(x) = f(x) + g(x)
  • Difference: (f − g)(x) = f(x) − g(x)
  • Product: (fg)(x) = f(x) · g(x)
  • Quotient: (f/g)(x) = f(x)/g(x), defined only where g(x) ≠ 0
  • Scalar multiple: (kf)(x) = k · f(x), for a real constant k

In every case, the domain of the new function is Dom(f) ∩ Dom(g); for the quotient, we further remove from this intersection every x where g(x) = 0.

Worked example. Let f(x) = x + 1 and g(x) = x2 − 1, both with domain R. Find (f + g)(x), (f − g)(x), (fg)(x) and (f/g)(x), along with their domains.

  • (f + g)(x) = (x + 1) + (x2 − 1) = x2 + x, domain R.
  • (f − g)(x) = (x + 1) − (x2 − 1) = −x2 + x + 2, domain R.
  • (fg)(x) = (x + 1)(x2 − 1) = (x + 1)2(x − 1), domain R.
  • (f/g)(x) = (x + 1)/(x2 − 1) = 1/(x − 1) for x ≠ −1, x ≠ 1; domain is R − {−1, 1}. Both values must be excluded: g(1) = 0 keeps x = 1 out because it is a genuine pole of 1/(x − 1), while g(−1) = 0 keeps x = −1 out even though the factor (x + 1) cancels algebraically, since the original quotient (f/g)(x) was never defined there.
Sum (f + g)(x) = f(x) + g(x)
Difference (f − g)(x) = f(x) − g(x)
Product (fg)(x) = f(x) · g(x)
Quotient (f/g)(x) = f(x)/g(x) domain excludes points where g(x) = 0
Remember
  • (f ± g)(x) = f(x) ± g(x), (fg)(x) = f(x)g(x), (f/g)(x) = f(x)/g(x); all defined pointwise.
  • Domain of f ± g and fg is Dom(f) ∩ Dom(g).
  • Domain of f/g is Dom(f) ∩ Dom(g) minus the points where g(x) = 0.
  • Even if a common factor cancels algebraically in f/g, the original zero of g must still be excluded from the domain.
  • (kf)(x) = k·f(x) scales every output by the constant k; its domain is unchanged from f.

The formula sheet

Every formula in this chapter, in one place — screenshot it before your exam.

(a, b) = (c, d) ⇔ a = c and b = d
Ordered pair equality
A × B = {(a, b) : a ∈ A, b ∈ B}
Cartesian product
n(A × B) = n(A) × n(B)
Cardinality of A×B
A × (B ∩ C) = (A × B) ∩ (A × C)
Distributive law
R ⊆ A × B
Relation
Dom(R) = {a : (a, b) ∈ R for some b}
Domain
Range(R) = {b : (a, b) ∈ R for some a}
Range
2^(n(A) × n(B))
Number of relations
∀ a ∈ A, ∃! b ∈ B such that (a, b) ∈ f
Function condition
f(a) = b ⇒ b is the image of a, a is a pre-image of b
Image and pre-image
f(x) = x
Identity function
f(x) = c
Constant function
f(x) = a₀ + a₁x + a₂x² + … + aₙxⁿ
Polynomial function
Domain = R − {x : h(x) = 0}
Rational function domain
|x| = x (x ≥ 0), |x| = −x (x < 0)
Modulus function
sgn(x) = 1 (x>0), 0 (x=0), −1 (x<0)
Signum function
[x] = greatest integer ≤ x
Greatest integer function
(f + g)(x) = f(x) + g(x)
Sum
(f − g)(x) = f(x) − g(x)
Difference
(fg)(x) = f(x) · g(x)
Product
(f/g)(x) = f(x)/g(x)
Quotient

Test yourself

Tap an answer to check it instantly — you'll see why it's right, and what to revise if it isn't.

0 correct · 0/12 answered
Q1 Cartesian Product easy

If n(A) = 3 and n(B) = 4, what is n(A × B)?

Q2 Ordered Pairs easy

If (a − 1, b + 2) = (3, 5), find the values of a and b.

Q3 Relations - Range medium

For the relation R = {(1, 2), (1, 3), (2, 3), (3, 4)}, what is the range of R?

Q4 Relations - Counting medium

If n(A) = 2 and n(B) = 3, how many relations can be defined from A to B?

Q5 Functions vs Relations medium

Which of the following relations from {1, 2, 3} is NOT a function?

Q6 Domain - Rational Function easy

What is the domain of f(x) = 1/(x − 3)?

Q7 Domain - Square Root medium

What is the domain of f(x) = √(x − 2)?

Q8 Range - Polynomial easy

What is the range of f(x) = x² for x ∈ R?

Q9 Greatest Integer Function medium

What is the value of [−3.2] using the greatest integer function?

Q10 Signum Function easy

What is the value of the signum function sgn(0)?

Q11 Algebra of Functions - Product easy

If f(x) = x + 1 and g(x) = x − 1, what is (fg)(x)?

Q12 Algebra of Functions - Domain of Quotient hard

If f(x) = x² − 4 and g(x) = x − 2, what is the domain of (f/g)(x)?

NCERT solutions & previous-year questions

Step-by-step model answers — tap a question to reveal the full solution.

NCERT questions 6

1 If A = {−1, 1}, find A × A × A.Cartesian Product

Since A = {−1, 1}, we have n(A) = 2, so n(A × A × A) = 23 = 8. Each ordered triplet (a, b, c) is formed by choosing a, b, c independently from A = {−1, 1}. Listing all 8 triplets:

A × A × A = {(−1, −1, −1), (−1, −1, 1), (−1, 1, −1), (−1, 1, 1), (1, −1, −1), (1, −1, 1), (1, 1, −1), (1, 1, 1)}.

2 If (x/3 + 1, y − 2/3) = (5/3, 1/3), find the values of x and y.Ordered Pairs

By equality of ordered pairs, the corresponding components must be equal:

x/3 + 1 = 5/3 ⇒ x/3 = 5/3 − 1 = 2/3 ⇒ x = 2.

y − 2/3 = 1/3 ⇒ y = 1/3 + 2/3 = 1.

Hence x = 2 and y = 1.

3 A relation R is defined by R = {(x, y) : y = x + 5, x is a natural number less than 4}. Write R in roster form and find its domain and range.Relations

Since x is a natural number less than 4, x can take the values 1, 2, 3. For each x, y = x + 5:

x = 1 ⇒ y = 6; x = 2 ⇒ y = 7; x = 3 ⇒ y = 8.

So R = {(1, 6), (2, 7), (3, 8)} in roster form.

Domain of R = {1, 2, 3}.

Range of R = {6, 7, 8}.

4 Find the domain of the function f(x) = (x² + 2x + 1)/(x² − 8x + 12).Domain of Real Functions

The function f is defined for all real x except where the denominator is zero. Factorise the denominator:

x2 − 8x + 12 = (x − 2)(x − 6).

This is zero when x = 2 or x = 6. Since division by zero is undefined, these two values must be excluded from the domain.

Domain of f = R − {2, 6}.

5 Let f(x) = x² and g(x) = 2x + 1 be two real functions with domain R. Find (f + g)(x), (f − g)(x), (fg)(x) and (f/g)(x), stating the domain of each.Algebra of Functions

Both f and g have domain R, so Dom(f) ∩ Dom(g) = R.

(f + g)(x) = x2 + 2x + 1, domain R.

(f − g)(x) = x2 − 2x − 1, domain R.

(fg)(x) = x2(2x + 1) = 2x3 + x2, domain R.

(f/g)(x) = x2/(2x + 1), defined only where 2x + 1 ≠ 0, i.e. x ≠ −1/2. So domain of f/g = R − {−1/2}.

6 The signum function f : R → R is defined by f(x) = 1 if x > 0, f(x) = 0 if x = 0, and f(x) = −1 if x < 0. Find f(5), f(−5) and f(0), and write the domain and range of f.Signum Function

Since 5 > 0, f(5) = 1.

Since −5 < 0, f(−5) = −1.

Since 0 = 0, f(0) = 0.

The rule is defined for every real number, so Domain of f = R. The only values the function ever takes are −1, 0 and 1, so Range of f = {−1, 0, 1}.

Previous-year board questions 4

Q1 Find the domain of the real function f(x) = 1/(x² − 1). CBSE 2019 1 mark

The function is undefined when the denominator is zero, i.e. when x2 − 1 = 0, which gives x = 1 or x = −1.

Hence the domain of f is R − {−1, 1}.

Q2 Let f(x) = √x and g(x) = x be two real functions, where f has domain [0, ∞) and g has domain R. Find (f + g)(x), (f − g)(x), (fg)(x) and (f/g)(x), stating the domain of each. CBSE 2021 3 marks

Since Dom(f) = [0, ∞) and Dom(g) = R, the common domain is Dom(f) ∩ Dom(g) = [0, ∞).

(f + g)(x) = √x + x, domain [0, ∞).

(f − g)(x) = √x − x, domain [0, ∞).

(fg)(x) = √x · x = x3/2, domain [0, ∞).

(f/g)(x) = √x / x = 1/√x, which additionally requires g(x) ≠ 0, i.e. x ≠ 0. So domain of f/g = (0, ∞).

Q3 A relation R is defined from A = {2, 3, 4, 5} to B = {3, 6, 7, 10} by R = {(x, y) : x divides y, x ∈ A, y ∈ B}. Write R in roster form and find its domain and range. CBSE 2018 3 marks

Check each x ∈ A against every y ∈ B for divisibility:

x = 2 divides 6 and 10, giving (2, 6) and (2, 10).

x = 3 divides 3 and 6, giving (3, 3) and (3, 6).

x = 4 divides none of 3, 6, 7, 10.

x = 5 divides 10, giving (5, 10).

So R = {(2, 6), (2, 10), (3, 3), (3, 6), (5, 10)}.

Domain of R = {2, 3, 5}. Range of R = {3, 6, 10}.

Q4 Let f = {(1, 1), (2, 3), (0, −1), (−1, −3)} be a function from Z to Z defined by f(x) = ax + b for some integers a and b. Determine a and b, write f(x), and find f(5). CBSE 2022 3 marks

Using the points (1, 1) and (2, 3): a(1) + b = 1 and a(2) + b = 3.

Subtracting the first equation from the second: a = 2. Substituting back: 2 + b = 1 ⇒ b = −1.

So f(x) = 2x − 1. Check: f(0) = −1 and f(−1) = −3, both matching the given pairs.

Therefore f(5) = 2(5) − 1 = 10 − 1 = 9.

Part of Priodemy for School

Interactive Maths & Science — free with every school on Priodemy EduSuite. Explore more chapters and labs on the Priodemy for School hub.

Ask AI