Relations Introduction to Relations 8.2 Properties of Relations. 8.3 Equivalence Relations. mjarrar 2015

Similar documents
Number Theory and Proof Methods

Set Theory Basics of Set Theory. 6.2 Properties of Sets and Element Argument. 6.3 Algebraic Proofs 6.4 Boolean Algebras.

Number Theory and Proof Methods

Set Theory Basics of Set Theory. mjarrar Watch this lecture and download the slides

14 Equivalence Relations

Propositional Logic Introduction and Basics. 2.2 Conditional Statements. 2.3 Inferencing. mjarrar 2015

Sequences & Mathematical Induction

Part V. Chapter 19. Congruence of integers

2 Equivalence Relations

CSE 20 DISCRETE MATH. Winter

1.4 Equivalence Relations and Partitions

Definition: A binary relation R from a set A to a set B is a subset R A B. Example:

CSE 20 DISCRETE MATH. Fall

MATH 215 Sets (S) Definition 1 A set is a collection of objects. The objects in a set X are called elements of X.

1 Predicates and Quantifiers

Section 0. Sets and Relations

9 RELATIONS. 9.1 Reflexive, symmetric and transitive relations. MATH Foundations of Pure Mathematics

Relations. P. Danziger. We may represent a relation by a diagram in which a line is drawn between two elements if they are related.

Discrete Mathematics with Applications MATH236

Section Summary. Relations and Functions Properties of Relations. Combining Relations

MATH 433 Applied Algebra Lecture 14: Functions. Relations.

Relations and Equivalence Relations

CSC Discrete Math I, Spring Relations

Properties of the Integers

a + b = b + a and a b = b a. (a + b) + c = a + (b + c) and (a b) c = a (b c). a (b + c) = a b + a c and (a + b) c = a c + b c.

Relations. Relations of Sets N-ary Relations Relational Databases Binary Relation Properties Equivalence Relations. Reading (Epp s textbook)

Tomáš Madaras Congruence classes

CSE 20 DISCRETE MATH. Winter

Orders and Equivalences

Automata and Languages

Notes on Sets, Relations and Functions

Foundations of Mathematics

Logic & Logic Agents Chapter 7 (& Some background)

Relations. Binary Relation. Let A and B be sets. A (binary) relation from A to B is a subset of A B. Notation. Let R A B be a relation from A to B.

Büchi Automata and their closure properties. - Ajith S and Ankit Kumar

Chapter 2 - Relations

Chapter VI. Relations. Assumptions are the termites of relationships. Henry Winkler

Relations. Relations. Definition. Let A and B be sets.

Lecture Notes 1 Basic Concepts of Mathematics MATH 352

MATH 115, SUMMER 2012 LECTURE 4 THURSDAY, JUNE 21ST

Value Constraints In ORM

MATH 13 SAMPLE FINAL EXAM SOLUTIONS

Math 109 September 1, 2016

Relations. We have seen several types of abstract, mathematical objects, including propositions, predicates, sets, and ordered pairs and tuples.

Chapter 1. Sets and Mappings

CHAPTER 1. Relations. 1. Relations and Their Properties. Discussion

Set Basics. P. Danziger

Sets. We discuss an informal (naive) set theory as needed in Computer Science. It was introduced by G. Cantor in the second half of the nineteenth

Sets and Functions. MATH 464/506, Real Analysis. J. Robert Buchanan. Summer Department of Mathematics. J. Robert Buchanan Sets and Functions

EQUIVALENCE RELATIONS (NOTES FOR STUDENTS) 1. RELATIONS

Simultaneous Linear, and Non-linear Congruences

FORMAL LANGUAGES, AUTOMATA AND COMPUTATION

Reading 11 : Relations and Functions

and e 2 ~ e 2 iff e 1

Lecture 8: Equivalence Relations

Chapter 1 : The language of mathematics.

In mathematics there are endless ways that two entities can be related

Chapter 9: Relations Relations

5. Partitions and Relations Ch.22 of PJE.

Economics 204 Summer/Fall 2017 Lecture 1 Monday July 17, 2017

