Download presentation
Presentation is loading. Please wait.
1
1 Module 8 Closure Properties –Definition –Language class definition set of languages –Closure properties and first-order logic statements For all, there exists
2
2 Closure Properties A set is closed under an operation if applying the operation to elements of the set produces another element of the set Example/Counterexample –set of integers and addition –set of integers and division
3
3 Integers and Addition Integers 2 5 7
4
4 Integers and Division Integers 2 5.4
5
5 Language Classes –We will be interested in closure properties of language classes A language class is a set of languages Thus, the elements of a language class (set of languages) are languages which are sets themselves –Crucial Observation When we say that a language class is closed under some set operation, we apply the set operation to the languages (elements of the language classes) rather than the language classes themselves
6
6 Example Language Classes * In all these examples, we do not explicitly state what the underlying alphabet is Finite languages –Languages with a finite number of strings CARD-3 –Languages with at most 3 strings
7
7 Finite Sets and Set Union * Finite Sets {0,1,00} {0,1,11} {0,1,00,11}
8
8 CARD-3 and Set Union CARD-3 {0,1,00} {0,1,11} {0,1,00,11} CARD-3: sets with at most 3 elements
9
9 Finite Sets and Set Complement Finite Sets {0,1,01} {/\,00,10,11,000,...}
10
10 Infinite Number of Facts A closure property often represents an infinite number of facts Example: The set of finite languages is closed under the set union operation –{} union {} is a finite language –{} union {0} is a finite language –... –{ } union {} is a finite language –...
11
11 First-order logic and closure properties * A way to formally write (not prove) a closure property –For all L 1,...,L k in LC, op (L 1,... L k ) in LC –Only one expression is needed because of the for all quantifier Number of languages k is determined by arity of the operation op
12
12 Example F-O logic statements * For all L 1,L 2 in FINITE, L 1 union L 2 in FINITE For all L 1,L 2 in CARD-3, L 1 union L 2 in CARD-3 For all L in FINITE, L c in FINITE For all L in CARD-3, L c in CARD-3
13
13 Stating a closure property is false What is true if a set is not closed under some k-ary operator? –There exist k elements of that set which, when combined together under the given operator, produce an element not in the set –There exists L 1,...,L k in LC, op (L 1, …, L k ) not in LC Example –Finite sets and set complement
14
14 Complementing a F-O logic statement Complement “For all L 1,L 2 in CARD-3, L 1 union L 2 in CARD-3” –not (For all L 1,L 2 in CARD-3, L 1 union L 2 in CARD-3) –There exists L 1,L 2 in CARD-3, not (L 1 union L 2 in CARD-3) –There exists L 1,L 2 in CARD-3, L 1 union L 2 not in CARD-3
15
15 Proving/Disproving * Which is easier and why? –Proving a closure property is true –Proving a closure property is false
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.