150 likes | 252 Vues
CSE 2353 – September 25 th 2002. Relations. Set Partitions. Math Review. Hamming Distance Error Correction. Relations. A R B is a subset of A X B a A is related to b B iff (a,b) R Example: A = B = {1,2,3,4,5,6}; R = {(a,b): a divides b}. Display of Relations. X-Y Plot
E N D
CSE 2353 – September 25th 2002 Relations
Relations • A R B is a subset of A X B • a A is related to b B iff (a,b) R • Example: • A = B = {1,2,3,4,5,6}; • R = {(a,b): a divides b}
Display of Relations • X-Y Plot • Two Lines • Dia-graph • “Adjacency” Matrix
Types of Relations • Identity • Universal • Inverse • n-Ary
Properties of Relations • Reflexive (a R a) • Symmetric • Anti-Symmetric • Transitive
Graphic Representation • Properties of the relation:
Set Terms • R S • R S • R and S are Reflexive • R and S are Symmetric • R and S are anti-symmetric • R and S are Transitive
Equivalence Relation • What Properties? • reflexive? • anti-symmetric? • symmetric? • transitive?
Equivalence Classes • Congruence modulo n • a-b = kn
Partial Ordering • a R b iff a <= b • a R b iff a < b
Properties • Reflexive iff aRa for all aA • Symmetric iff aRb -> bRa for all a,bA • Anti-symmetric iff aRb and bRa -> a=b for all a,bA • Transitive iff aRb and bRc -> aRc • Example: R is a relation on the real numbers: xRy iff x y