Ambiguity, closure properties, Overview of ambiguity, and Chomsky s standard form


 Kelly Reynolds
 2 years ago
 Views:
Transcription
1 Ambiguity, closure properties, and Chomsky s normal form Overview of ambiguity, and Chomsky s standard form
2 The notion of ambiguity Convention: we assume that in every substitution, the leftmost remaining variable is the one that is replaced. When this convention is applied to all substitutions in a derivation, we talk about leftmost derivations Definition: A CGF is said to be ambiguous if a string in its language has two different leftmost derivations. In such a case, the string has necessarily two different parsing trees
3 Equivalence and ambiguity Definition: Two contextfree grammars are declared to be equivalent if and only if they produce the same contextfree language. Remark: An ambiguous contextfree grammar may have an equivalent unambiguous contextfree grammar. Definition: Given an ambiguous grammar, the process of identifying an equivalent grammar that is not ambiguous is called disambiguation. If not such grammar exists, the language is called inherently ambiguous 3
4 Example of an ambiguous contextfree grammar Let G = ({, A}, {,}, R, } R = { A λ, A A A } w = L( G) Then, the string has the following two leftmost derivations:.. A A A A A A 4
5 The grammar is not inherently ambiguous The ambiguity stems from the fact that the rule A A can be use in the first or in the second substitution indistinctively. In either case the same string is derived. w = L( G) L(G) However, is not inherently ambiguous. Following is a context free grammar that eliminates the above ambiguity. 5
6 Disambiguation Let G R = ({, A, B},{,}, R, ) = { A λ, A A B, B B } Claim: L ( G ) = L ( G ) and under G each string is derived by a unique sequence of leftmost substitutions. This is, the new grammar derives the language unambiguously Proof: exercise! 6
7 Closure properties Theorem 9.: Contextfree languages are closed under regular operations L L cketch of the proof: Let and be contextfree languages. Let G = ( V, A, R, and G = ( V, A, R, ) be contextfree grammars such that L = L( G ) and L ( ) = L G respectively. We may assume without loss of generality that V I = φ. V ) 7
8 Proof (cont.) Define the contextfree grammars:. U = ({ } UV UV, A, R U R U{ },. C = ({ } UV UV, A, R U R U{ }, 3. T = ({ } U V, A, R U { λ }, ) Here we assume V UV Claim: L ( U ) = L U L L( C) = L L L( T) = L The rest of the proof (i.e. verification of the claim) is left as an exercise. ) ) * 8
9 Applications n. The language { n n n M = : n, n } is contextfree, since it is the concatenation n n of L = { : n } with itself. The language = i n n nk nk { : k N ( i =,..., k) n is also contextfree, since it is the starclosure of L } 9
10 Chomsky normal form Theorem 9.: (Chomsky normal form) Any contextfree grammar is equivalent to a grammar G = ( V, A, R, ) whose productions are either of the form: Z UT Z a λ where Z, U, T V U T ; or where a A ; or
11 Method 9. Transforming a contextfree grammar into a grammar in Chomsky normal form Given a contextfree grammar G=(V,A,R,). Add a new start variable and add the rule. Remove all rules of the form u λ, u V adding the rules that are necessary to preserve the grammar s productions 3. Eliminate unit rules. These are rules of the form of u v, u, v V and their elimination requires adding the rules u w wherever v w appears, unless was already eliminated 4. Convert rules of the form k to a set of rules of the form u a u, u au,..., uk ak ak where the u i ' s are new variables. 5. Convert rules of the form k to rules of the form of u w u a... a a3 a, k 3 u a... a, k ui ai, wherever ai is a terminal.here, ui is a new variable.
12 Example The context free grammar: G R = ({ },{,}, R, ) = { λ} is not in Chomsky normal form. We will find an equivalent contextfree grammar N, which is in Chomsky normal form, using the previous procedure (Method 9.)
13 Example (cont.). Define a new start variable Old productions λ
14 Example (cont.). Eliminate unitary productions. In our case we have: λ Recall that the removal is performed by eliminating them and adding all rules necessary to preserve the original grammar s derivations
15 Example (cont.) The derivations that involve these unitary productions (and have to be preserved) are: Thus, the new set of rules is: λ
16 Example (cont.) The latter set of rules define an equivalent grammar which is not yet in Chomsky normal form. Indeed no rule, except the one that associate the starting variable with the null string, is in Chomsky normal form. We ll fix this in the next step: 3. Decomposing all remaining productions that are not in Chomsky normal form into sets of productions with two variables or a terminal on the right hand side.
17 Example (cont.) This applies to the current productions:,, We transform each of them into a set of productions in Chomsky normal form as follows
18 Example (cont.) Consider first: This production is clearly equivalent to the combined action of the following productions:
19 Example (cont.) As for we have: ) ( 3 3 ince there are here productions that were already defined, we replace the variables: ) ( ) ( : : = =
20 Example (cont.) After replacing we get: 3 3
21 Example (cont.) And similarly, using the already defined productions, we transform and 3 3
22 Example (cont.) In summary, we get:, { ), },{,},,,,, ({ 3 3 R R N = = λ },,,, { R = λ
23 Does it work? Let s derive a few strings: λ 3 3
24 What s so important about Chomsky s normal form? Theorem 9.3: A contextfree grammar in Chomsky normal form derives a string of length n in exactly n substitutions Proof: Let G w = w of rules of of be a context  free grammar in Chomsky normal form and let w such rules. L ( G ).ince each w n i produced by substituting a the form of v But, the formation of the form u v n. Thus, rule of zv, u, z, v such rules involved in the generation of is a terminal, it could only be the form v the derivation of v v n w involves n applications of can only be done by applying variables.there are exactly n applications v i v w n. i in a string of variables
25 A note on contextsensitive grammars Definition: A contextsensitive grammar is a quadruple G = ( V, A, R, ) wherev, A and are just as in a context  free grammar, but the set of rules R includes rules of the form aub cvd, whereu andv are variables, and a, b, c, and d are strings of variables and literals. 5
26 Example Let G=({,R,T,U,V,W},{a, b, c}, R, ) R= { arc, R art b, btc bbcc, btt bbut, UT UU, UUc VUc Vcc, UV VV, bvc bbcc, bvv bbwv, WV WW, WWc TWc Tcc, WT TT } This grammar generates the canonical noncontextfree n n n language: {a b c : n } 6
27 A derivation The derivation of the string is: aaabbbccc arc aartc aaarttc aaabttc aaabbutc aaabbuuc aaabbvuc aaabbvcc aaabbbccc 7
28 Note on normal forms Principle: Every contextsensitive grammar which does not generate the empty string can be transformed into an equivalent grammar in Kuroda normal form Remark: The normal form will not in general be a contextsensitive grammar, but will be a noncontracting grammar 8
ContextFree Grammars (CFG)
ContextFree Grammars (CFG) SITE : http://www.sir.blois.univtours.fr/ mirian/ Automata Theory, Languages and Computation  Mírian HalfeldFerrari p. 1/2 An informal example Language of palindromes: L
More informationChomsky and Greibach Normal Forms. Chomsky and Greibach Normal Forms p.1/24
Chomsky and Greibach Normal Forms Chomsky and Greibach Normal Forms p.1/24 Simplifying a CFG It is often convenient to simplify CFG Chomsky and Greibach Normal Forms p.2/24 Simplifying a CFG It is often
More informationHomework Four Solution CSE 355
Homework Four Solution CSE 355 Due: 29 March 2012 Please note that there is more than one way to answer most of these questions. The following only represents a sample solution. Problem 1: Linz 5.1.23
More informationThe Halting Problem is Undecidable
185 Corollary G = { M, w w L(M) } is not Turingrecognizable. Proof. = ERR, where ERR is the easy to decide language: ERR = { x { 0, 1 }* x does not have a prefix that is a valid code for a Turing machine
More informationPushdown automata. Informatics 2A: Lecture 9. Alex Simpson. 3 October, 2014. School of Informatics University of Edinburgh als@inf.ed.ac.
Pushdown automata Informatics 2A: Lecture 9 Alex Simpson School of Informatics University of Edinburgh als@inf.ed.ac.uk 3 October, 2014 1 / 17 Recap of lecture 8 Contextfree languages are defined by contextfree
More informationContextFree Grammars
ContextFree Grammars Describing Languages We've seen two models for the regular languages: Automata accept precisely the strings in the language. Regular expressions describe precisely the strings in
More informationCPS 140  Mathematical Foundations of CS Dr. S. Rodger Section: Properties of ContextFree Languages èhandoutè Section 3.5 Which of the following languages are CFL? æ L=fa n b n c j j 0 énçjg æ L=fa n
More informationPlease note that there is more than one way to answer most of these questions. The following only represents a sample solution.
HOMEWORK THREE SOLUTION CSE 355 DUE: 10 MARCH 2011 Please note that there is more than one way to answer most of these questions. The following only represents a sample solution. (1) 2.4 and 2.5 (b),(c),(e),(f):
More informationComputational Linguistics: Syntax I
Computational Linguistics: Syntax I Raffaella Bernardi KRDB, Free University of BozenBolzano P.zza Domenicani, Room: 2.28, email: bernardi@inf.unibz.it Contents 1 Syntax...................................................
More informationIntroduction to Automata Theory. Reading: Chapter 1
Introduction to Automata Theory Reading: Chapter 1 1 What is Automata Theory? Study of abstract computing devices, or machines Automaton = an abstract computing device Note: A device need not even be a
More informationOverview of E0222: Automata and Computability
Overview of E0222: Automata and Computability Deepak D Souza Department of Computer Science and Automation Indian Institute of Science, Bangalore. August 3, 2011 What this course is about What we study
More informationTheory of Computation
Theory of Computation For Computer Science & Information Technology By www.thegateacademy.com Syllabus Syllabus for Theory of Computation Regular Expressions and Finite Automata, ContextFree Grammar s
More informationA FixedPoint Approach towards Efficient Models Conversion
ISSN: 19408978 A FixedPoint Approach towards Efficient Models Conversion Stefan Andrei, Hikyoo Koh No. 2, June 2008 Computer Science Department Technical Reports  Lamar University Computer Science Department,
More informationAutomata and Computability. Solutions to Exercises
Automata and Computability Solutions to Exercises Fall 25 Alexis Maciel Department of Computer Science Clarkson University Copyright c 25 Alexis Maciel ii Contents Preface vii Introduction 2 Finite Automata
More informationInner Product Spaces and Orthogonality
Inner Product Spaces and Orthogonality week 34 Fall 2006 Dot product of R n The inner product or dot product of R n is a function, defined by u, v a b + a 2 b 2 + + a n b n for u a, a 2,, a n T, v b,
More informationDeterministic PushDown Store Automata
Deterministic PushDown tore Automata 1 ContextFree Languages A B C D... A w 0 w 1 D...E The languagea n b n : a b ab 2 Finitetate Automata 3 Pushdown Automata Pushdown automata (pda s) is an fsa with
More informationFormal Grammars and Languages
Formal Grammars and Languages Tao Jiang Department of Computer Science McMaster University Hamilton, Ontario L8S 4K1, Canada Bala Ravikumar Department of Computer Science University of Rhode Island Kingston,
More informationÖVNINGSUPPGIFTER I SAMMANHANGSFRIA SPRÅK. 15 april 2003. Master Edition
ÖVNINGSUPPGIFTER I SAMMANHANGSFRIA SPRÅK 5 april 23 Master Edition CONTEXT FREE LANGUAGES & PUSHDOWN AUTOMATA CONTEXTFREE GRAMMARS, CFG Problems Sudkamp Problem. (3.2.) Which language generates the grammar
More informationApproximating ContextFree Grammars for Parsing and Verification
Approximating ContextFree Grammars for Parsing and Verification Sylvain Schmitz LORIA, INRIA Nancy  Grand Est October 18, 2007 datatype a option = NONE SOME of a fun filter pred l = let fun filterp (x::r,
More informationFinite Automata and Formal Languages
Finite Automata and Formal Languages TMV026/DIT321 LP4 2011 Lecture 14 May 19th 2011 Overview of today s lecture: Turing Machines Pushdown Automata Overview of the Course Undecidable and Intractable Problems
More informationParsing IV Bottomup Parsing
Parsing IV Bottomup Parsing Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412 at Rice University have explicit permission to make copies
More informationInfinitely Repeated Games with Discounting Ù
Infinitely Repeated Games with Discounting Page 1 Infinitely Repeated Games with Discounting Ù Introduction 1 Discounting the future 2 Interpreting the discount factor 3 The average discounted payoff 4
More informationCOMP 356 Programming Language Structures Notes for Chapter 4 of Concepts of Programming Languages Scanning and Parsing
COMP 356 Programming Language Structures Notes for Chapter 4 of Concepts of Programming Languages Scanning and Parsing The scanner (or lexical analyzer) of a compiler processes the source program, recognizing
More informationParse Trees. Prog. Prog. Stmts. { Stmts } Stmts = Stmts ; Stmt. id + id = Expr. Stmt. id = Expr. Expr + id
Parse Trees To illustrate a derivation, we can draw a derivation tree (also called a parse tree): Prog { Stmts } Stmts ; Stmt Stmt = xpr = xpr xpr + An abstract syntax tree (AST) shows essential structure
More informationSyntactic Analysis and ContextFree Grammars
Syntactic Analysis and ContextFree Grammars CSCI 3136 Principles of Programming Languages Faculty of Computer Science Dalhousie University Winter 2012 Reading: Chapter 2 Motivation Source program (character
More informationModel 2.4 Faculty member + student
Model 2.4 Faculty member + student Course syllabus for Formal languages and Automata Theory. Faculty member information: Name of faculty member responsible for the course Office Hours Office Number Email
More informationCompilers I  Chapter 2: An introduction to syntax analysis (and a complete toy compiler)
Compilers I  Chapter 2: An introduction to syntax analysis (and a complete toy compiler) Lecturers: Part I: Paul Kelly (phjk@doc.ic.ac.uk) Office: room 423 Part II: Naranker Dulay (nd@doc.ic.ac.uk) Office:
More informationLecture 1: Schur s Unitary Triangularization Theorem
Lecture 1: Schur s Unitary Triangularization Theorem This lecture introduces the notion of unitary equivalence and presents Schur s theorem and some of its consequences It roughly corresponds to Sections
More informationCS5236 Advanced Automata Theory
CS5236 Advanced Automata Theory Frank Stephan Semester I, Academic Year 20122013 Advanced Automata Theory is a lecture which will first review the basics of formal languages and automata theory and then
More informationProbabilistic ContextFree Grammars (PCFGs)
Probabilistic ContextFree Grammars (PCFGs) Michael Collins 1 ContextFree Grammars 1.1 Basic Definition A contextfree grammar (CFG) is a 4tuple G = (N, Σ, R, S) where: N is a finite set of nonterminal
More informationCS 4120 Introduction to Compilers
CS 4120 Introduction to Compilers Andrew Myers Cornell University Lecture 5: Topdown parsing 5 Feb 2016 Outline More on writing CFGs Topdown parsing LL(1) grammars Transforming a grammar into LL form
More informationWhat s a parser How to use Bison? Practice References. Introduction to GDB. Gregorio Toscano Pulido
Laboratorio de Tecnologías de Información Centro de Investigación y de Estudios Avanzados del IPN Laboratorio de Tecnologías de Investigación Outline 1 What s a parser 2 How to use Bison? 3 Practice 4
More informationIntelligent Systems (AI2)
Intelligent Systems (AI2) Computer Science cpsc422, Lecture 25 Nov, 9, 2016 CPSC 422, Lecture 26 Slide 1 Morphology Syntax Semantics Pragmatics Discourse and Dialogue KnowledgeFormalisms Map (including
More informationCourse Manual Automata & Complexity 2015
Course Manual Automata & Complexity 2015 Course code: Course homepage: Coordinator: Teachers lectures: Teacher exercise classes: Credits: X_401049 http://www.cs.vu.nl/~tcs/ac prof. dr. W.J. Fokkink home:
More informationLearning Analysis by Reduction from Positive Data
Learning Analysis by Reduction from Positive Data František Mráz 1, Friedrich Otto 1, and Martin Plátek 2 1 Fachbereich Mathematik/Informatik, Universität Kassel 34109 Kassel, Germany {mraz,otto}@theory.informatik.unikassel.de
More information3. Recurrence Recursive Definitions. To construct a recursively defined function:
3. RECURRENCE 10 3. Recurrence 3.1. Recursive Definitions. To construct a recursively defined function: 1. Initial Condition(s) (or basis): Prescribe initial value(s) of the function.. Recursion: Use a
More informationOn String Languages Generated by Spiking Neural P Systems
On String Languages Generated by Spiking Neural P Systems Haiming Chen 1, Rudolf Freund 2, Mihai Ionescu 3, Gheorghe Păun 4,5, Mario J. PérezJiménez 5 1 Computer Science Laboratory, Institute of Software
More informationProperties of Regular Languages
Properties of Regular Languages SITE : http://www.info.blois.univtours.fr/ mirian/ Automata Theory, Languages and Computation  Mírian HalfeldFerrari p. 1/3 Algebraic Laws for Regular Expressions Two
More informationHere we see a case of infinite expansion of instruments.
No. SemesterExamination of CS674 Name: 1. The sentence John drank a glass of milk can be paraphrased as John ingested the milk by getting the milk to his mouth from glass by transferring the glass containing
More informationTuring Machines: An Introduction
CIT 596 Theory of Computation 1 We have seen several abstract models of computing devices: Deterministic Finite Automata, Nondeterministic Finite Automata, Nondeterministic Finite Automata with ɛtransitions,
More informationUsing HandsOn Visualizations to Teach Computer Science from Beginning Courses to Advanced Courses
Using HandsOn Visualizations to Teach Computer Science from Beginning Courses to Advanced Courses Susan H. Rodger Department of Computer Science Duke University Durham, NC 27705 rodger@cs.duke.edu Abstract
More informationChapter 7 Uncomputability
Chapter 7 Uncomputability 190 7.1 Introduction Undecidability of concrete problems. First undecidable problem obtained by diagonalisation. Other undecidable problems obtained by means of the reduction
More informationSyntaktická analýza. Ján Šturc. Zima 208
Syntaktická analýza Ján Šturc Zima 208 Position of a Parser in the Compiler Model 2 The parser The task of the parser is to check syntax The syntaxdirected translation stage in the compiler s frontend
More informationReading 13 : Finite State Automata and Regular Expressions
CS/Math 24: Introduction to Discrete Mathematics Fall 25 Reading 3 : Finite State Automata and Regular Expressions Instructors: Beck Hasti, Gautam Prakriya In this reading we study a mathematical model
More informationComputer Science Through Urn Games: An Unified Framework for a Hierarchy of Solvable and Unsolvable Problems
Computer Science Through Urn Games: An Unified Framework for a Hierarchy of Solvable and Unsolvable Problems Sorin Istrail Department of Computer Science Brown University Dedicated to Alan Turings 100th
More informationAn Overview of a Compiler
An Overview of a Compiler Department of Computer Science and Automation Indian Institute of Science Bangalore 560 012 NPTEL Course on Principles of Compiler Design Outline of the Lecture About the course
More informationCompiler Construction
Compiler Construction Regular expressions Scanning Görel Hedin Reviderad 2013 01 23.a 2013 Compiler Construction 2013 F021 Compiler overview source code lexical analysis tokens intermediate code generation
More informationCSC 310: Information Theory
CSC 310: Information Theory University of Toronto, Fall 2011 Instructor: Radford M. Neal Week 2 What s Needed for a Theory of (Lossless) Data Compression? A context for the problem. What are we trying
More informationU.C. Berkeley CS276: Cryptography Handout 0.1 Luca Trevisan January, 2009. Notes on Algebra
U.C. Berkeley CS276: Cryptography Handout 0.1 Luca Trevisan January, 2009 Notes on Algebra These notes contain as little theory as possible, and most results are stated without proof. Any introductory
More informationMildly Context Sensitive Grammar Formalisms
Mildly Context Sensitive Grammar Formalisms Petra Schmidt PfarrerLauerStrasse 23 66386 St. Ingbert petra.schmidt@edekasuedwest.de Overview 3 TreedjoiningGrammars 4 Co 7 8 9 CCG 9 LIG 10 TG 13 Linear
More information3515ICT Theory of Computation Turing Machines
Griffith University 3515ICT Theory of Computation Turing Machines (Based loosely on slides by Harald Søndergaard of The University of Melbourne) 90 Overview Turing machines: a general model of computation
More information8 Simulatability of Net Types
8 Simulatability of Net Types In chapter 7 was presented different higher order net types. Now we discuss the relations between these net types, place transition nets, and condition event nets. Especially
More informationLow upper bound of ideals, coding into rich Π 0 1 classes
Low upper bound of ideals, coding into rich Π 0 1 classes Antonín Kučera the main part is a joint project with T. Slaman Charles University, Prague September 2007, Chicago The main result There is a low
More information5HFDOO &RPSLOHU 6WUXFWXUH
6FDQQLQJ 2XWOLQH 2. Scanning The basics Adhoc scanning FSM based techniques A Lexical Analysis tool  Lex (a scanner generator) 5HFDOO &RPSLOHU 6WUXFWXUH 6RXUFH &RGH /H[LFDO $QDO\VLV6FDQQLQJ 6\QWD[ $QDO\VLV3DUVLQJ
More informationHomework Three Solution CSE 355
Homework Three Solution CSE 355 Due: 06 March 2012 Please note that there is more than one way to answer most of these questions. The following only represents a sample solution. Problem 1: Linz 4.1.13
More informationHonors Class (Foundations of) Informatics. Tom Verhoeff. Department of Mathematics & Computer Science Software Engineering & Technology
Honors Class (Foundations of) Informatics Tom Verhoeff Department of Mathematics & Computer Science Software Engineering & Technology www.win.tue.nl/~wstomv/edu/hci c 2011, T. Verhoeff @ TUE.NL 1/20 Information
More informationMathematical Induction
Mathematical Induction (Handout March 8, 01) The Principle of Mathematical Induction provides a means to prove infinitely many statements all at once The principle is logical rather than strictly mathematical,
More informationContext Free Grammars
Context Free Grammars So far we have looked at models of language that capture only local phenomena, namely what we can analyze when looking at only a small window of words in a sentence. To move towards
More informationAutomata and Languages
Automata and Languages Computational Models: An idealized mathematical model of a computer. A computational model may be accurate in some ways but not in others. We shall be defining increasingly powerful
More informationLocal periods and binary partial words: An algorithm
Local periods and binary partial words: An algorithm F. BlanchetSadri and Ajay Chriscoe Department of Mathematical Sciences University of North Carolina P.O. Box 26170 Greensboro, NC 27402 6170, USA Email:
More informationFixedPoint Logics and Computation
1 FixedPoint Logics and Computation Symposium on the Unusual Effectiveness of Logic in Computer Science University of Cambridge 2 Mathematical Logic Mathematical logic seeks to formalise the process of
More informationSRM UNIVERSITY FACULTY OF ENGINEERING & TECHNOLOGY SCHOOL OF COMPUTING DEPARTMENT OF SOFTWARE ENGINEERING COURSE PLAN
Course Code : CS0355 SRM UNIVERSITY FACULTY OF ENGINEERING & TECHNOLOGY SCHOOL OF COMPUTING DEPARTMENT OF SOFTWARE ENGINEERING COURSE PLAN Course Title : THEORY OF COMPUTATION Semester : VI Course : June
More informationClassification of Cartan matrices
Chapter 7 Classification of Cartan matrices In this chapter we describe a classification of generalised Cartan matrices This classification can be compared as the rough classification of varieties in terms
More informationCS 4310 HOMEWORK SET 1
CS 4310 HOMEWORK SET 1 PAUL MILLER Section 2.1 Exercises Exercise 2.11. Using Figure 2.2 as a model, illustrate the operation of INSERTIONSORT on the array A = 31, 41, 59, 26, 41, 58. Solution: Assume
More informationAnalysis of Algorithms I: Binary Search Trees
Analysis of Algorithms I: Binary Search Trees Xi Chen Columbia University Hash table: A data structure that maintains a subset of keys from a universe set U = {0, 1,..., p 1} and supports all three dictionary
More informationRegular Expressions with Nested Levels of Back Referencing Form a Hierarchy
Regular Expressions with Nested Levels of Back Referencing Form a Hierarchy Kim S. Larsen Odense University Abstract For many years, regular expressions with back referencing have been used in a variety
More informationScanning and parsing. Topics. Announcements Pick a partner by Monday Makeup lecture will be on Monday August 29th at 3pm
Scanning and Parsing Announcements Pick a partner by Monday Makeup lecture will be on Monday August 29th at 3pm Today Outline of planned topics for course Overall structure of a compiler Lexical analysis
More informationChapter 2 How to Describe a Programming Language
Chapter 2 How to Describe a Programming Language A programming language is an artificial formalism in which algorithms can be expressed. For all its artificiality, though, this formalism remains a language.
More informationOHJ2306 Fall 2011 Introduction to Theoretical Computer Science
1 OHJ2306 Fall 2011 Introduction to Theoretical Computer Science 2 3 Organization & timetable Lectures: prof. Tapio Elomaa, M.Sc. Timo Aho Tue and Thu 14 16 TB220 Aug. 30 Dec. 8, 2011 Exceptions: Thu
More informationPractice Problems for Final Exam: Solutions CS 341: Foundations of Computer Science II Prof. Marvin K. Nakayama
Practice Problems for Final Exam: Solutions CS 341: Foundations of Computer Science II Prof. Marvin K. Nakayama 1. Short answers: (a) Define the following terms and concepts: i. Union, intersection, set
More informationMATH10212 Linear Algebra. Systems of Linear Equations. Definition. An ndimensional vector is a row or a column of n numbers (or letters): a 1.
MATH10212 Linear Algebra Textbook: D. Poole, Linear Algebra: A Modern Introduction. Thompson, 2006. ISBN 0534405967. Systems of Linear Equations Definition. An ndimensional vector is a row or a column
More informationLecture 4: Partitioned Matrices and Determinants
Lecture 4: Partitioned Matrices and Determinants 1 Elementary row operations Recall the elementary operations on the rows of a matrix, equivalent to premultiplying by an elementary matrix E: (1) multiplying
More informationSolving Systems of Linear Equations
LECTURE 5 Solving Systems of Linear Equations Recall that we introduced the notion of matrices as a way of standardizing the expression of systems of linear equations In today s lecture I shall show how
More informationKhair Eddin Sabri and Ridha Khedri
Khair Eddin Sabri and Ridha Foundations & Practice of Security Symposium (Oct. 2012) CRYPTO Presentation Outline 1 Introduction 2 3 4 Order Semiring 5 keystructure 6 7 8 Technique 9 Verification of secrecy
More informationCS 164 Programming Languages and Compilers Handout 8. Midterm I
Mterm I Please read all instructions (including these) carefully. There are six questions on the exam, each worth between 15 and 30 points. You have 3 hours to work on the exam. The exam is closed book,
More informationChapter 4: More on Logical, Information, and Text Functions
CSE 1520.03 The Glade Manual Chapter 4: More on Logical, Information, and Text Functions Introduction Logical functions are those that involve Boolean values. The Boolean values are TRUE and FALSE. Some
More information5 2x 3y= 9 4x+7y=56. 3x+4y=16 4x 7y= x
Systems of Inequalities 1 Given system of inequalities of the form Ax b Goals: determine if system has an integer solution enumerate all integer solutions 2 bounds for x: (2) and (3) Upper bounds for x:
More informationComputability Theory
CSC 438F/2404F Notes (S. Cook and T. Pitassi) Fall, 2014 Computability Theory This section is partly inspired by the material in A Course in Mathematical Logic by Bell and Machover, Chap 6, sections 110.
More informationUnified Language for Network Security Policy Implementation
Unified Language for Network Security Policy Implementation Dmitry Chernyavskiy Information Security Faculty National Research Nuclear University MEPhI Moscow, Russia milnat2004@yahoo.co.uk Natalia Miloslavskaya
More informationForbidden Substrings on Weighted Alphabets
Forbidden Substrings on Weighted Alphabets Amy N Myers June 9, 2009 Abstract In an influential 98 paper, Guibas and Odlyzko constructed a generating function for the number of length n strings over a finite
More informationCompiler I: Syntax Analysis Human Thought
Course map Compiler I: Syntax Analysis Human Thought Abstract design Chapters 9, 12 H.L. Language & Operating Sys. Compiler Chapters 1011 Virtual Machine Software hierarchy Translator Chapters 78 Assembly
More informationFORMAL LANGUAGES, AUTOMATA AND COMPUTATION
FORMAL LANGUAGES, AUTOMATA AND COMPUTATION REDUCIBILITY ( LECTURE 16) SLIDES FOR 15453 SPRING 2011 1 / 20 THE LANDSCAPE OF THE CHOMSKY HIERARCHY ( LECTURE 16) SLIDES FOR 15453 SPRING 2011 2 / 20 REDUCIBILITY
More informationMATH20302 Propositional Logic. Mike Prest School of Mathematics Alan Turing Building Room
MATH20302 Propositional Logic Mike Prest School of Mathematics Alan Turing Building Room 1.120 mprest@manchester.ac.uk April 10, 2015 Contents I Propositional Logic 3 1 Propositional languages 4 1.1 Propositional
More informationFormal Languages and Automata Theory  Regular Expressions and Finite Automata 
Formal Languages and Automata Theory  Regular Expressions and Finite Automata  Samarjit Chakraborty Computer Engineering and Networks Laboratory Swiss Federal Institute of Technology (ETH) Zürich March
More informationJOINING UP TO THE GENERALIZED HIGH DEGREES
PROCEEDINGS OF THE AMERICAN MATHEMATICAL SOCIETY Volume 138, Number 8, August 2010, Pages 2949 2960 S 00029939(10)102998 Article electronically published on March 29, 2010 JOINING UP TO THE GENERALIZED
More informationNUMBER SYSTEMS CHAPTER 191
NUMBER SYSTEMS 19.1 The Decimal System 19. The Binary System 19.3 Converting between Binary and Decimal Integers Fractions 19.4 Hexadecimal Notation 19.5 Key Terms and Problems CHAPTER 191 19 CHAPTER
More informationMerge Sort and Recurrences. COSC 581, Algorithms January 14, 2014
Merge Sort and Recurrences COSC 581, Algorithms January 14, 2014 Reading Assignments Today s class: Chapter 2, 4.0, 4.4 Reading assignment for next class: Chapter 4.2, 4.5 3 Common Algorithmic Techniques
More informationDefinition: String concatenation. Definition: String. Definition: Language (cont.) Definition: Language
CMSC 330: Organization of Programming Languages Regular Expressions and Finite Automata Introduction That s it for the basics of Ruby If you need other material for your project, come to office hours or
More informationA note on properties for a complementary graph and its tree graph
A note on properties for a complementary graph and its tree graph Abulimiti Yiming Department of Mathematics Institute of Mathematics & Informations Xinjiang Normal University China Masami Yasuda Department
More informationMACM 101 Discrete Mathematics I
MACM 101 Discrete Mathematics I Exercises on Combinatorics, Probability, Languages and Integers. Due: Tuesday, November 2th (at the beginning of the class) Reminder: the work you submit must be your own.
More informationGenetic programming with regular expressions
Genetic programming with regular expressions Børge Svingen Chief Technology Officer, Open AdExchange bsvingen@openadex.com 20090323 Pattern discovery Pattern discovery: Recognizing patterns that characterize
More informationComputer Science Department. Technion  IIT, Haifa, Israel. Itai and Rodeh [IR] have proved that for any 2connected graph G and any vertex s G there
 1  THREE TREEPATHS Avram Zehavi Alon Itai Computer Science Department Technion  IIT, Haifa, Israel Abstract Itai and Rodeh [IR] have proved that for any 2connected graph G and any vertex s G there
More information3.2 The Factor Theorem and The Remainder Theorem
3. The Factor Theorem and The Remainder Theorem 57 3. The Factor Theorem and The Remainder Theorem Suppose we wish to find the zeros of f(x) = x 3 + 4x 5x 4. Setting f(x) = 0 results in the polynomial
More informationSHARP BOUNDS FOR THE SUM OF THE SQUARES OF THE DEGREES OF A GRAPH
31 Kragujevac J. Math. 25 (2003) 31 49. SHARP BOUNDS FOR THE SUM OF THE SQUARES OF THE DEGREES OF A GRAPH Kinkar Ch. Das Department of Mathematics, Indian Institute of Technology, Kharagpur 721302, W.B.,
More informationProblem Set #1 Solutions
CS161: Design and Analysis of Algorithms Summer 2004 Problem Set #1 Solutions General Notes Regrade Policy: If you believe an error has been made in the grading of your problem set, you may resubmit it
More informationIn Chapter 1 we discussed the hierarchy of formal grammars proposed by
Chapter 3 ATTRIBUTE GRAMMARS In Chapter 1 we discussed the hierarchy of formal grammars proposed by Noam Chomsky. We mentioned that contextsensitive conditions, such as ensuring the same value for n in
More informationGrammars with Regulated Rewriting
Grammars with Regulated Rewriting Jürgen Dassow OttovonGuerickeUniversität Magdeburg Fakultät für Informatik Lecture in the 5 th PhD Program Formal Languages and Applications PhD Program Formal Languages
More informationA ixedpoint Approach towards Efficient Models Conversion
A ixedpoint Approach towards Efficient Models Conversion S,. Andrei, H. Koh Key Words: Pushdown automaton contextfree grammar conversion fixedpoint approach. Abstract. ormal languages have different
More informationDynamic Cognitive Modeling IV
Dynamic Cognitive Modeling IV CLS2010  Computational Linguistics Summer Events University of Zadar 23.08.2010 27.08.2010 Department of German Language and Linguistics Humboldt Universität zu Berlin Overview
More information