What is a Relation?
Open the lesson
What a relation really is: a subset of A × B. Learn domain, range and codomain with an arrow diagram, the five ways to write a relation, why there are 2^(mn) relations from A to B and 2^(m²) on A, the range-versus-codomain trap, and two solved JEE-style examples.
Chapters
- 0:00Introduction
- 0:35Relations are all around us
- 1:16Definition: any subset of A x B
- 2:11Domain, range and codomain
- 3:19Five ways to describe a relation
- 4:09How many relations?
- 5:11Example 1: domain, range, codomain when b = a squared
- 6:24Example 2: how many relations from A to B and on A
- 7:42Quick revision: domain, range and 2 to the power mn
Transcript
0:00Introduction
Hello everyone! Okay, one small puzzle before we start. Set A has three elements, and set B has two. So, A cross B has three times two, that is six ordered pairs, okay? Now tell me: how many different relations can we make from A to B? Six? Most students say six. Actually, the real answer is much bigger! By the end of this video, you will find it yourself. And look, counting relations is a question JEE loves to ask. So, let's begin.
0:35Relations are all around us
See, in daily life we relate things all the time. Ravi is the brother of Priya. This connects a first object, Ravi, to a second object, Priya, in that order, okay? So, as the arrow on screen shows, we write it as an ordered pair: Ravi comma Priya. Next: three is less than five. That gives the pair three comma five. Now flip it. Is five less than three? Of course not! So order matters: three comma five fits the rule, five comma three does not. Clear? So here is today's big idea: a relation is simply a collection of ordered pairs. That's all there is to it!
1:16Definition: any subset of A x B
Let A and B be non-empty sets. Remember, A cross B, with the little cross sign, is the set of all ordered pairs, first element from A, second element from B, okay? So, a relation R from A to B is any subset of A cross B, nothing more. Got it? Alright, quick question. Does a relation have to use every pair? No! It can take some pairs, all the pairs, or even no pair at all. Keep this in mind for counting. Now the notation. If the pair a comma b belongs to R, we write a, R, b, and say a is related to b. The curved symbol, like a rounded letter e, means belongs to. And if the pair does not belong, we put a slash through that symbol, and through the R, okay? One more word. When both sets are the same, a subset of A cross A, we call it a relation on A, okay? Remember this little word, on. It matters in today's last example.
2:11Domain, range and codomain
Now look at this arrow diagram. On the left, set A: two, three, four. On the right, set B: four, six, nine, ten. The rule: an arrow from a to b whenever a divides b. So two sends arrows to four, six and ten, three to six and nine, and four to four itself, okay? Now, the domain of R, written D o m of R, is the set of all first elements: where the arrows start. Here every element of A sends out an arrow, right? The range of R is the set of all second elements: where the arrows land. Which elements of B receive an arrow here? All four of them: four, six, nine and ten. And the codomain is simply the whole set B, whether an arrow lands there or not, okay? So here, range and codomain came out the same. Is that always true? No, careful! The symbol on screen means, is a subset of. The range always sits inside B, but it need not be the whole of B, okay? This is a favourite JEE trap, and you will meet it in Example one.
3:19Five ways to describe a relation
So, how do we write a relation down? Five ways. First, roster form: just list the pairs. Second, set-builder form: in curly brackets, the pair a comma b, a colon, then the rule. The colon is read as, such that. Third, the arrow diagram, which you just saw: one arrow for every pair. Fourth, the relation matrix: a table with a one in row a and column b whenever a is related to b. So in our divides example, row two, column four gets a one, because two divides four. With me? And fifth, for a relation on one set, the directed graph, or digraph: the elements as dots, and an arrow for each pair. And a pair like a comma a? It becomes a little loop. Nice and simple.
4:09How many relations?
Now, back to our puzzle. Let A have m elements and B have n elements. Then A cross B has m times n pairs. The double arrow is read as, so. And every subset of A cross B is a relation, right? So, how many subsets does A cross B have? Remember Chapter one: a set with k elements has two raised to the power k subsets. Yes, exactly! For each of the m times n pairs: take it or leave it. Two choices, m times n times. The number of relations from A to B is two raised to the power m n. Write this down. Okay? Now, relations on A are from A to A itself. So the pairs come from A cross A, and there are m squared of them. So there are two raised to the power m squared relations on A, clear? Careful: the power is m squared, not m n. And these counts include the empty relation, with no pairs at all, shown by the circle with a slash, and the full relation, A cross B itself. Both are subsets, so both are relations. Absolutely.
5:11Example 1: domain, range, codomain when b = a squared
Alright, Example one. Let A be the set one, two, three, four, and B the set one, four, nine, sixteen, twenty five. R is the set of pairs a comma b, with a from A, b from B, and b equal to a squared. Write R in roster form, and find its domain, range and codomain. Pause the video, and try it first. Done? Okay, let's check. Square every element of A: one squared is one, two squared is four, three squared is nine, four squared is sixteen, and all of these are in set B, right? So R is: one comma one, two comma four, three comma nine, four comma sixteen. Domain: all the first elements. One, two, three, four. The whole of set A, okay? Range: all the second elements. One, four, nine, sixteen. Now, what about the codomain? Same as the range, right? No, no, careful! This is the trap we talked about. The codomain is the whole set B, so it also has twenty five. Twenty five is in the codomain, but not in the range, because no element of A squares to twenty five. Nothing is related to it. Got it?
6:24Example 2: how many relations from A to B and on A
Now Example two, and this one finishes our puzzle. If A has three elements and B has two, find: one, the number of relations from A to B; two, the number of non-empty relations from A to B; and three, the number of relations on A, okay? Pause the video and try it. Done? Okay, let's check. First, A cross B has three times two, that is six pairs. Each pair: take it or leave it. So, two raised to the power six. Sixty four! See, six was the number of pairs, not relations. Puzzle solved! Part two: non-empty. Out of these sixty four, which one has no pairs at all? Yes, the empty relation! So remove just that one. Sixty four minus one: sixty three. Part three: relations on A, okay? So, two raised to the power six again, sixty four, right? No, no! This is the JEE trap. On A means from A to A, so the pairs come from A cross A, not A cross B. Now, A cross A has three times three, that is nine pairs. So, two raised to the power three squared, which is two raised to the power nine. Five hundred and twelve!
7:42Quick revision: domain, range and 2 to the power mn
So, quick revision. One: a relation from A to B is any subset of A cross B, nothing more. Two: domain means first elements, range means second elements, and codomain is the whole of B, whether used or not. Three: there are two raised to the power m n relations from A to B, and two raised to the power m squared relations on A, okay? Now go and try the practice problems on this page. You will find them easy, I promise. All the best!
More videos in Unit 1 · Sets, Relations & Functions
- What is a Set?
- Representation of Sets
- Types of Sets
- Subsets, Intervals and Power Set
- Universal Set and Venn Diagrams
- Operations on Sets
- Laws of the Algebra of Sets
- Counting: Number of Elements in Unions
- Ordered Pairs and Cartesian Product
- Chapter Summary: Mixed Solved Problems on Sets
- Inverse of a Relation
- Types of Relations
- Equivalence Relations
- Equivalence Classes and Partitions
- Composition of Relations and Partial Orders
- Chapter Summary: Mixed Solved Problems on Relations
- What is a Function?
- Domain of Real Functions
- Finding the Range
- Standard Real Functions and Their Graphs
- Algebra of Real Functions
- One-one and Many-one Functions
- Onto and Into Functions; Bijections
- Counting Special Functions
- Composition of Functions
- Inverse of a Function
- Even and Odd Functions
- Simple Functional Equations
- Overview
- Part A: Sets
- Part B: Relations
- Part C: Functions
- Part D: Assertion–Reason and Concept Checks