CSCI 2824 Lecture 19: Properties of RelationsWe will now restrict ourselves to relations for a set . Such relations can be viewed as a graph. Graphs and RelationsRelations with domain and co-domain as the same set can be viewed as a graph. Graph
A graph consists of a set of nodes and a relation of edges. Each edge in a graph corresponds to a pair . It is a common convention to call the set of nodes (rather than ) edge relation (rather than ) if we are talking about a graph. But we will ignore this convention for now. We will look at two examples of relations and their corresponding graphs. Example # 1Consider the relation over the set of nodes . Its graph is depicted below: Note that the graph has a node without any links. This is because but there is no tuple involving in the relation that describes the edge set. Next, note that the edges corresponding to and are called self-loops. The graph of the relation in this example has two self loops, one over and the other over . Example # 2Consider the relation over the set of nodes . Its graph is depicted below: Note that the arrow from 1 to 2 corresponds to the tuple , whereas the reverse arrow from to corresponds to the tuple . Types of RelationsWe first study three types of relations: reflexive, symmetric and transitive. Reflexive Relation
A relation is reflexive iff for all . From the graph, we note that a relation is reflexive if all nodes in the graph have self-loops The relation from example #2 above is reflexive whereas the relation from example #1 is not. is missing the self loops from and . The next concept is that of a symmetric relation. Symmetric Relation
A relation is symmetric iff for all , . From its graph, a relation is symmetric if for every “forward” arrow from to , there is also a reverse arrow from to . The relation from example #2 above is symmetric whereas the relation from example #1 is not. has the edge but not the reverse edge . Finally, we will talk about transitive relations. Transitive Relation
A relation is transitive iff for all a,b,c, IF and THEN . In graph terms, if we start at some node , and using an edge go from to and then from to using another edge, we should also be able to go from to directly using an edge. The relation from example #2 above is not transitive. It is missing the edges and , that would make it transitive. The relation from example #1 is transitive, on the other hand. Putting all these together, a relation is an equivalence iff it is reflexive, symmetric and transitive. We now consider the polar opposite of a reflexive relation, an irreflexive relation: Irreflexive Relation
A relation is irreflexive iff for all . For all , we have . While a reflexive relation has all the self-loops, an irreflexive one has no self-loops. The relation in example # 1 is not irreflexive since it has self-loops d,d)$. Removing these from the relations yields us an irreflexive relation ExampleTake the set . Give us examples of relations that are
What about the empty set as a relation? Is it reflexive? Symmetric? Transitive?? ExampleConider the standard relation over .
Anti-Symmetric RelationWe looked at irreflexive relations as the polar opposite of reflexive (and not just the logical negation). Now we consider a similar concept of anti-symmetric relations. This is a special property that is not the negation of symmetric. A relation is anti-symmetric iff whenever and are both in then . Anti-symmetric is not the opposite of symmetric. A relation can be both symmetric and anti-symmetric: Another example is the empty set. It is both symmetric and anti-symmetric. The relation on is anti-symmetric. Whenever and then . In fact, the notion of anti-symmetry is useful to talk about ordering relations such as over sets and over natural numbers. Partial OrdersA relation is a partial order iff it is
The easiest way to remember a partial order is to think of the relation over sets. In fact, the partial order definition is an abstraction of the subset relation. Example-1Let us take the words in an english dictionary. The lexicographic ordering (or alphabetic ordering) is a partial order. Example-2Is the order on a partial order? What about the ordering? Example-3Is the relation on a partial order? Example-4Is the empty relation a partial order, in general? Partial orders can leave elements incomparable. We saw the example with where is incomparable in the ordering to . A strict partial order is an irreflexive, transitive and anti-symmetric relation. It is inspired by the order between sets which captures the notion of proper subsets. Total OrderA total ordering is a partial order that also satisfies the property that there are no incomparable elements. The definition of a total ordering is inspired by the relation. It is a partial order over but additionally for any either or . A strict total ordering is a strict partial order that ensures that no two different elements are incomparable. Strict total orderings are inspired by the relation on . More ExamplesLet us take an example and study various find of relations. Let us take the set of natural numbers and classify relations over them.
|