Quadratic reciprocity and the Jacobi symbol Stephen McAdam Department of Mathematics University of Texas at Austin

cse303 ELEMENTS OF THE THEORY OF COMPUTATION Professor Anita Wasilewska

0 Sets and Induction. Sets

Theory of Computation 3 Deterministic Finite Automata

Name (please print) Mathematics Final Examination December 14, 2005 I. (4)

Definition List Modern Algebra, Fall 2011 Anders O.F. Hendrickson

This exam contains 5 pages (including this cover page) and 4 questions. The total number of points is 100. Grade Table

Set Theory. CSE 215, Foundations of Computer Science Stony Brook University

RED. Fall 2016 Student Submitted Sample Questions

MATH 433 Applied Algebra Lecture 22: Semigroups. Rings.

RED. Name: Instructor: Pace Nielsen Math 290 Section 1: Winter 2014 Final Exam

Advanced Automata Theory 2 Finite Automata

MATH1240 Definitions and Theorems

Chapter 3. Cartesian Products and Relations. 3.1 Cartesian Products

MATH 433 Applied Algebra Lecture 4: Modular arithmetic (continued). Linear congruences.

Module 2: Language of Mathematics

Comment: The induction is always on some parameter, and the basis case is always an integer or set of integers.

Advanced Automata Theory 9 Automatic Structures in General

Deterministic Finite Automata (DFAs)

Mathematics 220 Homework 4 - Solutions. Solution: We must prove the two statements: (1) if A = B, then A B = A B, and (2) if A B = A B, then A = B.

Formal Language and Automata Theory (CS21004)

The integers. Chapter 3

Notes on Systems of Linear Congruences

Structural Induction

DISCRETE MATHEMATICS W W L CHEN

(4.2) Equivalence Relations. 151 Math Exercises. Malek Zein AL-Abidin. King Saud University College of Science Department of Mathematics

Modular Arithmetic Instructor: Marizza Bailey Name:

Deterministic Finite Automata (DFAs)

MA441: Algebraic Structures I. Lecture 18

Definitions. Notations. Injective, Surjective and Bijective. Divides. Cartesian Product. Relations. Equivalence Relations

CS 514, Mathematics for Computer Science Mid-semester Exam, Autumn 2017 Department of Computer Science and Engineering IIT Guwahati

In N we can do addition, but in order to do subtraction we need to extend N to the integers

X-MA2C01-1: Partial Worked Solutions

REVIEW QUESTIONS. Chapter 1: Foundations: Sets, Logic, and Algorithms

XMA2C011, Annual Examination 2012: Worked Solutions

Lecturecise 22 Weak monadic second-order theory of one successor (WS1S)

Discrete Structures: Sample Questions, Exam 2, SOLUTIONS

Finite Automata and Formal Languages TMV026/DIT321 LP Testing Equivalence of Regular Languages

BOOLEAN ALGEBRA INTRODUCTION SUBSETS

We define the multi-step transition function T : S Σ S as follows. 1. For any s S, T (s,λ) = s. 2. For any s S, x Σ and a Σ,

Transcription:

9/6/17 Mustafa Jarrar: Lecture Notes in Discrete Mathematics. Birzeit University Palestine 2015 Relations 8.1. Introduction to Relations 8.2 Properties of Relations 8.3 Equivalence Relations mjarrar 2015 1 Watch this lecture and download the slides Course Page: http://www.jarrar.info/courses/dmath/ More Online Courses at: http://www.jarrar.info Acknowledgement: This lecture is based on (but not limited to) to chapter 5 in Discrete Mathematics with Applications by Susanna S. Epp (3rd Edition). 2 1

Mustafa Jarrar: Lecture Notes in Discrete Mathematics. Birzeit University Palestine 2015 Relations 8.3 Equivalence Relations In this lecture: qpart 1: Partitioned Sets qpart 2: Equivalence Relation qpart 3: Equivalence Class 3 Partitioned Sets Sets can be partitioned into disjoint sets A partition of a set A is a finite or infinite collection of nonempty mutually disjoint subsets whose union is A. A 1 A 2 A 3 A 4 A 5 A 6 (جامع ( Total A i A 2... A 6 = A تقسیم جامع مانع ) مانع) Disjoint A i A j = φ whenever i j 4 2

