0 оценок0% нашли этот документ полезным (0 голосов)

39 просмотров30 страницNov 26, 2011

© Attribution Non-Commercial (BY-NC)

DOC, PDF, TXT или читайте онлайн в Scribd

Attribution Non-Commercial (BY-NC)

0 оценок0% нашли этот документ полезным (0 голосов)

39 просмотров30 страницAttribution Non-Commercial (BY-NC)

Вы находитесь на странице: 1из 30

a1 as its first element, a2 as its second element, and an as its nth element.

2-tuples are called ordered pairs. (a,b) = (c,d) if and only if a=c and b=d (a,b) (b,a) unless a=b

The Cartesian product of two sets A and B denoted by A x B is the set of ordered pairs of the form (a,b), where a is taken from A and b is taken from B. This can be written mathematically: A x B = {(a,b) | a A and b B}

Definition: The Cartesian product of the sets A1, A2, , An, denoted A1A2 An, is the set of ordered ntuples (a1, a2, , an), where ai belongs to set Ai for i =1, 2, , n. A1A2 An = {(a1, a2, , an) | aiAi for i=1, 2, , n} Let, A = {0,1,2}, B = {a,b} A B = {(0,a),(0,b),(1,a),(1,b),(2,a),(2,b). The Cartesian product of sets A and B is denoted AB and defined as follows: AB ={(x,y): xA and yB} A={1,3,5,7}, B={2,4,6} AB={(1,2),(1,4),(1,6),(3,2),(3,4),(3,6), (5,2),(5,4),(5,6),(7,2),(7,4),(7,6)} Binary Relations: Let A and B be sets. A binary relation between two sets A and B is a SUBSET of A x B. A binary relation from A to B is a set R of ordered pairs where the first element of each ordered pair comes from A and the second element comes from B. A relation, in general, is any set of ordered n-tuples chosen from n sets. If (a,b) R, then we say a is related to b by R. This is sometimes written as a R b.

Definition: Let A and B be sets. A binary relation R from A to B is a subset of the Cartesian product A

B.

x is said to be related to y under R. xRy denotes (x,y)R. Example: Examples Let A = {1, 2, 3} and B = {a, b} Relation from A to B? R = {(1, 1) (2, 2)} R={} No Yes

R = {(1, a) (1, b)} R = {(a, 1) (b, 2)} R={} R = {(1, 2) (2, 3) (3, 4)

Yes No

Relations on a set: A relation on the set A is a relation from A to A. A relation on a set is a subset of A x A.

Inverse Relations:

Given a relation RAB then R-1BA such that: R-1={(y,x):(x,y)R} R= {(x,y):x<y} defined on natural numbers. i.e. Given a relation R from A to B, the inverse of the relation R from B to A is defined as follows: R-1 = { (y, x) BxA | (x, y) R} xX and yY, (y, x) R-1 iff (x, y) R

Identity relation: IA AA. IA ={(a,a):a A} Universal relation: UA AA. UA ={(a,b):a A, b A} A={1,2,3} IA ={(1,1),(2,2),(3,3)} UA={(1,1),(2,2),(3,3),(1,2),(1,3),(2,1),(2,3),(3,1),(3,2)}.

relation on AC defined by S0R={(x,z): (x,y)R and (y,z)S for some yB}

Domain of R: Domain of a Relation(R) is the set of all the first elements of ordered

A(a; b) R}. Range of R: Range of a Relation(R) is the set of all the second elements of ordered

b) R}.

