The Wayback Machine - https://web.archive.org/web/20240910100104/https://www.geeksforgeeks.org/cartesian-product-of-sets/
Open In App

Cartesian Product of Sets

Last Updated : 16 May, 2024
Comments
Improve
Suggest changes
Like Article
Like
Save
Share
Report
News Follow

‘Product‘ mathematically signifies the result obtained when two or more values are multiplied together. For example, 45 is the product of 9 and 5. One must be familiar with the basic operations on sets like Union and Intersection, which are performed on 2 or more sets. Cartesian Product is also one such operation that is performed on two sets, which returns a set of ordered pairs.

In this article, we have covered, ordered pair definition, cartesian product of sets, and others in detail.

What is an Ordered Pair?

An ordere­d pair has two parts. The first part is called the first compone­nt. The second part is called the­ second component. We write­ an ordered pair like this: (a, b). The­ letter ‘a’ is the first compone­nt. The letter ‘b’ is the­ second component. An ordere­d pair has two things. One thing comes first. The othe­r thing comes second.

Example:

(5, 7) is an ordered pair of integers.

Note: (5, 7) ≠ (7, 5), an ordered pair (a, b) is equal to (x, y) only if a = x and b = y.

Cartesian Product of Sets

When two se­ts have items in them, A and B, the­ir Cartesian product is all the pairs you can make. One­ part of the pair comes from set A. The­ other part comes from set B. We­ make every possible­ pair this way. The result is a new se­t of all these pairs. We write­ this new set as A×B.

A × B = {(a, b) : a ∈ A and b ∈ B}

Example: 

Let A = {1, 2} and B = {4, 5, 6}

A × B = {(1, 4), (1, 5), (1, 6), (2, 4), (2, 5), (2, 6)}

Here the first component of every ordered pair is from set A the second component is from set B.

Cartesian Product of two sets can be easily represented in the form of a matrix where both sets are on either axis, as shown in the image below. Cartesian Product of  A = {1,  2} and B = {x, y, z}

Cartesian Product of two sets

Properties of Cartesian Product

Various properties of cartesian product includes,

1. Cartesian Product is non-commutative: A × B ≠ B × A

Example: 

A = {1, 2} , B = {a, b}

A × B = {(1, a), (1, b), (2, a), (2, b)}

B × A = {(a, 1), (b, 1), (b, 1), (b, 2)}

Therefore as A ≠ B we have A × B ≠ B × A

2. A × B = B × A, only if A = B

Proof:

Let A × B = B × A then we have  

A ⊆  B  and B ⊆  A, it follows that A = B

3. Cardinality of Cartesian Product is defined as number of elements in A × B and is equal to the product of cardinality of both sets i.e.,

|A × B| = |A| × |B|

Proof:

Let a ∈ A then the number of ordered pair (a, b) such that b ∈ B is |B|

Therefore we have |B| choices for b for each a where a ∈ A therefore the number of element in A × B is |A| × |B|

4. A × B = ∅, if either A = ∅ or B = ∅

Proof: 

Suppose A×B=∅. This means there are no ordered pairs (a,b) where a∈A and b∈B.

If A is non-empty, then there exists at least one element a∈A. For any such a, there should be an ordered pair (a,b) for some b∈B, as B is not empty. But since we have assumed A×B=∅, this is a contradiction. Hence, A must be empty.

Similarly, if B is non-empty, then there exists at least one element b∈B. For any such b, there should be an ordered pair (a,b) for some a∈A, as A is not empty. But since we have assumed A×B=∅, this is a contradiction. Hence, B must be empty.

Therefore, if ðī × ðĩ = ∅, either A or B must be empty

Hence, the statement ðī × ðĩ = ∅ if and only if either A=∅ or ðĩ = ∅ is proven.

Read More,

Problems on Cartesian Product of Sets

Problem 1: Find the value of x and y given (2x – y,  25) = (15,  2x + y)?

Solution:  

As we know from the property of ordered pairs, 2x – y = 15 and 25 = 2x + y.

Solving the linear equations we have x = 10 and y = 5.

Problem 2. Given A = {2, 3, 4 , 5} and B = {4 , 16 , 23}, a ∈ A, b ∈ B, find the set of ordered pairs such that a2 < b?

Solution:

As 22 < 16 and 23, 32 < 16 and 23, 42 < 23  

We have the set of ordered pairs such that a2 < b is {(2, 16), (2, 23), (3, 16), (2, 23), (4, 23)}

Problem 3. If A = {9, 10} and B = {3, 4, 6}, find A × B and |A × B|? 

Solution:

A × B = {(9, 3), (9, 4), (9, 6), (10, 3), (10, 4), (10, 6)}

|A × B| = |A| * |B| = 2 * 3 = 6

Problem 4. If A × B = {(a, x), (a, y ), (b, x ), (b, y)}, find A and B?