Relations Induced by a Partition A relation induced by a partition is a relation between two element in the same partition. A 1 A 2 A 3 A 4 A 5 A 6 (جامع ( Total A i A 2... A 6 = A تقسیم جامع مانع ) مانع) Disjoint A i A j = φ whenever i j 5 Relations Induced by a Partition Definition Sets Can be Partitioned into disjoint sets Given a partition of a set Atherelation induced by the partition Risdefinedon A as follows: For all x y A xry there is a subset A i of the partition such that both x and y are in A i. A 1 A 2 A 3 A 4 A 5 A 6 (جامع ( Total A i A 2... A 6 = A تقسیم جامع مانع ) مانع) Disjoint A i A j = φ whenever i j 6 3

Let A = {0 1 2 3 4} and consider the following partition of A: {0 3 4} {1} {2}. Find the relation R induced by this partition. Since {0 3 4} is a subset of the partition 0 R 3 because both 0 and 3arein{0 3 4} 3 R 0 because both 3 and 0arein{0 3 4} 0 R 4 because both 0 and 4arein{0 3 4} 4 R 0 because both 4 and 0arein{0 3 4} 3 R 4 because both 3 and 4arein{0 3 4} and 4 R 3 because both 4 and 3arein{0 3 4}. } Also 0 R 0 because both 0 and 0arein{0 3 4} 3 R 3 because both 3 and 3arein{0 3 4} and 4 R 4 because both 4 and 4arein{0 3 4}. 7 Let A = {0 1 2 3 4} and consider the following partition of A: {0 3 4} {1} {2}. Find the relation R induced by this partition. Since {1} is a subset of the partition 1 R 1 because both 1 and 1arein{1} { } { } and since {2} is a subset of the partition Hence 2 R 2 because both 2 and 2arein{2}. Hence R = {(00)(03)(04)(11)(22)(30) (33)(34)(40)(43)(44)}. { 8 4

Relations Induced by a Partition Theorem 8.3.1 Let A be a set with a partition and let R be the relation induced by the partition. Then R is reflexive symmetric and transitive. 9 Mustafa Jarrar: Lecture Notes in Discrete Mathematics. Birzeit University Palestine 2015 Relations 8.3 Equivalence Relations In this lecture: qpart 1: Partitioned Sets qpart 2: Equivalence Relation qpart 3: Equivalence Class 10 5

Equivalence Relation Definition Let A be a set and R a relation on A. R is an equivalence relation if and only if R is reflexive symmetric and transitive. è The relation induced by a partition is an equivalence relation 11 Let X be the set of all nonempty subsets of {1 2 3}. Then X = {{1} {2} {3} {1 2} {1 3} {2 3} {1 2 3}} Define a relation R on X as follows: For all A and B in X A R B the least element of A equals the least element of B. Prove that R is an equivalence relation on X. by definition of R: R is reflexive: A R A R is Symmetric : B R A R is transitive : A R C 12 6

Let S be the set of all digital circuits with a fixed number n of inputs. Define a relation E on S as follows: For all circuits C1 and C2 in S C 1 E C 2 C1 has the same input/output table as C2. E is reflexive: Suppose C is a digital logic circuit in S. [We must show that C E C.] Certainly C has the same input/output table as itself. Thus by definition of E C E C E is symmetric: Suppose C1 and C2 are digital logic circuits in S such that C1 E C2. By definition of E since C1 E C2 then C1 has the same input/output table as C2. It follows that C2 has the same input/output table as C1. Hence by definition of E C2 E C1 E is transitive: Suppose C1 C2 and C3 are digital logic circuits in S such that C1 E C2 andc2 E C3. By definition of E since C1 E C2 and C2 E C3 then C1 has the same input/output table as C2 and C2 has the same input/output table as C3. It follows that C1 has the same input/output table as C3. Hence by definition of E C1 E C3 13 Let L be the set of all allowable identifiers in a certain computer language and define a relation R on L as follows: For all strings s and t in L s R t the first eight characters of s equal the first eight characters of t. R is reflexive: Let s L. Clearly s has the same first eight characters as itself. Thus by definition of R s R s. R is symmetric: Let s and t be in L and suppose that s R t. By definition of R since s R t the first eight characters of s equal the first eight characters of t. But then the first eight characters of t equal the first eight characters of s. And so by definition of R t R s R is transitive: Let s t and u be in L and suppose that s R t and t R u. By definition of R since s R t and t R u the first eight characters of s equal the first eight characters of t and the first eight characters of t equal the first eight characters of u. Hence the first eight characters of s equal the first eight characters of u. Thus by definition of R s R u 14 7

Mustafa Jarrar: Lecture Notes in Discrete Mathematics. Birzeit University Palestine 2015 Relations 8.3 Equivalence Relations In this lecture: qpart 1: Partitioned Sets qpart 2: Equivalence Relation qpart 3: Equivalence Class 15 Equivalence Class Definition Suppose A is a set and R is an equivalence relation on A. Foreachelementa in A the equivalence class of a denoted [a] and called the class of a for short is the set of all elements x in A such that x is related to a by R. In symbols: [a] ={x A xra} for all x A x [a] xra. 16 8

Let A = {01234} and define a relation R on A as : R = {(0 0) (0 4) (1 1) (1 3) (2 2) (3 1) (3 3) (4 0) (4 4)}. 4 0 Find the distinct equivalence classes of R. [0] ={x A xr0} ={0 4} 3 2 1 [1] ={x A xr1} ={1 3} [2] ={x A xr2} ={2} [3] ={x A xr3} ={1 3} [4] ={x A xr4} ={0 4} =[ ] [0] = [4] and [1] = [3]. 17 Equivalence Class Lemma 8.3.2 Suppose A is a set R is an equivalence relation on Aanda and b are elements of A. If arbthen[a] =[b]. Lemma 8.3.3 If A is a set R is an equivalence relation on A anda and b are elements of Athen either [a] [b] = or [a] =[b]. Definition Suppose R is an equivalence relation on a set A and S is an equivalence class of R. A representative of the class S is any element a such that [a] =S. 18 9

Congruence Modulo 3 Let R be the relation of congruence modulo 3 on the set Z of all integers. That is for all integers m and n m R n 3 (m n) m n (mod3). Describe the distinct equivalence classes of R. For each integer a [a] ={x Z xra} ={x Z 3 (x a)} ={x Z x a = 3k for some integer k}. Therefore [a] ={x Z x = 3k + a for some integer k}. 19 Congruence Modulo 3 Let R be the relation of congruence modulo 3 on the set Z of all integers. That is for all integers m and n mrn 3 (m n) m n(mod3). Describe the distinct [ ]={ equivalence = classes + of R. } [0] ={x Z x = 3k + 0 for some integer k} ={x Z x = 3k for some integer k} ={... 9 6 3 0 3 6 9...} [1] ={x Z x = 3k + 1 for some integer k} ={... 8 5 2 1 4 7 10...} [2] ={x Z x = 3k + 2 for some integer k} ={... 7 4 1 2 5 8 11...}. 20 10

Congruence Modulo 3 Let R be the relation of congruence modulo 3 on the set Z of all integers. That is for all integers m and n mrn 3 (m n) m n(mod3). Describe the distinct equivalence classes of R. The distinct equivalence classes: {x Z x = 3k for some integer k} {x Z x = 3k + 1 for some integer k} {x Z x = 3k + 2 for some integer k}. 21 Exercise Let A be the set of all ordered pairs of integers for which the second element of the pair is nonzero. Symbolically A = Z (Z {0}). Define a relation R on A as follows: For all (a b) (c d) A (ab)r(cd) ad=bc. Describe the distinct equivalence classes of R class For of example 1 2 is the class (12): [(1 2)] ={(1 2) ( 1 2) (2 4) ( 2 4) (3 6) ( 3 6)...} since 1 2 = 1 2 = 2 4 = 2 4 = 3 6 = 3 and so forth. 6 22 11