A(a;

For Example: If a Relation R=[{1,2} ,{2,3} ,{3,4}] Domain of Relation R ={1,2,3} And Range of Relation R={2,3,4}

n-ary: Let A1, A2, , An be sets. An n-ary relation on these sets (in this order) is a subset of A1A2 An. Ordered tuple :Given sets A1; :::An. An element (a1; a2; :::an) such that ai is called an ordered TUPLE. Example: If X = {1, 2, 3, 4, 5, 6}, find R = { (x,y): x is a divisor of y} R = { (1,1), (1,2), (1,3), (1,4), (1,5), (1,6), (2,2), (2,4), (2,6), (3,3), (3,6) } Arrow Diagrams of Relations: Example 1 Ai for i = 1; 2; :::n

Draw an arrow diagram from x to y xRy (x, y) R Let A = {-1, 0, 1} and B = {1, 2, 3} and xRy xy 1

R = {(1, 1) (1, 2) (1, 3)}

Example 2

Draw an arrow diagram from x to y xRy (x, y) R Let A = {1, 2, 3, 4} and B = {1, 2} and xRy x = y2

R = {(1, 1) (4, 2)}

Not a function because every element in A is not the first element of an ordered pairNote: Relations can have elements in A with no arrow coming out of it and an element in A with multiple arrows pointing to different elements in B *this is different than a function* Directed Graph of Relations: Remember: A binary relation on a set A is a binary relation from A to A The graph of this relation is called a directed graph Example

A x A = {(1, 1) (1, 2) (1, 3) (2, 1) (2, 2) (2, 3) (3, 1) (3, 2) (3, 3)}

Directed Graph of Relations (contd) Draw the directed graph of the binary relation

Let A = {2, 3, 4, 5, 6, 7, 8} (x, y)A, xTy 3 | (x-y) A x A = { (2,2) (2,3) (2,4) (2,5) (2,6) (2,7) (2,8), (3,2) (3,3) (3,4) (3,5) (3,6) (3,7) (3,8), (4,2) (4,3) (4,4) (4,5) (4,6) (4,7) (4,8), (5,2) (5,3) (5,4) (5,5) (5,6) (5,7) (5,8), (6,2) (6,3) (6,4) (6,5) (6,6) (6,7) (6,8), (7,2) (7,3) (7,4) (7,5) (7,6) (7,7) (7,8), (8,2) (8,3) (8,4) (8,5) (8,6) (8,7) (8,8) }

Matrix representation of relation: If A and B are finite sets and R is a binary relation between A and B then create a matrix, M, with the following properties: the rows of the matrix are indexed by the elements of A the columns of the matrix are indexed by elements of B

M(ai,bj) = 1 if (ai,bj) belongs to R; 0 otherwise R = {(a,b): a + 1 < b} Consider the set S = {1, 2, 3, 4, 5, 6, 7, 8}. The relation < is the set of ordered pairs R = {(1, 2), (1, 3), (1, 4), (1, 5), (1, 6), (1, 7), (1, 8), (2, 3), (2, 4), (2, 5), (2, 6), (2, 7), (2, 8), (3, 4), (3, 5), (3, 6), (3, 7), (3, 8), (4, 5), (4, 6), (4, 7), (4, 8), (5, 6), (5, 7), (5, 8), (6, 7), (6, 8), (7, 8)}.

< 1 1 2 3 4

5 6 7 8

Graph Representation of a Binary Relation (Directed graph): If A and B are two finite sets and R is a binary relation between A and B we can represent this relation as a graph (set of vertices and edges). A = {1, 3, 5 ,7}, B = {2, 4, 6, 8}. R = {(a,b): a < b}

Reflexive: A relation R on a set A is called reflexive if (a,a) R for every element a A. Irreflexive: R is irreflexive means: (x, x) oe R for all x belongs to A. Symmetric: A relation R on a set A is called symmetric if (b,a) R whenever (a,b) R, for some a,b A. Antisymmetric: A relation R on a set A such that (a,b) R and (b,a) R only if a = b for a,b A is called antisymmetric. Note that antisymmetric is not the opposite of symmetric. A relation can be both. Asymmetric: A relation R on a set A is called asymmetric if (a,b) R (b,a) R.

Transitive: A relation R on a set A, is called transitive if whenever (a,b) R and (b,c) R, then (a,c) R , for a, b, c A. Consider the following relations on {1,2,3,4}. Which are reflexive, irreflexive, neither?

Reflexive Irreflexive Irreflexive Reflexive Irreflexive

R2 = {(2,4), (4,2)} R3 = {(1,2), (2,3), (3,4)} R4 = {(1,1), (2,2), (3,3), (4,4)} R5 = {(1,3), (1,4), (2,3), (2,4), (3,1), (3,4)} R6 = {(2,2), (2,3), (2,4), (3,2), (3,3), (3,4)} Neither

Consider the following relations on {1,2,3,4}. Which are transitive?

Transitive Transitive Not Transitive Not Transitive Transitive

R2 = {(1,1), (1,2), (2,1), (2,2), (3,3), (4,4)} R3 = {(2,4), (4,2)} R4 = {(1,2), (2,3), (3,4)} R5 = {(1,1), (2,2), (3,3), (4,4)} R6 = {(1,3), (1,4), (2,3), (2,4), (3,1), (3,4)}

Not Transitive The divides relation on the set of positive integers Transitive Consider the following relations on {1,2,3,4}. Name its properties?

T/A R/S/T S A R/S/A/T

R2 = {(1,1), (1,2), (2,1), (2,2), (3,3), (4,4)} R3 = {(2,4), (4,2)} R4 = {(1,2), (2,3), (3,4)} R5 = {(1,1), (2,2), (3,3), (4,4)}

None The divides relation on the set of positive integers R/A/T Keys: R = Reflexive, S = Symmetric, A = Antisymmetric, T=Transitive

Determine the properties of each of the following relations defined on the set of all real numbers R: R = {(x,y) | x + y = 0} R = {(x,y) | x = y x = y} R = {(x,y) | x y is a rational number} R = {(x,y) | x = 2y} R = {(x,y) | x y 0} R = {(x,y) | x y = 0} R = {(x,y) | x = 1}

R = {(x,y) | x = 1 or y = 1} R = {(x,y) | x + y = 0} Solution:

It is not reflexive since, for example, (1,1) R. It is not irreflexive since, for example, (0,0) R. Since x + y = y + x, it follows that if x + y = 0 then y + x = 0, so the relation is symmetric. It is not antisymmetric since, for example, (1,1) and (1, 1) are both in R, but 1 1 The relation is not transitive since, for example, (1,1) R and (1,1) R, but (1,1) R. R = {(x,y) | x = y x = y}

Solution:

Since it is reflexive, it is not irreflexive.

Since x = y if and only if y = x, then it is symmetric. It is not antisymmetric since, for example, (1,1)

and (1,1) are both in R but 1 1 It is also transitive because essentially the product of 1 and 1 is 1. R = {(x,y) | x y is a rational number} Solution:

Since it is reflexive, it is not irreflexive.

It is symmetric because, if x y is rational, then (x y) = y x is also. It is not antisymmetric because, for example, (1, 1) and ( 1,1) are both in R but 1 1.

It is transitive because if x y is a rational and y z is a rational, so is x y + y z = x z. R = {(x,y) | x = 2y} Solution:

It is not reflexive since, for example, (1,1) R. It is not irreflexive since, for example, (0,0) R. It is not symmetric since, for example, (2,1) R

but (1,2) R.

It is antisymmetric because x = y =0 is the only time that (x,y) and (y,x) are both in R.

It is not transitive since, for example, (4,2) R and (2,1) R but (4,1) R. R = {(x,y) | x y 0} Solution:

It is reflexive since xx 0.

Since it is reflexive, it is not irreflexive.

It is symmetric as the role of x and y are interchangeable. It is not antisymmetric since, for example, (2,3) and (3,2) are both in R, but 2 3.

It is not transitive because, for example, (1,0) and (0, 2) are both in R but (1, 2) is not. R = {(x,y) | x y = 0} Solution: It is not reflexive since (1,1) R. It is not irreflexive since (0,0) R. It is symmetric as the role of x and y are interchangeable. It is not antisymmetric since, for example, (2,0) and (0,2) are both in R but 2 0. It is not transitive because, for example, (1,0) and (0, 2) are both in R but (1, 2) is not.

R = {(x,y) | x = 1} Solution: It is not reflexive since (2,2) R. It is not irreflexive since (1,1) R. It is not symmetric since, for example, (1,2) R but (2,1) R. It is antisymmetric because if (x,y) R and (y,x) R it means x = y = 1. It is transitive since if (1,y) R and (y,z) R, so is (1,z) R .

Matrices are used to represent the ordered pairs in a Cartesian product, A x B. The rows are labelled with elements of A and the columns are labeled with elements of B. Each position in the matrix is referred to by the ordered pair (row label (in A), column label (in B)). Then, we use this matrix to represent different relations on A x B. When the ordered pair (a,b) is in the relation R, we place a 1 in position (a,b) in the matrix. When (a,b) is not in R, we place a 0 in position (a,b).

R in A x B b1 b2 b3 b4 For example: a1 1 0 0 0 A = {a1,a2,a3,a4} a2 1 0 0 0 B = {b1,b2,b3,b4} a3 0 1 1 0 R = { (a1,b1), (a2, b1), a4 0 0 0 1 (a3,b2), (a3, b3), (a4, b4) }

Composite Relations

Consider the following problem: You would like to fly from an airport in NC to somewhere near or in Ireland for a vacation, and you don't care where you fly through, so long as you get between NC and Ireland. But there are no direct flights available, so you'll have to take a two-leg trip. You really don't want to have more legs than that. Determine if there is a way to fly between here and there. First, we figure out which cities have available flights leaving from airports in NC, that also have flights to London or Ireland:

0 1 1

1 0 1

0 0 1

Next, we determine the available flights from Atlanta, Washington, and New York, to cities near/in Ireland.

B: Destinations in/near Ireland London Dublin Shannon Atlanta 0 1 0 Washington 1 1 0 New York 1 0 1

Now, to find flights from NC to Ireland, we perform matrix composition (this is matrix multiplication, replacing multiplies with logical AND and replacing addition with logical OR), on the two matrices, to get a matrix of values for available trips between Greensboro, Raleigh, and Charlotte, and London, Shannon, and Dublin.

A binary relation R from the set A to itself is said to be reflexive if, for all elements a in A, (a,a) is in R. Example 1: x <= y is reflexive, because x <= x is always true. Example 2: "x and y have the same hair color" is also reflexive. A binary relation R in A x A is said to be irreflexive if, for all elements a in A, (a,a) is not in R. Example 1: x < x is irreflexive, because x < x is never true. A relation may be NEITHER reflexive nor irreflexive. Note that, when we look at the matrix representation for a relation R, if the relation is reflexive, then the entire diagonal (1,1),(2,2), (3,3),.... is all ones. If R is irreflexive, then its diagonal will be all zeroes. However, any n by n matrix of 0's and 1's can be thought of as a binary relation: then, any matrix with a diagonal containing both zeroes and ones is neither reflexive nor irreflexive.

R in A x A is symmetric if for all a, b in A, (a,b) is in R whenever (b,a) is in R. Example: x = y is symmetric. If x = y, then y = x. R in A x A is antisymmetric if for all a,b in A, if both (a,b) and (b,a) are in R, then (a,b)=(b,a) and a=b. This means we allow only ONE of (a,b) or (b,a) to be true at a time, unless a=b. Example 1: x < y is antisymmetric because if x < y, then y < x is false. Example 2: x <= y is antisymmetic. R in A x A is asymmetric if it is both antisymmetric AND irreflexive. Also, R in A x A is asymmetric if, for all a, b in A, if (a,b) is in R, then (b,a) is not in R. This is the same as the above definition, **except** that we can't have any points (x,x) in R!

Example 1: x < y is asymmetric Example 2: "x has more course hours than y" is asymmetric

When can relations be both symmetric and antisymmetric? How about both symmetric and asymmetric? Are there relations that are none of these? Why? What do the matrix representations of these relations look like?

Transitive Relations

R in A x A is transitive if, for all a, b, c, in A, IF (a,b) is in R, AND (b,c) is in R, THEN (a,c) is in R. Example 1: x < y is transitive. Example 2: "x is taller than y" is transitive. Example 3: x = 2y is NOT transitive. To determine whether a relation is transitive is much harder than determining whether a relation is reflexive, irreflexive, symmetric, etc. Remember composite relations? To do a composite of two relations S in A x B and T in B x C, we get a point (a,c) in (S o T) whenever there is a point (a,k) in S and a point (k,c) in T, where k is some (random) element in B. To say this a different way, if (a,k) is in S, and (k,c) is in T, then (a,c) is in S o T. This should look very similar to our definition of transitivity. We can use relation composition to determine if R is transitive. Compose R o R to get "R squared". This is a new relation. Whenever (a,b) is in R, and (b,c) is in R, then (a,c) is in R o R. So, all the points that should be in R, if R is transitive, are automatically found in R o R. So, we can tell if R is transitive by seeing if R o R is a subset of R (i.e. every point in R o R is also a point in R).

R in A x A is an equivalence relation if R is:

Example 1: [x = y (mod 3)] is an equivalence relation. This partitions integers into 3 kinds of sets: those with remainders of 0 when we divide by 3, those with remainders of 1, and those with remainders of 2. Under this relation, we say 0 is equivalent to 3, 6, 9, ...; 1 is equivalent to 4, 7, 10, ...; and 2 is equivalent to 5, 8, 11, ...

Example 2: "x and y are in the same discrete math class" is also an ER. R in A x A is an poset, or partially ordered set, if R is:

Example 1: x <= y is a poset. Example 2: "x divides y" is a poset on the integers.

The Cartesian product of two sets, X and Y , is the set of all ordered pairs whose first member is an element of set X, and whose second member is an element of set Y. The Cartesian product is written as XxY. Cartesian product is also known as direct product. The concept of Cartesian product was named after Ren Descartes. X Y = {(x, y) | x X and y Y}

Cartesian product of set X and Y is the set of all possible combinations of ( x , y ) where x is an element of set X and y is an element of set Y. For example, if set X has 4 elements { a , b , c , d } and set Y has 3 elements{ 1 , 2 , 3 }then Cartesian product of set X and Y (written as XxY) has 12 elements { ( a , 1 ) , ( a , 2 ) , ( a , 3 ) , ( b , 1 ) , ( b , 2 ) , ( b , 3 ) , ( c , 1 ) , ( c , 2 ) , ( c , 3 ) , ( d , 1 ) , ( d , 2 ) , ( d , 3 ) }. Another example of Cartesian product is the 2-dimensional plane R R .Here R represents set of all real numbers. In the Cartesian plane all points ( x , y ) represents any location where x and y both are real numbers. A Cartesian product of two finite sets can be considered as a table, where one set represents rows and the other represents the columns, and forms the ordered pairs. The cells of the table are accessed by choosing the element of the set from the row and the column. The Cartesian product can be used to graph mathematical properties, like in graphing equivalence and Graphing the total product.

1. Cartesian product is not commutative.

The reason behind this is that ordered pair is reversed. Although its elements remain same but their pairing gets reversed.

For example, Consider 2 sets A and B, where A = { a , b} and B = { 1 , 2 }.

AxB ={(a,1),(a,2),(b,1),(b,2)} BxA ={(1,a),(1,b),(2,a),(2,b)} Hence A x B B x A There is one exception with . Ax=xA For two equal sets P and Q, P x Q = Q x P , where P = Q For example, P = { 1 , 2 } and Q = { 1 , 2 } PxQ={(1,1),(1,2),(2,1),(2,2)} Q x P ={ ( 1 , 1 ) , ( 1 , 2 ) , ( 2 , 1 ) , ( 2 , 2 ) }

3. Cartesian product is not associative. For any three non equal sets A , B and C

( A x B ) x C A x ( B x C) For example , A = { a , b} , B = { c , d }and C ={ e , f } then ( A x B ) x C = { ( ( a , c ) ,e ) , ( ( a , d ) , e ) , ( ( a , c ) , f ) , ( ( a , d ) , f ) , ( ( b , c ) , e),((b,d),e),((b,c),f),((b,d),f)} Ax(BxC)={(a,(c,e)),(a,(d,e)),(a,(c,f)),(a,(d,f)),(b,(c,e ) ) , ( b , ( d , e ) )v , ( b , ( c , f ) ) , ( b , ( d , f ) ) } Hence ( A x B ) x C A x ( B x C) 4. Intersection holds on Cartesian product. (AB)x(CD)=(AxC)(BxD) 5. The above case in not true for union (AUB)x(CUD)(AxB)U(CxD)

6. ( A ) x ( B C ) = ( A x B ) ( A x C )

7. ( A ) x ( B U C ) = ( A x B ) U ( A x C )

n - Ary product

Generalized form of Cartesian product for n number of sets is called n-ary product.X1 , X2 Xn be n sets. Cartesian product of these n sets can be given as, X1 x X2 x .......Xn = { (x1 , x2...xn ) : xi Xi } Its a n-tuple set. All tuples are defined by nested ordered pairs.

Cartesian square

Cartesian square is also known as binary Cartesian product. For a set A the Cartesian square is A2 =A x A. For example a Cartesian plane is a Cartesian square represented by R2 that is R x R where R is set of real numbers. For example set G={ 1 , 2 } G2 ={ ( 1 , 1 , ) , ( 1 , 2 ) , ( 2 , 1 ) , ( 2 , 2 ) }

Cartesian power

It is a generalized form. Power is represented as a variable n. For a set X and power n, Xn= X x X x X ....x X (n times) = { ( x1,x2,...xn) : x1 X x2 X....xn X } For example , for a set G, G4 = G x G x G x G

1. Cartesian product of two set A x B has 6 elements If three of these are ( a , b ) , ( b , c ) and ( c , c ) , then find Cartesian product set " B x A ". Solution: First elements of ordered pairs of A x B are elements of set A. Hence a , b and c are the elements of set A, whereas second elements of ordered pairs of A x B are elements of set B. Hence, b and c are elements of set B . It is given that there are total 6 elements in the Cartesian product. We have 3 elements in set A and 2 in set B , There product is 6 ( i.e., 3 x 2 = 6 ). Hence we have got all the elements of set A and set B. A={a,b,c}

B={b,c} We have set A and set B , now we can find B x A . B x A = { ( b , a ) , ( b ,b ) , ( b , c) , ( c , a ) , ( c, b ) , ( c , c ) } 2. Cartesian product of two sets X x Y has 4 elements .If two of these are ( 1 , 2 ) and ( 2 , 3 ).Find Cartesian product of Y x X. Solution : First element of ordered pair of X x Y are elements of set X and second elements of ordered pair of set X x Y belongs to set Y. Hence 1 and 2 belongs to set X and 2 and 3 are elements of set Y. So far set X and set Y have 2 elements each. And 2 x 2 is 4. It is given that Cartesian product of set X x Y have 4 elements .It implies that we identified all the elements of set X and set Y. We have, X={1,2} Y={2,3} We have set X and set Y .hence, YxX ={(2,1),(2,2),(3,1),(3,2)} 3.Two sets are given as : A = { a , b } and B = { c , d }. Find the total numbers of subsets of A x B and hence write the power set of AXB . Solution: Let x be he total number of elements in set A. x=n(A) =2 Similarly let y be the number of elements of set B. y=n(B)=2 Now, the total number of elements in Cartesian product of A x B is xy. n( A x B) = xy = 2 x 2 = 4 AxB ={(a,c),(a,d),(b,c),(b,d)}

Power set of A x B contains 2xy elements. Hence power set of A x B contains 24 i.e., 16 elements. n( P ( A x B ) ) = 16 P ( A x B ) = {, ( a , c ) , ( a , d ) , ( b , c ) , ( b , d ) , { ( a , c ) , ( a , d ) } , { ( a , c ) , ( b , c ) } , {(a,c),(b,d)},{(a,d),(b,c)},{(a,d),(b,d)},{(b,c), (b,d)},{(a,c) , ( a , d ) , ( b , c ) } , { ( a , c ) , ( a , d ) , ( b , d) } , { ( a, c ) , ( b, c ) , ( b , d ) } , { ( a , d ) , ( b , c),(b,d)}, { ( a , c ) , ( a , d ) , ( b, c ) , ( b , d ) } }

Related Tags

Explain Cartesian Product Of Two Sets , Introduction to Cartesian Product Of Two Sets , What is Cartesian Product Of Two Sets

Cartesian Product:

The Cartesian Product of two sets A and B is the set of all Ordered Pairs (a,b) where the first element of order pairs a belongs to first set A and second element of ordered pairs b belongs or second set B. Or aA and bB Note: Cartesian product of set A and B is not equal to Cartesian product of set B and A.

Denotation of Cartesian product:

Cartesian product of sets A and B is denoted by : AB And Cartesian product of sets B and A is denoted by: BA For example: If set A={1,2} and set B={4,5} Then, AB=[ {1,4} , {1,5} , {2,4} , {2,5} ] And

BA=[ {4,1} , {4,2} , {5,1} , {5,2} ] Note: If m is the number of elements in set A and n is number of elements in set B then the numbers of elements of AB and BA is mn For example: If set A have 2 elements and Set B have 3 elements the the number of elements that AB and BA have is 32=6.

What is Relation?

Any subset of a Cartesian product AB in which the first element and second element of ordered pairs have special relation to each other is known as Relation. A relation from one set (A) to another set (B) is denoted by: xRy or simply R Where (x,y)R For example: If set A={Me , My father , My son} And set B={My spouse , My mother , My daughter} Then one of the Relation from set A to set B can be: R=[{My spouse , Me} , {My mother , My father}] In above Relation , the relation between the first and second element of ordered pairs is that first element is wife of Second element. Like My spouse Is wife of Me And If set A={2,3,4} And set B={4,5,6} Then one of the Relation from set A to set B can be : R=[{2,4} , {2,6} ,{3,6} ,{4,4}] In above Relation the relation between first and second element of ordered pairs is that First element is a factor of second element. Like 4 is a factor of 4.

Domain of a Relation(R) is the set of all the first elements of ordered pairs of the Relation(R) and Range of a Relation(R) is the set of all the second elements of ordered pairs of The Relation(R). For Example: If a Relation R=[{1,2} ,{2,3} ,{3,4}] Domain of Relation R ={1,2,3} And Range of Relation R={2,3,4} Diagrammatically we can denote the relations from one set(A) to another (B) as following:

etc.

Inverse Relations:

A relation obtained by interchanging first and second elements in the ordered pairs of given Relation is known as the inverse Relation of given Relation. If a Relation R is given then the inverse of the relation R is denoted by the symbol: R-1 For example: If Relation R=[{1,2} , {3,4} , {5,6}} Then the inverse of Relation R =R-1=[{2,1} , {4,3} , {6,5}] Relation (mathematics) redirects here. For a more general notion of relation, see Finitary relation. For a more combinatorial viewpoint, see Theory of relations. In mathematics, a binary relation on a set A is a collection of ordered pairs of elements of A. In other words, it is a subset of the Cartesian product A2 = A A. More generally, a binary relation between two sets A and B is a subset of A B. The terms dyadic relation and 2-place relation are synonyms for binary relations. An example is the "divides" relation between the set of prime numbers P and the set of integers Z, in which every prime p is associated with every integer z that is a multiple of p (and not with any integer that is not a multiple of p). In this relation, for instance, the prime 2 is associated with numbers that include 4, 0, 6, 10, but not 1 or 9; and the prime 3 is associated with numbers that include 0, 6, and 9, but not 4 or 13.

Binary relations are used in many branches of mathematics to model concepts like "is greater than", "is equal to", and "divides" in arithmetic, "is congruent to" in geometry, "is adjacent to" in graph theory, "is orthogonal to" in linear algebra and many more. The concept of function is defined as a special kind of binary relation. Binary relations are also heavily used in computer science. A binary relation is the special case n = 2 of an n-ary relation R A1 An, that is, a set of ntuples where the jth component of each n-tuple is taken from the jth domain Aj of the relation. In some systems of axiomatic set theory, relations are extended to classes, which are generalizations of sets. This extension is needed for, among other things, modeling the concepts of "is an element of" or "is a subset of" in set theory, without running into logical inconsistencies such as Russell's paradox.

Formal definition

A binary relation R is usually defined as an ordered triple (X, Y, G) where X and Y are arbitrary sets (or classes), and G is a subset of the Cartesian product X Y. The sets X and Y are called the domain (or the set of departure) and codomain (or the set of destination), respectively, of the relation, and G is called its graph. The statement (x,y) R is read "x is R-related to y", and is denoted by xRy or R(x,y). The latter notation corresponds to viewing R as the characteristic function on "X" x "Y" for the set of pairs of G. The order of the elements in each pair of G is important: if a b, then aRb and bRa can be true or false, independently of each other.

Is a relation more than its graph?

According to the definition above, two relations with the same graph may be different, if they differ in the sets X and Y. For example, if G = {(1,2),(1,3),(2,7)}, then (Z,Z, G), (R, N, G), and (N, R, G) are three distinct relations. Some mathematicians do not consider the sets X and Y to be part of the relation, and therefore define a binary relation as being a subset of XY, that is, just the graph G. According to this view, the set of pairs {(1,2),(1,3),(2,7)} is a relation from any set that contains {1,2} to any set that contains {2,3,7}. A special case of this difference in points of view applies to the notion of function. Most authors insist on distinguishing between a function's codomain and its range. Thus, a single "rule" like mapping every real number x to x2 can lead to distinct functions f:RR and g:RR+, depending on the images under that rule are understood to be reals or, more particularly, non-negative reals. But others view functions as simply sets of ordered pairs with unique first components. This difference in perspectives does raise some nontrivial issues. As an example, the former camp

considers surjectivityor being ontoas a property of functions, while the latter sees it as a relationship that functions may bear to sets. Either approach is adequate for most uses, provided that one attends to the necessary changes in language, notation, and the definitions of concepts like restrictions, composition, inverse relation, and so on. The choice between the two definitions usually matters only in very formal contexts, like category theory.

Example

Example: Suppose there are four objects {ball, car, doll, gun} and four persons {John, Mary, Ian, Venus}. Suppose that John owns the ball, Mary owns the doll, and Venus owns the car. Nobody owns the gun and Ian owns nothing. Then the binary relation "is owned by" is given as

R=({ball, car, doll, gun}, {John, Mary, Ian, Venus}, {(ball, John), (doll, Mary), (car, Venus)}).

Thus the first element of R is the set of objects, the second is the set of people, and the last element is a set of ordered pairs of the form (object, owner). The pair (ball, John), denoted by ballRJohn means that the ball is owned by John. Two different relations could have the same graph. For example: the relation

({ball, car, doll, gun}, {John, Mary, Venus}, {(ball,John), (doll, Mary), (car, Venus)})

is different from the previous one as everyone is an owner. But the graphs of the two relations are the same. Nevertheless, R is usually identified or even defined as G(R) and "an ordered pair (x, y) G(R)" is usually denoted as "(x, y) R".

Some important classes of binary relations R between X and Y are listed below. Uniqueness properties:

injective (also called left-unique[1]): for all x and z in X and y in Y it holds that if xRy and zRy then x = z. functional (also called right-unique[1] or right-definite[citation needed]): for all x in X, and y and z in Y it holds that if xRy and xRz then y = z; such a binary relation is called a partial function. one-to-one (also written 1-to-1): injective and functional.

Totality properties:

left-total[1]: for all x in X there exists a y in Y such that xRy (this property, although sometimes also referred to as total, is different from the definition of total in the next section). surjective (also called right-total[1]): for all y in Y there exists an x in X such that xRy. A correspondence: a binary relation that is both left-total and surjective.

A function: a relation that is functional and left-total. A bijection: a one-to-one correspondence; such a relation is a function and is said to be bijective.

If X = Y then we simply say that the binary relation is over X. Or it is an endorelation over X. Some classes of endorelations are widely studied in graph theory, where they're known as directed graphs. The set of all binary relations B(X) on a set X is a semigroup with involution with the involution being the mapping of a relation to its inverse relation. Some important classes of binary relations over a set X are:

reflexive: for all x in X it holds that xRx. For example, "greater than or equal to" is a reflexive relation but "greater than" is not. irreflexive (or strict): for all x in X it holds that not xRx. "Greater than" is an example of an irreflexive relation. coreflexive: for all x and y in X it holds that if xRy then x = y. "Equal to and odd" is an example of a coreflexive relation. symmetric: for all x and y in X it holds that if xRy then yRx. "Is a blood relative of" is a symmetric relation, because x is a blood relative of y if and only if y is a blood relative of x. antisymmetric: for all x and y in X it holds that if xRy and yRx then x = y. "Greater than or equal to" is an antisymmetric relation, because if xy and yx, then x=y. asymmetric: for all x and y in X it holds that if xRy then not yRx. "Greater than" is an asymmetric relation, because if x>y then not y>x. transitive: for all x, y and z in X it holds that if xRy and yRz then xRz. "Is an ancestor of" is a transitive relation, because if x is an ancestor of y and y is an ancestor of z, then x is an ancestor of z. total: for all x and y in X it holds that xRy or yRx (or both). "Is greater than or equal to" is an example of a total relation (this definition for total is different from the one in the previous section). trichotomous: for all x and y in X exactly one of xRy, yRx or x = y holds. "Is greater than" is an example of a trichotomous relation.

Euclidean: for all x, y and z in X it holds that if xRy and xRz, then yRz (and zRy). Equality is a Euclidean relation because if x=y and x=z, then y=z. serial: for all x in X, there exists y in X such that xRy. "Is greater than" is a serial relation on the integers. But it is not a serial relation on the positive integers, because there is no y in the positive integers such that 1>y.[2] However, the "Is less than" is a serial relation on the positive integers (the natural numbers), the rational numbers and the real numbers. Every reflexive relation is serial. set-like: for every x in X, the class of all y such that yRx is a set. (This makes sense only if we allow relations on proper classes.) The usual ordering < on the class of ordinal numbers is set-like, while its inverse > is not.

A relation that is reflexive, symmetric, and transitive is called an equivalence relation. A relation that is reflexive, antisymmetric, and transitive is called a partial order. A partial order that is total is called a total order, simple order, linear order, or a chain.[3] A linear order where every nonempty set has a least element is called a well-order. A relation that is symmetric, transitive, and serial is also reflexive.

If R is a binary relation over X and Y, then the following is a binary relation over Y and X:

Inverse or converse: R 1, defined as R 1 = {(y, x)|(x, y) R}. A binary relation over a set is equal to its inverse if and only if it is symmetric. See also duality (order theory).

If R is a binary relation over X, then each of the following is a binary relation over X:

Reflexive closure: R=, defined as R= = {(x, x) | x X} R or the smallest reflexive relation over X containing R. This can be seen to be equal to the intersection of all reflexive relations containing R. Reflexive reduction: R, defined as R = R \ {(x, x) | x X} or the largest irreflexive relation over X contained in R. Transitive closure: R+, defined as the smallest transitive relation over X containing R. This can be seen to be equal to the intersection of all transitive relations containing R. Transitive reduction: R, defined as a minimal relation having the same transitive closure as R. Reflexive transitive closure: R*, defined as R* = (R+)=, the smallest preorder containing R. Reflexive transitive symmetric closure: R, defined as the smallest equivalence relation over X containing R.

If R, S are binary relations over X and Y, then each of the following is a binary relation:

Union: R S X Y, defined as R S = {(x, y) | (x, y) R or (x, y) S}. Intersection: R S X Y, defined as R S = {(x, y) | (x, y) R and (x, y) S}.

If R is a binary relation over X and Y, and S is a binary relation over Y and Z, then the following is a binary relation over X and Z: (see main article composition of relations)

Composition: SR, also denoted R;S (or more ambiguously RS), defined as SR = {(x, z) | there exists y Y, such that (x, y) R and (y, z) S}. The order of R and S in the notation SR, used here agrees with the standard notational order for composition of functions.

Complement

The complement of the inverse is the inverse of the complement. If X = Y the complement has the following properties:

If a relation is symmetric, the complement is too. The complement of a reflexive relation is irreflexive and vice versa. The complement of a strict weak order is a total preorder and vice versa.

Restriction

The restriction of a binary relation on a set X to a subset S is the set of all pairs (x, y) in the relation for which x and y are in S. If a relation is reflexive, irreflexive, symmetric, antisymmetric, asymmetric, transitive, total, trichotomous, a partial order, total order, strict weak order, total preorder (weak order), or an equivalence relation, its restrictions are too. However, the transitive closure of a restriction is a subset of the restriction of the transitive closure, i.e., in general not equal. Also, the various concepts of completeness (not to be confused with being "total") do not carry over to restrictions. For example, on the set of real numbers a property of the relation "" is that every non-empty subset S of R with an upper bound in R has a least upper bound (also called supremum) in R. However, for a set of rational numbers this supremum is not necessarily rational, so the same property does not hold on the restriction of the relation "" to the set of rational numbers. The left-restriction (right-restriction, respectively) of a binary relation between X and Y to a subset S of its domain (codomain) is the set of all pairs (x, y) in the relation for which x (y) is an element of S.

Certain mathematical "relations", such as "equal to", "member of", and "subset of", cannot be understood to be binary relations as defined above, because their domains and codomains cannot be taken to be sets in the usual systems of axiomatic set theory. For example, if we try to model the general concept of "equality" as a binary relation =, we must take the domain and codomain to be the "set of all sets", which is not a set in the usual set theory. The usual work-around to this problem is to select a "large enough" set A, that contains all the objects of interest, and work with the restriction =A instead of =. Similarly, the "subset of" relation needs to be restricted to have domain and codomain P(A) (the power set of a specific set A): the resulting set relation can be denoted A. Also, the "member of" relation needs to be restricted to have domain A and codomain P(A) to obtain a binary relation A that is a set. Another solution to this problem is to use a set theory with proper classes, such as NBG or MorseKelley set theory, and allow the domain and codomain (and so the graph) to be proper classes: in such a theory, equality, membership, and subset are binary relations without special comment. (A minor modification needs to be made to the concept of the ordered triple (X, Y, G), as normally a proper class cannot be a member of an ordered tuple; or of course one can identify the function with its graph in this context.) In most mathematical contexts, references to the relations of equality, membership and subset are harmless because they can be understood implicitly to be restricted to some set in the context.

The number of distinct binary relations on an n-element set is 2n2 (sequence A002416 in OEIS):

Number of n-element binary relations of different types n 0 1 2 3 4 1 2 16 512 all transit reflexi preord partial ive ve er order 1 2 13 171 1 1 4 64 4096 1 1 4 29 355 1 1 3 19 219 total preorder 1 1 3 13 75 1 1 2 6 24 total order 1 1 2 5 15 equivalence relation

65536 3994

A000142 A000110

Notes:

The number of irreflexive relations is the same as that of reflexive relations. The number of strict partial orders (irreflexive transitive relations) is the same as that of partial orders. The number of strict weak orders is the same as that of total preorders. The total orders are the partial orders that are also total preorders. The number of preorders that are neither a partial order nor a total preorder is, therefore, the number of preorders, minus the number of partial orders, minus the number of total preorders, plus the number of total orders: 0, 0, 0, 3, and 85, respectively. the number of equivalence relations is the number of partitions, which is the Bell number.

The binary relations can be grouped into pairs (relation, complement), except that for n = 0 the relation is its own complement. The non-symmetric ones can be grouped into quadruples (relation, complement, inverse, inverse complement).

Binary relations by property reflexi symmet transiti symbol example ve ric ve directed graph undirected graph tournament dependency weak order preorder partial order partial equivalence equivalence Yes Yes Yes No Yes Yes No No Yes Yes No Yes Yes Yes Yes Yes Yes , , , equality preference subset pecking order

## Гораздо больше, чем просто документы.

Откройте для себя все, что может предложить Scribd, включая книги и аудиокниги от крупных издательств.

Отменить можно в любой момент.