******************************************************************** *These notes contain NDSU confidential and proprietary material. * *Patents are pending.

Slides:



Advertisements
Similar presentations
Partial Orderings Section 8.6.
Advertisements

CSCI 115 Chapter 6 Order Relations and Structures.
Relations Relations on a Set. Properties of Relations.
Divide and Conquer. Subject Series-Parallel Digraphs Planarity testing.
Equivalence, Order, and Inductive Proof
1 Chapter 22: Elementary Graph Algorithms IV. 2 About this lecture Review of Strongly Connected Components (SCC) in a directed graph Finding all SCC (i.e.,
Chapter 7 Relations : the second time around
1 Relations: The Second Time Around Chapter 7 Equivalence Classes.
Relations binary relations xRy on sets x  X y  Y R  X  Y Example: “less than” relation from A={0,1,2} to B={1,2,3} use traditional notation 0 < 1,
Theory and Applications
Costas Busch - RPI1 Mathematical Preliminaries. Costas Busch - RPI2 Mathematical Preliminaries Sets Functions Relations Graphs Proof Techniques.
Courtesy Costas Busch - RPI1 Mathematical Preliminaries.
Discrete Mathematics Lecture#11.
Partially Ordered Sets Basic Concepts
Section 7.6: Partial Orderings Def: A relation R on a set S is called a partial ordering (or partial order) if it is reflexive, antisymmetric, and transitive.
1 Partial Orderings Based on Slides by Chuck Allison from Rosen, Chapter 8.6 Modified by.
Partially Ordered Sets (POSets)
Chapter 9 1. Chapter Summary Relations and Their Properties n-ary Relations and Their Applications (not currently included in overheads) Representing.
1 Partial Orderings Aaron Bloomfield CS 202 Rosen, section 7.6.
GRAPHS CSE, POSTECH. Chapter 16 covers the following topics Graph terminology: vertex, edge, adjacent, incident, degree, cycle, path, connected component,
Chapter 4 Relations and Digraphs
Mathematical Preliminaries Strings and Languages Preliminaries 1.
Chapter 9. Chapter Summary Relations and Their Properties n-ary Relations and Their Applications (not currently included in overheads) Representing Relations.
Discrete Math for CS Binary Relation: A binary relation between sets A and B is a subset of the Cartesian Product A x B. If A = B we say that the relation.
2.6 Equivalence Relation §1.Equivalence relation §Definition 2.18: A relation R on a set A is called an equivalence relation if it is reflexive, symmetric,
Mathematical Preliminaries. Sets Functions Relations Graphs Proof Techniques.
8.3 Representing Relations Directed Graphs –Vertex –Arc (directed edge) –Initial vertex –Terminal vertex.
GRAPHS THEROY. 2 –Graphs Graph basics and definitions Vertices/nodes, edges, adjacency, incidence Degree, in-degree, out-degree Subgraphs, unions, isomorphism.
Discrete Mathematics and Its Applications Sixth Edition By Kenneth Rosen Chapter 8 Relations 歐亞書局.
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Relations.
Relations and their Properties
COSC 2007 Data Structures II Chapter 14 Graphs I.
Mathematical Preliminaries
Sets and Subsets Set A set is a collection of well-defined objects (elements/members). The elements of the set are said to belong to (or be contained in)
1 Partial Orderings Aaron Bloomfield CS 202 Epp, section ???
Equivalence Relations. Partial Ordering Relations 1.
Problem Statement How do we represent relationship between two related elements ?
Chapter 9. Chapter Summary Relations and Their Properties n-ary Relations and Their Applications (not currently included in overheads) Representing Relations.
Unit II Discrete Structures Relations and Functions SE (Comp.Engg.)
1 Section 4.3 Order Relations A binary relation is an partial order if it transitive and antisymmetric. If R is a partial order over the set S, we also.
GRAPHS. Graph Graph terminology: vertex, edge, adjacent, incident, degree, cycle, path, connected component, spanning tree Types of graphs: undirected,
Chapter 8: Relations. 8.1 Relations and Their Properties Binary relations: Let A and B be any two sets. A binary relation R from A to B, written R : A.
1 Mathematical Preliminaries. 2 Sets Functions Relations Graphs Proof Techniques.
Copyright © Cengage Learning. All rights reserved. CHAPTER 8 RELATIONS.
Chap. 7 Relations: The Second Time Around
1 Partial Orderings Based on Slides by Chuck Allison from Rosen, Chapter 8.6 Modified by.
1 GRAPH Learning Outcomes Students should be able to: Explain basic terminology of a graph Identify Euler and Hamiltonian cycle Represent graphs using.
English for Economic Informatics I Tomáš Foltýnek Theoretical Foundations of Informatics.
Relations and Graphs Relations and Graphs Sanjay Jain, Lecturer, School of Computing.
1 Partial Orderings Epp, section Introduction An equivalence relation is a relation that is reflexive, symmetric, and transitive A partial ordering.
Framework Unifying Association Rule Mining, Clustering and Classification Anne Denton and William Perrizo Dept of Computer Science North Dakota State University.
Relations and Their Properties
Chapter 5 Relations and Operations
CSE 2813 Discrete Structures
Unit-III Algebraic Structures
Partial Orderings CSE 2813 Discrete Structures.
Introduction to Relations
Relations Binary relations represent relationships between the elements of two sets. A binary relation R from set A to set B is defined by: R  A 
Learn about relations and their basic properties
Equivalence Relations
Partial Orderings.
Relations and Digraphs
Aaron Bloomfield CS 202 Epp, section ???
CS201: Data Structures and Discrete Mathematics I
Graph Algorithms Using Depth First Search
Relations and Digraphs
Sungho Kang Yonsei University
Relations.
교환 학생 프로그램 내년 1월 중순부터 6월 초 현재 학부 2,3 학년?
Relations: The Second Time Around
Presentation transcript:

******************************************************************** *These notes contain NDSU confidential and proprietary material. * *Patents are pending on the concepts and applications of bSQ * *organization and P-tree technology, etc. * ******************************************************************** RELATION on {N 1,..N n } is a subset of  i=1..n N i FUNCTION,f:D  R is a relation on {D,R}  : {d,r 1 },{d,r 2 }  f  r 1 =r 2. Thus we can safely use the notation, r=f(d). Relation, R, on (N,N) (or just a relation on N) is: reflexive if (n,n)  R  n  N symmetric if (n 1,n 2 )  R  (n 2,n 1 )  R transitive if (n 1,n 2 ),(n 2,n 1 )  R  (n 1,n 3 )  R irreflexive if  n  N (n,n)  R anti-symmetric if (n 1,n 2 ),(n 2,n 1 )  R  n 1 =n 2 Order relation on N is a relation on N which is: irreflexive, anti-symmetric and transitive R e.g.  or  in the real numbers, R note that  is just 

Equivalence Relation (ER), , on N is a relation on N which is: reflexive symmetric transitive An Equiv Relation induces a canonical partition into equivalence classes. Partition {N 1,…,N n }, of a set N, is a collection of subset of N (  2 N) of mutually exclusive ( N 1  N 2 =   N 1  N 2  {N 1,…,N n } ) and collectively exhaustive (  {N 1,…,N n }=N ) ( together, the conditions are  !{N 1,…,N n }=N ). A partition induces a canonical equivalence relation: x  y iff x and y are in the same partition component. A function y=f(x) induces a canonical equivalence relation,  f, on its domain D f, (and  a partition on D f ) by x 1  f x 2 iff f(x 1 )=f(x 2 ) A labeled partition of N is a partition, {N 1,…,N n } together with a label function, f:{N 1,…,N n }  L (L is the label space). A function induces a canonical labeled partition on its domain. A labeled partition, f:{N 1,…,N n }  L induces a canonical function f:N  L by f(x)=y  x  f -1 (y). Undirected graph is just a relation on N (unipartite graph).

UNDIRECTED GRAPH G=(N,E): N={x 1,…,x n } (set of nodes) E  { {x 1,x 2 }| x 1,x 2  N } (set of edges; set of sets; denoted x 1 --x 2 ) SUBGRAPH, G'=(N',E') of G is a graph  : N'  N and E'  E GRAPH-PARTITION of a graph G is a set of subgraphs, {G 1,…,G n }  : {E 1,…,E n } is a set partition of E. Each G i is called a COMPONENT. PATH (length=k-1) in G is a subgraph, P=(N',E‘)  :  an ordering of N', (x 1,x 2,…,x k )  : {{x 1,x 2 },…,{x k-1,x k }}=E‘ PATH-CONNECTED GRAPH is  :  {x i,x j }  E’,  a path in G from x i to x j. PATH-CONNECTED GRAPH-PARTITION of a graph is the partition into its path-connected components. Examples: N={a,b,c,d,e,f,g} E={{a,b},{a,f},{a,g},{b,c},{b,d},{c,d},{d,g},{e,g},{e,f}} Connected Unconnected a b c def g a b c def g