Solution:

We know A is the set of all first components in ordered pairs of A × B and 

B is the set of the second component in the ordered pair of A × B.

Therefore A = {a, b} and B = {x, y}

Problem 5. Given A × B has 15 ordered pairs and A has 5 elements, find the number of elements in B?

Solution:

We know |A × B| = |A| * |B|, 15 = 5 * |B|

Therefore B has 15 / 5 = 3 elements.

Practice Problems on Cartesian Product of Sets

Problem 1: Let A = {a, b, c} and B = {1, 2}. Find A × B.

Problem 2: Let A = {} and B = {x, y}. Find A × B.

Problem 3: Let A = {apple, banana} and B = {red, yellow}. Find A × B.

Problem 4: Let A = {1, 2, 3} and B = {3, 4, 5}. Find A × B.

Problem 5: Let A = {cat} and B = {dog}. Find A × B.

FAQs on Cartesian Product of Sets

What is cartesian product of two sets i.e., A×B?

Cartesian product of sets A and B, denoted A×B, is the set of all possible ordered pairs where the first element is from A and the second from B.

Define ordered pair.

An ordered pair is a pair of elements (a, b) in which the order of the elements is significant. This means (a, b) is distinct from (b, a) if a is not equal to b.

What is cartesian product of 3 sets?

Cartesian product of three sets A, B, and C is the set of all possible ordered triples where first element is from A, second from B, and third from C.

Write formula for cartesian product of sets.

Cartesian product of two sets A and B is defined as:

A × B = {(a, b) | a ∈ A and b ∈ B}

For three sets A, B, and C:

A × B × C = {(a, b, c) | a ∈ A, b ∈ B, and c ∈ C}

What is cartesian product of a set and a null set?

Cartesian product of a set A and a null set (∅) is always an empty set (∅), as there are no elements in the null set to form pairs with elements from set A.



Previous Article
Next Article

Similar Reads

