announcements ics 6b
play

Announcements ICS 6B Regrades for Quiz #3 and Homeworks #4 & 5 - PDF document

Announcements ICS 6B Regrades for Quiz #3 and Homeworks #4 & 5 are due Today Boolean Algebra & Logic Lecture Notes for Summer Quarter, 2008 Michele Rousseau Set 8 Ch. 8.6, 11.6 2 Lecture Set 8 - Chpts 8.6, 11.1 Todays


  1. Announcements ICS 6B � Regrades for Quiz #3 and Homeworks #4 & 5 are due Today Boolean Algebra & Logic Lecture Notes for Summer Quarter, 2008 Michele Rousseau Set 8 – Ch. 8.6, 11.6 2 Lecture Set 8 - Chpts 8.6, 11.1 Today’s Lecture � Chapter 8 �8.6�, Chapter 11 �11.1� ● Partial Orderings �8.6� Chapter 8: Section 8.6 ● Boolean Functions �11.1� Partial Orderings (Continued) Lecture Set 8 - Chpts 8.6, 11.1 3 What is a Partial Order? Some more defintions Let R be a relation on A. The R is a partial order iff R is: � If �A,R� is a poset and a,b are � A, reflexive, antisymmetric, & transitive we say that: � �A,R� is called a partially ordered set or “poset” ● “a and b are comparable” if a�b or b�a � Notation: ◘ �i.e. if �a,b��R and �b,a��R� ● “a and b are incomparable” if neither a�b nor b�a p ● If �A R� is a poset and a and b are 2 elements of A ● If �A,R� is a poset and a and b are 2 elements of A ◘ �i.e if �a,b��R and �b,a��R such that �a,b��R, we write a � b �instead of aRb� � If two objects are always related in a poset it is called a total order , linear order or simple order . NOTE: it is not required that two things be related ● In this case �A,R� is called a chain . under a partial order. ● �i.e if any two elements of A are comparable� ● That’s the “partial” of it. ● So for all a,b � A, it is true that �a,b��R or �b,a��R 5 Lecture Set 8 - Chpts 8.6, 11.1 6 1

  2. Now onto more examples… More Examples Let A��0,1,2,3� and Let A��a,b,c,d� and let R be the relation Let R���0,0��1,1�, �2,0�,�2,2�,�2,3��3,3�� on A represented by the diagraph We draw the associated digraph: The R is reflexive, but a b not antisymmetric �a,c� &�c,a� It is easy to check that R is 0 1 1 and not and not Refl. , antisym. & trans. c transitive �d,c��c,a�, but not �d,a� d So �A,R� is a poset. 2 3 The elements 1,3 are incomparable �because �1, 3�� R and �3, 1�� R � so �A,R� is not a total ordered set. 7 8 Lecture Set 8 - Chpts 8.6, 11.1 Lecture Set 8 - Chpts 8.6, 11.1 More Examples (3) Another example Let A��a,b,c,d� and let R be the related Matrix: A��all people� [ ] [ ] R�the relation “a not taller than b” 1 1 1 0 To check Then a b 0 1 1 0 properties R is reflexive �a is not taller than a� 0 0 1 1 more easily 1 1 0 0 1 lets convert R is not antisymmetric R i i i it to a diagraph c d ● If “a is not taller than b” and “b is not taller than a”, then a and b have the same height, but a is not necessarily equal to b – it could be 2 people of the We see that R is reflexive �loops at every vertex� same height. and antisymmetric �no double arrows� Not a poset! It is not transitive �eg. �c,d� & �d,a�, but no �c,a�� Lecture Set 8 - Chpts 8.6, 11.1 9 Lecture Set 8 - Chpts 8.6, 11.1 10 Lexicographic Order Lexicographic Order Suppose that �A 1 .� 1 � and �A 2 ,� 2 � are two posets. We construct a partial ordering on the Cartesian product A 1 x A 2 . � Lexicographic order is how we order words in the dictionary Given 2 elements �a 1 , a 2 � and �b 1 , b 2 � in A 1 x A 2 ● It is AKA dictionary order or alphabetic order We say that �a 1 , a 2 � � �b 1 , b 2 � ● First, we compare the 1 st letters, if they are Iff a 1 � b 1 �but a 1 �b 1 � equal then we check the 2 nd pair and etc. or a 1 �b 1 and a 2 � b 2 . equal then we check the 2 pair and etc. ◘ E.g Let S��1,2,3� In other words, ◘ The lexicographical order of �a 1 , a 2 � � �b 1 , b 2 � iff 1. the first entries of �a 1 , a 2 � � the first entries of �b 1 , b 2 � P�S� ���,�1�,�1,2�,�1,2,3�,�1,3�,�2�,�2,3�,�3� or � We can apply this to any poset 2. the first entries of �a 1 , a 2 � and �b 1 , b 2 � , and the 2 nd entries of �a 1 , a 2 � � the 2 nd entries of �b 1 , b 2 � entry ● On a poset it is a natural order structure on the Cartesian product. 11 12 2

  3. Examples Example (2) Which of the following are true? EX. A 1 � A 2 ��; R 1 � R 2 �� �3,5� � �4,8� True Then �1,3� � �1,4� ; �1,3� � �2,0�; �4,4� � �2,8� False �1, 3� � �1, 3� In general, given �a 1 , a 2 � and �b 1 , b 2 �, g g � 1 2 � � 2 � � , � �3,8� � �4,5� � , � True 1 compare a 1 and b 1 �1,2,4,10� � �1,2,5,8� True If a 1 � b 1 then �2,4,5� � �2,3,6� False �a 1 , a 2 � � �b 1 , b 2 � �1,5,8� � �2,3,4� True ElseIf a 1 � b 1 , then If b 1 � b 2 then �a 1 , a 2 � � �b 1 , b 2 � 13 14 Lecture Set 8 - Chpts 8.6, 11.1 Lecture Set 8 - Chpts 8.6, 11.1 Strings Well Ordered Set � We apply this ordering to strings of symbols where � Let �A,R� be a poset there is an underlying 'alphabetical' or partial We say that A is a well‐ordered set if any non‐empty order �which is a total order in this case�. subset B�A has a least element. Example: In other words, � Let A � � a, b, c� and suppose R is the natural a�B is a least element if a�b for all b�B. alphabetical order on A: p �recall that R is denoted by �� �recall that R is denoted by �� a R b and b R c. Example Then �� � , �� is well ordered ● Any shorter string is related to any longer string �comes ● Any subset B�� �which is not empty� has a least element. before it in the ordering�. ● Eg if B��2,3,4,5,27,248,1253� then the least element is ● If two strings have the same length then use the induced a�2, because a� b for all b�B. partial order from the alphabetical order: ��, �� is not well ordered aabc R abac ● Choose B��, there is no least element 15 16 Example Hasse Diagram Construct the Hasse diagram of To every poset �A,R� we associate a Hasse diagram A��1, 2, 3�, R � � ● �A graph that carries less info than the diagraph� � Thus R���1,1�,�1,2�,�1,3�,�2,2�,�2,3�,�3,3�� To construct a Hasse diagram: Step 2: Step 1:Draw the Digraph 1� Construct a digraph representation of the poset Remove loops With arrows pointing up p g p �A, R� so that all arcs point up �except the loops�. �A, R� so that all arcs point up �except the loops�. 3 2� Eliminate all loops R is reflexive – SO we know they are there • 3� Eliminate all arcs that are redundant because of Step 3: Eliminate 2 transitivity redundant transitive arcs Keep �a,b� and �b,c� � remove �a,c� • 4� Eliminate the arrows at the ends of arcs since Step 4: Remove arrows 1 everything points up. �and it is antisymmetric so arrows go only 1 way� 17 Lecture Set 8 - Chpts 8.6, 11.1 18 3

  4. Example (2) Example (3) Construct the Hasse diagram of �P��a, b, c��, �� � Given the Hasse diagram write down all � The elements of P��a, b, c�� are the ordered pairs in R � �a�, �b�, �c� � Okay, so what do we know about this diagram �a, b�, �a, c�, �b, c� {a, b, c} c d � We know it is antisymmetric � We know it is antisymmetric �a, b, c� and that the arrows point up • � Basically, it shows � We know it is reflexive {a, c} {a, b} {b, c} a hierarchy � We also know it is transitive {b} {a} b � Now that we have the diagraph R {c} is easy to find R���a,a�,�a,b�,�a,c�,�a,d�,�b,b�,�b,c�, � a �b,d�,�c,c�,�d,d�� 19 20 Lecture Set 8 - Chpts 8.6, 11.1 Lecture Set 8 - Chpts 8.6, 11.1 Maximal and Minimal Elements Example Let �S, �� be a poset � In this diagram An element a � S is called maximal if there What is the maximal element? is no b such that a � b. What is the minimal element? In other words {a, b, c} M Maximal i l a is not less than any element in the poset. Similarly, Note: there can {a, c} {a, b} {b, c} be more than An element B � S is called minimal if there is 1 minimal and {b} {a} no b such that b � a. {c} maximal element in a poset These are easy to find in a Hasse diagram Minimal � Because they are the “top” and “bottom” elements Lecture Set 8 - Chpts 8.6, 11.1 21 Lecture Set 8 - Chpts 8.6, 11.1 22 22 Example (2) Greatest and Least Elements a�S is called the greatest element of poset �S, ��, if b � a , �b � S 3 Maximal elements � If there is only 1 maximal element then it is the greatest. Note: Every poset h has 1 or more 1 a�S is called the least element of poset �S, maximal elements ��, if a � b , �b � S and 1 or more Minimal elements � If there is only 1 minimal element then it is the least 2 Minimal elements Note: The greatest and least may not exist Lecture Set 8 - Chpts 8.6, 11.1 23 Lecture Set 8 - Chpts 8.6, 11.1 24 4

Recommend


More recommend