Presentation is loading. Please wait.

Presentation is loading. Please wait.

4.4 Properties of Relations

Similar presentations


Presentation on theme: "4.4 Properties of Relations"— Presentation transcript:

1 4.4 Properties of Relations

2 Relations Reflexive Irreflexive Symmetric Asymmetric Antisymmetric
Transitive

3 Reflexive Reflexive relation has a cycle of 1 at every vertex
A = {1,2,3} B=A R = {(1,1)(1,2),(2,2),(2,3),(3,3),(3,1)} Reflexive matrix has all 1’s on the main diagonal 1 3 2 a\b 1 2 3

4 Irreflexive Irreflexive relation has no cycles of length 1 at any vertex. A = {1,2,3} B=A R = {(1,2),(1,3),(2,3)} Irreflexive has all 0’s on its main diagonal 1 2 3 a\b 1 2 3

5 Symmetric If there is an edge from vertex i to vertex j, then there is an edge from vertex j to vertex i. A = {a,b,c} B = A R = {(a,a),(a,c),(b,c),(c,a),(c,b),(c,c)} a c b a\b a b c 1

6 R = {(a,b),(b,a),(a,c),(c,a),(b,c),(c,b)}
This is a little messy R = {(a,b),(b,a),(a,c),(c,a),(b,c),(c,b)} Another way to draw this is: This is a connected digraph This digraph is not connected. R={(a,b),(b,a),(c,d),(d,c)} a b c a c b a c b d

7 Asymmetric aRb bRa A = {1,2,3,4} B = A R ={(1,2),(3,4),(2,3)}
There is no (1,1) or (2,2) or (3,3) or (4,4) There is no (2,1), (4,3), or (3,2) IF mij = 1 then mji = 0 (i = row and j = column) There are no back arrows. All edges are 1 way streets 1 a\b 1 2 3 4 2 4 3

8 Antisymmetric Contains no back arrows. Can contain one node cycles
1 a\b 1 2 3 4 2 3 4

9 Transitive (tricky) Every time you have (a,b) and (b,c) you must also have (a,c). A = {1,2,3,4} This relation is not transitive: a,b b,c R = {(1,1),(2,2),(3,3),(4,4),(2,3),(3,4)} In order to make this relation transitive, you would a,c need (2,4). If you have R = {(1,1),(2,2),(3,3),(4,4),(2,3)} is it transitive? Yes, because it doesn’t break the rule. You have (a,b), you don’t have (b,c), therefore you do not need (a,c). Only when you have (a,b) AND (b,c), you must have (a,c).

10 A cycle is a path where you start and end with the same vertex.
iff is shorthand for if and only if.


Download ppt "4.4 Properties of Relations"

Similar presentations


Ads by Google