Real Life Applications of Cartesian Product
Cartesian product is a fundamental concept in mathematics, involving the pairing of elements from two sets to form ordered pairs. This concept has numerous real-life applications across various fields, making it an essential tool for solving practical problems. In the field of computer graphics, Cartesian products are used to represent pixels in di
6 min read
Class 11 RD Sharma Solutions- Chapter 22 Brief Review of Cartesian System of Rectangular Coordinates- Exercise 22.1
Question 1. If the line segment joining the points P(x1,y1) and Q(x2,y2) subtends an angle ∅ at the origin O, prove that OP.OQ cos∅ = x1x2 + y1y2. Solution: Since, O is the origin, we can get, OP2 = x12 + y12 and OQ2 = x22 + y22 Also, by the distance formula we know distance between two points P and Q is: PQ2 = (x2 - x1)2 + (y2 - y1)2 Using the cos
6 min read
Class 11 RD Sharma Solutions - Chapter 22 Brief Review of Cartesian System of Rectangular Coordinates- Exercise 22.3
Question 1. What does the equation (x – a)2 + (y – b)2 = r2 become when the axes are transferred to parallel axes through the point (a–c, b)? Solution: We are given, (x – a)2 + (y – b)2 = r2 Putting x = X + a – c and y = Y + b, we get, =&gt; ((X + a – c) – a)2 + ((Y + b ) – b)2 = r2 =&gt; (X – c)2 + Y2 = r2 =&gt; X2 + c2 – 2cX + Y2 = r2 =&gt; X2 +
11 min read
Class 11 RD Sharma Solutions - Chapter 22 Brief Review of Cartesian System of Rectangular Coordinates- Exercise 22.2
Question 1. Find the locus of a point equidistant from the point (2, 4) and the y-axis. Solution: Let C (a, b) be any point on the locus and let A (2, 4) and B (0, b). We are given, =&gt; CA = CB =&gt; CA2 = CB2 Using distance formula, we get, =&gt; (a − 2)2 + (b − 4)2 = (a − 0)2 + (b − b)2 =&gt; a2 + 4 − 4a + b2 + 16 − 8b = a2 =&gt; b2 − 4a − 8b +
10 min read
Cartesian Plane
Cartesian plane is defined as the two-dimensional plane used in the Cartesian coordinate system. This plane is formed by intersecting two perpendicular lines called the x-axis and the y-axis and their intersection is called the origin. This method of distributing the 2-Dimensional space into four areas was first introduced by Rene Descartes in the
9 min read
Cartesian Coordinate System
Cartesian Coordinate System in Maths is a division of coordinate geometry where the location of a point in a plane or space is marked by a pair of numbers or three numbers. The branch of geometry that deals with the Cartesian Coordinate System is called Coordinate Geometry. The numbers which are used to identify the location of a point in a plane o
15+ min read
Cartesian Plane Practice Worksheet
Coordinate Geometry is a fundamental part of Mathematics that is used to solve problems related to the plotting of various curves on the graphs. In this article, we will make use of algebra to solve geometrical problems. A Cartesian Plane is a system in which real numbers are represented by points. A Cartesian plane is usually n-dimensional. But we
6 min read
Plotting Points on the Cartesian Plane Practice Questions
Plotting points on the Cartesian plane is a fundamental skill in mathematics particularly in coordinate geometry. This concept involves representing points using the ordered pairs (x, y) where x is the horizontal coordinate and y is the vertical coordinate. Understanding how to plot points is crucial for visualizing relationships between the variab
4 min read
Class 11 RD Sharma Solutions - Chapter 1 Sets - Exercise 1.6 | Set 1
Question 1. Find the smallest set A such that A ∊ {1, 2} = {1, 2, 3, 5, 9}. Solution: A ∊ {1, 2} = {1, 2, 3, 5, 9} The union indicates that the summation of elements of both sets should form RHS. Elements of A and {1, 2} together give us the resultant set. Therefore, the smallest set will be, A = {1, 2, 3, 5, 9} - {1, 2} Hence, A = {3, 5, 9} Questi
11 min read
Class 11 RD Sharma Solutions - Chapter 1 Sets - Exercise 1.7
Question 1: For any two sets A and B, prove that: A‘ – B‘ = B – A Solution: To prove: A’ – B’ = B – A Firstly show that A’ – B’ ⊆ B – A Let, x ∈ A’ – B’ ⇒ x ∈ A’ and x ∉ B’ ⇒ x ∉ A and x ∈ B (since, A âˆĐ A’ = ϕ) ⇒ x ∈ B – A It is true for all x ∈ A’ – B’ Therefore, A’ – B’ = B – A Hence, Proved. Question 2: For any two sets A and B, prove the follow
6 min read
Class 11 NCERT Solutions - Chapter 1 Sets - Exercise 1.4
Question 1. Find the union of each of the following pairs of sets:(i) X = {1, 3, 5} Y = {1, 2, 3}(ii) A = {a, e, i, o, u} B = {a, b, c}(iii) A = {x: x is a natural number and multiple of 3}B = {x: x is a natural number less than 6}(iv) A = {x: x is a natural number and 1 &lt; x â‰Ī 6}B = {x: x is a natural number and 6 &lt; x &lt; 10}(v) A = {1, 2, 3
10 min read
Class 11 RD Sharma Solutions - Chapter 1 Sets - Exercise 1.2
Question 1. Describe the following sets in Roster form: (i) {x : x is a letter before e in the English alphabet} (ii) {x ∈ N: x2 &lt; 25} (iii) {x ∈ N: x is a prime number, 10 &lt; x &lt; 20} (iv) {x ∈ N: x = 2n, n ∈ N} (v) {x ∈ R: x &gt; x} (vi) {x : x is a prime number which is a divisor of 60} (vii) {x : x is a two-digit number such that the sum
9 min read
Class 11 NCERT Solutions- Chapter 1 Sets - Miscellaneous Exercise on Chapter 1 | Set 2
Chapter 1 Sets - Miscellaneous Exercise on Chapter 1 | Set 1Question 11: Let A and B be sets. If A âˆĐ X = B âˆĐ X = φ and A ∊ X = B ∊ X for some set X, show that A = B Solution: A = A âˆĐ (A ∊ X) //absorption law A = A âˆĐ (B ∊ X) //given that A âˆĐ X = B âˆĐ X = (A âˆĐ B) ∊ (A âˆĐ X) //distributive law = (A âˆĐ B) ∊ φ //given that A âˆĐ X = φ A = (A âˆĐ B) ...(1) Repe
6 min read
Class 11 RD Sharma Solutions - Chapter 1 Sets - Exercise 1.6 | Set 2
Question 8. Find sets A, B and C, such that A âˆĐ B and B âˆĐ C and A âˆĐ C are non-empty sets, and A âˆĐ B âˆĐ C = ϕ Solution: Let us consider the sets, A = {5, 6, 10} B = {6, 8, 9} C = {9, 10, 11} Now, we have, A âˆĐ B = 6 ≠ ϕ B âˆĐ C = 9 ≠ ϕ A âˆĐ C = 10 ≠ ϕ And, A âˆĐ B âˆĐ C = ϕ Now, we have A âˆĐ B and B âˆĐ C and A âˆĐ C as non-empty sets, but A âˆĐ B âˆĐ C is empty set.
5 min read
Python Tokens and Character Sets
Python is a general-purpose, high-level programming language. It was designed with an emphasis on code readability, and its syntax allows programmers to express their concepts in fewer lines of code, and these codes are known as scripts. These scripts contain character sets, tokens, and identifiers. In this article, we will learn about these charac
6 min read
Difference of Sets
Difference of Sets is the operation defined on sets, just like we can perform arithmetic operations on numbers in mathematics. Other than difference we can also perform union and intersection of sets for any given sets. These operations have a lot of important applications in mathematical practice. In this article, we will learn about the differenc
10 min read
CBSE Class 10 Social Science Answer Key 2024 (All Sets)
CBSE Class 10 Social Science Answer Key 2024: The CBSE Class 10th Social Science Exam was conducted on March 7, 2024. The exam paper has been reviewed to be well-balanced and also was moderately easy. Now, students have been eagerly awaiting the answers or solutions to the CBSE Class 10 Social Science exam, as they seek the review as well as assess
15+ min read
CBSE Class 10 Science Answer Key 2024 (All Sets)
CBSE Class 10 Science Answer Key 2024:The exam paper has been reviewed to be well-balanced and also was moderately easy. Now, students have been eagerly awaiting the answers or solutions to the CBSE Class 10 Science exam, as they seek the review as well as assessment of their performance. In this article, we will discuss the answer key for today's
15+ min read
Real Life Applications of Data Sets
In today's data-driven world, datasets are invaluable assets with applications across numerous sectors. From healthcare to finance, transportation to education, datasets enable informed decision-making, drive innovation, and address complex challenges. In this article, we explore how datasets empower organizations and individuals to extract insight
5 min read
Finite Sets
Finite set is a collection of finite, well-defined elements. For better understanding, imagine you have a bunch of your favourite toys or snacks. You know exactly how many you have, that's the idea of a finite set in math. A finite set is a way to discuss collections of things you can count. In this article, we will discuss the concept of finite se
10 min read
Equal Sets: Definition, Cardinality, and Venn Diagram
Equal Set is the relation between two sets that tells us about the equality of two sets i.e., all the elements of both sets are the same and both sets have the same number of elements as well. As we know, a set is a well-defined collection of objects where no two objects can be the same, and sets can be empty, singleton, finite, or infinite based o
9 min read
Worksheet on Equal and Equivalent Sets
Equal and Equivalent sets are two types of sets based on the elements present in them. This article provides worksheet on equal and equivalent set to practice question that need to be solved before appearing in exams. This article also has important concept and solved examples that students should go through to get an idea how to solve worksheet on
7 min read
Types Of Sets
Sets are a well-defined collection of objects. Objects that a set contains are called the elements of the set. We can also consider sets as collections of elements that have a common feature. For example, the collection of even numbers is called the set of even numbers. Table of Content What is Set?Types of Sets in MathematicsSingleton SetEmpty Set
8 min read
Union of Sets
Union of Sets: The representation of similar types of data is called the set. Union of a set is the basic operation on the sets which is used to find all the entries of the given sets. It is one of the operators on the set used to solve the set theory problems. Union of two sets means finding a set containing all the values in both sets. It is deno
14 min read
Universal Sets
Universal Set is a set that has all the elements associated with a given set, without any repetition. Suppose we have two sets P = {1, 3, 5} and Q = {2, 4, 6} then the universal set of P and Q is U = {1, 2, 3, 4, 5, 6}. We generally use U to denote universal sets. Universal Set is a type of set that is used to represent all the possible elements as
6 min read
Practice Questions on Operations on Sets
When studying set theory, having a good understanding of the various operations on sets is crucial and an effective way to deepen this understanding is by working through practice questions on operations on sets. These Practice Questions on Operations on Sets will help to reinforce the fundamental concepts of the Set theory. In set theory, there ar
5 min read
Intersection of Sets
Intersection of Sets is the operation in set theory and is applied between two or more sets. It result in the output as all the elements which are common in all the sets under consideration. For example, The  intersection of sets A and B is the set of all elements which are common to both A and B. In other words, it is an operation that selects the
12 min read
Mathematics | Independent Sets, Covering and Matching
Mathematics | Independent Sets, Covering and Matching1. Independent SetsA set of vertices I is called an independent set if no two vertices in set I are adjacent to each other in other words the set of non-adjacent vertices is called an independent set.It is also called a stable set.The parameter Îą0(G) = max { |I|: I is an independent set in G } is
5 min read
Practice Problems on Finite and Infinite Sets
Finite and infinite sets are two different parts of "Set theory" in mathematics. When a set has a finite number of elements, it is called a "Finite set" and when a set has an infinite number of elements, it is called an "Infinite set". A finite set is countable, whereas an infinite set is uncountable. The elements in a finite set are natural number
7 min read
Disjoint Sets
Disjoint Sets are one of the types of many pair of sets, which are used in Set Theory, other than this other types are equivalent sets, equal sets, etc. Set Theory is the branch of mathematics that deals with the collection of objects and generalized various properties for these collections of objects. In this article, we will learn about Disjoint
9 min read