DIRECTED GRAPH (digraph): G=(N,E) is a graph  :  each edge is an ordered pair. I.e., E = set of ordered pairs of nodes. Edges denoted x 1  x 2 DIRECTED SUBGRAPH G'=(N',E') is  : N'  N and E'  E. PATH in a Directed Graph, G is a subgraph, P=(N',E')  :  ordering of N', (x 1,x 2,…,x k )  : {(x 1,x 2 ),…,(x k-1,x k )}=E’ A Path, (x 1,x 2,…,x k ), is: TRIVIAL if |N|=1 and |E|=0. SIMPLE if all x i are distinct except possibly x 1 and/or n k. CYCLIC if it is simple and nontrivial with x 1 =x k (simple closed path). MINIMAL if it is cyclic and  x i, x j, (x i,x j )  E’. DIRECTED ACYCLIC GRAPH (DAG) is a digraph with no cycles. SOURCE = node with outgoing but no incoming edges. SINK = node with incoming but no outgoing edges. ROOTED DAG = dag with a unique source.

If (a,b)  E (a  b), a is called a PARENT and b is called a CHILD of b. In a path from a to b, a is an ANCESTOR of b; b is a DESCENDANT of a. b  a, a is a PROPER ANCESTOR of b and b is a PROPER DESCENDANT of a. b  a and neither is ancestor of the other then they are UNRELATED. TOPOLOGICAL SORT of digraph G is a sequence of all of the nodes of G  : if a appears before b in the sequence, then there is no path from b to a. Proposition: A digraph can be topologically sorted iff it is a dag. TRANSITIVE CLOSURE : if G=(N,E) is a digraph and G+=(N,E') is  : (a,b)  E' iff  a nontrivial path from a to b in G then G+ is the transitive closure of G. (Proposition below proves that there is just one) Proposition:  G there is 1 and only 1 transitive closure (G  G+ a fctn). The transitive closure is obtained by including in E', (x i,x j )  non- trivial path in G from x i to x j. Proposition: G+ is a dag iff G is a dag. A dag is TRANSITIVELY CLOSED or just CLOSED iff G=G+.

TREE = rooted dag with a unique path from the root to each node. PARTIAL ORDER (POSET) : (S,  ) is irreflexive: a  a transitive: if a  b and b  c then a  c Partial Order L'=(S',  ') is a RESTRICTION of L=(S,  ) on domain L‘ if S'  S and  a,b in S' a  ' b iff a  b. L' is a PREFIX of L if L' is restriction and if  a  S' all S-predecessors of a are also in S'. (Prefix is closed under "predecessorship" operation) A POSET L=(S,  ) can be viewed as a dag G=(S,E) where N=S,(a,b)  E iff a  b A dag G, can be viewed as PO L, where S=N and a  b iff a  b and (a,b)  C(E) Note: Given a POSET, L, we often diagram it as a DAG using the duality just described. However, since a diagram is intended to help visualize, and therefore should not be cluttered, we generally do not include all edges (don't display the closure - in fact usually display the minimal dag that corresponds to the POSET. QUESTION: Is it correct to say THE mininmal dag here? Is this theorem true? Given a dag, G=(S,E) there exists a unique subdag G'=(S,E') such that C(G') = C(G) and if G''=(S,E'') is a subdag of G' such that C(G'') = C(G) then G'' = G'.

Many-to-Many relationships are graphs. They are bipartite when they involve 2 different entity types (e.g., CustomerPurchaseTransaction-to-Item relationship). They are unipartite when they involve the same entity type on both sides of the relationship (e.g., protein-protein interactions). A Graph G=(N,E) is implemented in the relational (tabular) model where N = {n1,n2,...,nm} as: n1______n2______n3___________nm_____ n1|E(1,1) E(1,2) E(1,3)... E(1,m) | n2|E(2,1) E(2,2) E(2,3)... E(2,m) | n1|E(3,1) E(3,2) E(3,3)... E(3,m) |. | | nm|E(m,1) E(m,2) E(m,3)... E(m,m) | ` ‘ where E(i,j)=1 iff (ni,nj)  E. For undirected graphs, this will be triangular (symmetric), E(i,j)=E(j,i) For directed graphs, it will not.

For a bipartite graph, G=(N 1  !N 2, E), where N 1 ={x 1,…,x r } and N 2 ={x r+1,…,x m } it will be quadrangular and symmetric: n1_.._nr_nr+1..nm n1|0 0 0 | 0|. |0 0 0 | 1|. |... |..| nr|0_0___0_|_______1| nr+1| | 0 0 0|. | | 0 0 0|. | |....| nm| | 0 0 0| So it is often simplified to: nr+1..nm n1| 0|. | 1|. |...| nr| | ` ' Only change for a labeled graph, is E(i,j), will be a value from L  {null} Note the label space, L, can be a relation of feature attributes (L can be a tuple or vector of feature values, one from each feature domain)

LATTICE is a POSET in which every subset has a supremum. UPPER BOUND of a subset, X’, of a POSET is an element, z,  : x  z  x  X. SUPREMUM of a subset, X’, of a POSET is an upper bound, z’,  :  other upper bound, z of X’, z’  z. A partially ordered set, (X,  ), is LINEARLY ORDERED if  x,y  X either x  y or y  x. m  X is a MAXIMAL ELEMENT of X if  y  X  : m  y, m=y. Zorn’s Lemma: (X,  ) a non-empty POSET  :  linearly ordered subset, Y, there is an upper bound, then Y contains at least one maximal element. LATTICE ORDER, R, on S is a partial Order on S (and (S,R) is a LATTICE) if for every s 1 not equal to s 2 in S there is a s 3 in S such that (s 1,s 3 ) is in S and (s 2,s 3 ) is in S (every pair has upper bound) PARTITION LATTICE of S is lattice ordering of all Partitions of S under the ordering of sub-partitions, where a sub-partition, Q, of a partition, P, is such that every component of Q is a subset of a component of P (and of course only one). CONCEPT HIERARCHY of an attribute is Partition Lattice of that attribute (the Mother of all concept hierarchies for that attribute since any user defined concept hierarchy based on some domain knowledge, is a sub-Lattice of this Mother Lattice).

ISA graph for the concepts: 4-way DUALITY on a set S: PARTITION  FUNCTION  EQUIVALENCE RELATION  CLOSED UNDIRECTED GRAPH LABELED_EQUIVALENCE_RELATION induces the canonical LABELED_PARTITION of equivalence components (a,b belong to same component iff they're equivalent). LABELED_PARTITION, P={C 1,…,C n } induces the canonical FUNCTION, g:S  {C 1,…,C n } by g(s)=C i iff s  C i (letting C i be both the partition component and label (name) assigned to that component). FUNCTION, g:S  L induces the canonical CLOSED UNDIRECTED GRAPH on S with edge set = {(s 1,s 2 ) | g(s 1 )=g(s 2 )}. CLOSED UNIDRECTED GRAPH induces the canonical LABELED EQUIVALENCE RELATION by s 1,s 2 are equivalent iff there is a path connecting them. relation Equivalence relation function Closed Undirected graph partition Partial order relation Acyclic directed graph

E g