ɛ-closure, Kleene s Theorem,

Size: px
Start display at page:

Download "ɛ-closure, Kleene s Theorem,"

Transcription

1 DEGefWb5wiGH2XgYMEzUKajEmtCDUsRQ4d 1 A nice paper relevant to this course is titled The Glory of the Past 2 NICTA Researcher, Adjunct at the Australian National University and Griffith University ɛ-closure, Kleene s Theorem, and Kleene s Algebra Charles Gretton 2 24 February 2014 NICTA Funding and Supporting Members and Partners Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 1/30

2 First, a Quick Summary of ɛ-closure I ve previously waived my hands about ɛ-labelled arcs. Recall, ɛ is our notation for the empty string. How can we formally treat ɛ-labelled arcs in an NFA? Using a function called ECLOSE... A construction similar to that for NFA DFA is used to prove ɛ-nfa DFA Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 2/30

3 Quick Summary of ɛ-closure ɛ-nfa is Q, Σ, δ, q 0, F. ECLOSE : Q 2 Q i.e. gives an element in the powerset of states. It is defined inductively, as follows. BASIS: q ECLOSE(q) i.e. the argument is in the basis. INDUCTION: Suppose p ECLOSE(q) and r δ(p, ɛ), then r ECLOSE(q). Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 3/30

4 Quick Example of ɛ-closure ECLOSE : Q 2 Q i.e. gives an element in the powerset of states. It is defined inductively, as follows. BASIS: q ECLOSE(q) i.e. the argument is in the basis. INDUCTION: Suppose p ECLOSE(q) and r δ(p, ɛ), then r ECLOSE(q).??? Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 4/30

5 Quick Example of ɛ-closure ECLOSE : Q 2 Q i.e. gives an element in the powerset of states. It is defined inductively, as follows. BASIS: q ECLOSE(q) i.e. the argument is in the basis. INDUCTION: Suppose p ECLOSE(q) and r δ(p, ɛ), then r ECLOSE(q). ECLOSE(1) = {1, 2, 3, 4, 6} Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 5/30

6 ɛ-closure Subset Construction For DFA ɛ-nfa, just add δ(q, ɛ) = transitions to all states i.e. ɛ is not an alphabet symbol. ɛ-nfa DFA Same as for NFA DFA, Each DFA state corresponds to a unique set of ɛ-nfa states. Only take the ɛ-closure at ɛ-nfa transitions. Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 6/30

7 Summarizing NFA DFA The equivalent NFA can be exponentially smaller than the corresponding DFA. ɛ-nfa DFA From transitivity: ɛ-nfa NFA All formalisms so far are expressively equivalent. Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 7/30

8 Languages and Regular Expressions Regular expression implementations in many UNIX tools: grep, sed, awk, emacs and vi Following Kleene s seminal work, we deal with regularity formally. We describe the language intended by a given regular expression. We consider the class of languages that can be expressed. We examine algebraic laws which inform re-writing rules for simplifying expressions. Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 8/30

9 Operations on Languages L 1, L 2 Σ product of languages inductive i th product L 1.L 2 = L 1 L 2 = {WX W L 1, X L 2 } positive closure L 0 = {ɛ} i > 0, L i = LL i 1 L = i 0 Li L + = LL Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 9/30

10 Regular Expressions A regular expression is a well formed word over a given alphabet Σ We use the following symbols: Σ {ɛ ( ) +. } alphabet empty string empty set open parenthesis close parenthesis union or choice concatenation X.Y often written as XY Kleene closure the star of this show Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 10/30

11 Regular Expressions A regular expression is a well formed word over a given alphabet Σ We use the following symbols: Σ {ɛ ( ) +. } symbol :: alphabet constant (or 0-ary operator) :: empty string constant (or 0-ary operator) :: empty set punctuation :: open parenthesis punctuation :: close parenthesis infix binary operator :: union or choice infix binary operator :: concatenation X.Y often written as XY postfix unary operator :: Kleene closure the star of this show Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 11/30

12 Regular Expressions We use the following symbols: Σ {ɛ ( ) +. } Taking a Σ {ɛ, }, regular expressions satisfy the following grammar: regxp ::= a (regxp) regxp + regxp regxp.regxp regxp The Kleene closure operator, *, has the highest precedence. Concatenation,., is usually represented by juxtaposition e.g. concatenation a.b is written ab Concatenation has the next highest precedence. Union/choice has the least precedence. Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 12/30

13 Regular Expression Examples Taking a Σ {ɛ, }, regular expressions satisfy the following grammar: regxp ::= a (regxp) regxp + regxp regxp.regxp regxp So, which of the following is correct? ab + a = (a(b + a)) ab + a = (ab) + a ab + a = (a(b )) + a Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 13/30

14 Regular Expression Examples Taking a Σ {ɛ, }, regular expressions satisfy the following grammar: regxp ::= a (regxp) regxp + regxp regxp.regxp regxp So, which of the following is correct? ab + a = (a(b + a)) ab + a = (ab) + a ab + a = (a(b )) + a Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 14/30

15 Semantics of Regular Expressions BASIS Language of Expression Semantics L(ɛ) = {ɛ} L( ) = L(a), a Σ = {a} INDUCTION Below, L 1 and L 2 are well formed regular expressions. Language of Expression Semantics L(L 1 + L 2 ) = L(L 1 ) L(L 2 ) L(L 1 L 2 ) = L(L 1 )L(L 2 ) L(L 1 ) = L(L 1) L((L 1 )) = L(L 1 ) Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 15/30

16 Every Finite Language is Regular A regular language is a language that can be given by a regular expression. A finite language is a finite set of strings: {X 1, X 2,.., X n } The regular expression that gives that finite language is: X 1 + X X n QED Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 16/30

17 Algebra and Regular Expressions Commutativity laws: L 1 + L 2 = L 2 + L 1 Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 17/30

18 Algebra and Regular Expressions Cancellation laws: Identities Annihilators L + = L + L = L ɛl = L Lɛ = L L = L = Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 18/30

19 Algebra and Regular Expressions Associative laws: L 1 + (L 2 + L 3 ) = (L 1 + L 2 ) + L 3 L 1 (L 2 L 3 ) = (L 1 L 2 )L 3 Power associativity L 1 (L 1 L 1 ) = (L 1 L 1 )L (L 1 L 1 )(L 1 L 1 ) = (L 1 (L 1 L 1 ))L 1 Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 19/30

20 Algebra and Regular Expressions Left and right distributive laws: L 1 (L 2 + L 3 ) = L 1 L 2 + L 1 L 3 (L 2 + L 3 )L 1 = L 2 L 1 + L 3 L 1 Idempotence: L + L = L Closure laws There are exactly two languages whose closures are finite. What are they? Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 20/30

21 Algebra and Regular Expressions Left and right distributive laws: Idempotence: L 1 (L 2 + L 3 ) = L 1 L 2 + L 1 L 3 (L 2 + L 3 )L 1 = L 2 L 1 + L 3 L 1 Closure laws L + L = L ɛ = ɛ = ɛ (L ) = L Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 21/30

22 Application of Algebraic Laws a + ab precedence: (a + (a(b ))) annihilators: (aɛ + (a(b ))) left distributive law: a(ɛ + b ) cancellation law: a(b ) CONCLUSION: ab = a + ab Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 22/30

23 Relating Concrete and Lifted Expressions When I write (L ) = L, I intended that L could be any regular expression. For example, the following concrete expressions are instances of this identity. 1 ((a) ) = a 2 ((ɛ(a + bab + ) + bab) ) = (ɛ(a + bab + ) + bab) The above are called concrete regular expressions, because they contain no variables. Our textbook talks about a specific class of concrete expression (above, Type 1), where each variable symbol from the lifted expression is replaced with an alphabet constant. Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 23/30

24 Theorem Relating Concrete and Lifted Expressions Let E be a regular expression with variable symbols L i, i [1..m]. For example taking m = 2, E could be (L 1 + L 2 ), (L 1 L 2 ), etc Let E be an expression where each variable L i is replaced by a constant a i. Every X L(E) can be written as X 1 X 2..X k, where each substring X j is in one of the languages L(L i ). Writing L(X j ) = i if X j is from the i th language, a L(X1 )a L(X2 )..a L(Xk ) L(E ) Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 24/30

25 Theorem Relating Concrete and Lifted Expressions BASIS: E {ɛ,, L 1 }. The cases E {ɛ, } are trivial, because the concrete and lifted expressions are identical. Taking E = L 1, then L(E) = L(L 1 ). Also E = a 1 and L(E ) = L(a 1 ) = {a 1 }. Above, the L 1 /a 1 correspondence is clearly satisfied. Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 25/30

26 Theorem Relating Concrete and Lifted Expressions INDUCTION: E {E 1 + E 2, E 1 E 2, E 1 }. E 1 and E 2 are constructed so that if a variable appears in both subexpressions, then that is substituted with the same concrete symbol. For example, take E = L 1 L 2 + L 2 L 1. Then a valid concrete expression is: E = a 1 a 2 + a 2 a 1. An invalid concrete expression would be: E = a 1 a 2 + a 3 a 4. Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 26/30

27 Theorem Relating Concrete and Lifted Expressions INDUCTION: E {E 1 + E 2, E 1 E 2, E 1 }. E 1 and E 2 are constructed so that if a variable appears in both subexpressions, then that is substituted with the same concrete symbol. L(E ) = L(E 1 + E 2 ) = L(E 1 ) L(E 2 ) L(E) = L(E 1 + E 2 ) = L(E 1 ) L(E 2 ) Our inductive hypothesis gives us the correspondence for strings in L(E 1 )/L(E 1 ). Also for strings in L(E 2 )/L(E 2 ). Following the definition of union, we have proved this step case. Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 27/30

28 Theorem Relating Concrete and Lifted Expressions INDUCTION: E {E 1 + E 2, E 1 E 2, E 1 }. E 1 and E 2 are constructed so that if a variable appears in both subexpressions, then that is substituted with the same concrete symbol. L(E ) = L(E 1.E 2 ) = L(E 1 ).L(E 2 ) L(E) = L(E 1.E 2 ) = L(E 1 ).L(E 2 ) Our inductive hypothesis gives us the correspondence for strings in L(E 1 )/L(E 1 ). Also for strings in L(E 2 )/L(E 2 ). Following the definition of concatenation, we have proved this step case. Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 28/30

29 Theorem Relating Concrete and Lifted Expressions INDUCTION: E {E 1 + E 2, E 1 E 2, E 1 }. L((E 1 ) ) = L(ɛ) L(E 1 )+ L(E 1 ) = L(ɛ) L(E 1) + Our inductive hypothesis gives us the correspondence for strings in L(E 1 )/L(E 1 ). Because closure yields zero or more occurrences of the language strings, we also have a correspondence between L(E 1 ) /L(E 1 ). QED Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 29/30

30 Theorem Relating Concrete and Lifted Expressions What if we added to the step cases: E {E 1 E 2, E 1 + E 2, E 1 E 2, E 1 }? Let s propose a law L 1 L 2 L 3 = L 1 L 2 The law holds for a concretization: L(a b c) = L(a b) = But fails generally: L(a a ) L(a a) So, the theorem we just proved is rather specific to regular expressions. Kleene s Theorem Copyright NICTA 2014 Charles Gretton 2 30/30

C H A P T E R Regular Expressions regular expression

C H A P T E R Regular Expressions regular expression 7 CHAPTER Regular Expressions Most programmers and other power-users of computer systems have used tools that match text patterns. You may have used a Web search engine with a pattern like travel cancun

More information

Formal Languages and Automata Theory - Regular Expressions and Finite Automata -

Formal 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 information

6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, 2010. Class 4 Nancy Lynch

6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, 2010. Class 4 Nancy Lynch 6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, 2010 Class 4 Nancy Lynch Today Two more models of computation: Nondeterministic Finite Automata (NFAs)

More information

Lecture 2: Regular Languages [Fa 14]

Lecture 2: Regular Languages [Fa 14] Caveat lector: This is the first edition of this lecture note. Please send bug reports and suggestions to jeffe@illinois.edu. But the Lord came down to see the city and the tower the people were building.

More information

Automata and Formal Languages

Automata and Formal Languages Automata and Formal Languages Winter 2009-2010 Yacov Hel-Or 1 What this course is all about This course is about mathematical models of computation We ll study different machine models (finite automata,

More information

Finite Automata. Reading: Chapter 2

Finite Automata. Reading: Chapter 2 Finite Automata Reading: Chapter 2 1 Finite Automaton (FA) Informally, a state diagram that comprehensively captures all possible states and transitions that a machine can take while responding to a stream

More information

Lecture 18 Regular Expressions

Lecture 18 Regular Expressions Lecture 18 Regular Expressions Many of today s web applications require matching patterns in a text document to look for specific information. A good example is parsing a html file to extract tags

More information

Finite Automata. Reading: Chapter 2

Finite Automata. Reading: Chapter 2 Finite Automata Reading: Chapter 2 1 Finite Automata Informally, a state machine that comprehensively captures all possible states and transitions that a machine can take while responding to a stream (or

More information

CS103B Handout 17 Winter 2007 February 26, 2007 Languages and Regular Expressions

CS103B Handout 17 Winter 2007 February 26, 2007 Languages and Regular Expressions CS103B Handout 17 Winter 2007 February 26, 2007 Languages and Regular Expressions Theory of Formal Languages In the English language, we distinguish between three different identities: letter, word, sentence.

More information

Scanner. tokens scanner parser IR. source code. errors

Scanner. tokens scanner parser IR. source code. errors Scanner source code tokens scanner parser IR errors maps characters into tokens the basic unit of syntax x = x + y; becomes = + ; character string value for a token is a lexeme

More information

Reading 13 : Finite State Automata and Regular Expressions

Reading 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 information

Regular Expressions and Automata using Haskell

Regular Expressions and Automata using Haskell Regular Expressions and Automata using Haskell Simon Thompson Computing Laboratory University of Kent at Canterbury January 2000 Contents 1 Introduction 2 2 Regular Expressions 2 3 Matching regular expressions

More information

Full and Complete Binary Trees

Full and Complete Binary Trees Full and Complete Binary Trees Binary Tree Theorems 1 Here are two important types of binary trees. Note that the definitions, while similar, are logically independent. Definition: a binary tree T is full

More information

Regular Expressions with Nested Levels of Back Referencing Form a Hierarchy

Regular 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 information

CONTENTS 1. Peter Kahn. Spring 2007

CONTENTS 1. Peter Kahn. Spring 2007 CONTENTS 1 MATH 304: CONSTRUCTING THE REAL NUMBERS Peter Kahn Spring 2007 Contents 2 The Integers 1 2.1 The basic construction.......................... 1 2.2 Adding integers..............................

More information

Automata on Infinite Words and Trees

Automata on Infinite Words and Trees Automata on Infinite Words and Trees Course notes for the course Automata on Infinite Words and Trees given by Dr. Meghyn Bienvenu at Universität Bremen in the 2009-2010 winter semester Last modified:

More information

Automata Theory. Şubat 2006 Tuğrul Yılmaz Ankara Üniversitesi

Automata Theory. Şubat 2006 Tuğrul Yılmaz Ankara Üniversitesi Automata Theory Automata theory is the study of abstract computing devices. A. M. Turing studied an abstract machine that had all the capabilities of today s computers. Turing s goal was to describe the

More information

CMPSCI 250: Introduction to Computation. Lecture #19: Regular Expressions and Their Languages David Mix Barrington 11 April 2013

CMPSCI 250: Introduction to Computation. Lecture #19: Regular Expressions and Their Languages David Mix Barrington 11 April 2013 CMPSCI 250: Introduction to Computation Lecture #19: Regular Expressions and Their Languages David Mix Barrington 11 April 2013 Regular Expressions and Their Languages Alphabets, Strings and Languages

More information

Pushdown 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. 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 Context-free languages are defined by context-free

More information

2110711 THEORY of COMPUTATION

2110711 THEORY of COMPUTATION 2110711 THEORY of COMPUTATION ATHASIT SURARERKS ELITE Athasit Surarerks ELITE Engineering Laboratory in Theoretical Enumerable System Computer Engineering, Faculty of Engineering Chulalongkorn University

More information

Fundamentele Informatica II

Fundamentele Informatica II Fundamentele Informatica II Answer to selected exercises 1 John C Martin: Introduction to Languages and the Theory of Computation M.M. Bonsangue (and J. Kleijn) Fall 2011 Let L be a language. It is clear

More information

8 Divisibility and prime numbers

8 Divisibility and prime numbers 8 Divisibility and prime numbers 8.1 Divisibility In this short section we extend the concept of a multiple from the natural numbers to the integers. We also summarize several other terms that express

More information

Finite Automata and Regular Languages

Finite Automata and Regular Languages CHAPTER 3 Finite Automata and Regular Languages 3. Introduction 3.. States and Automata A finite-state machine or finite automaton (the noun comes from the Greek; the singular is automaton, the Greek-derived

More information

Regular Languages and Finite Automata

Regular Languages and Finite Automata Regular Languages and Finite Automata 1 Introduction Hing Leung Department of Computer Science New Mexico State University Sep 16, 2010 In 1943, McCulloch and Pitts [4] published a pioneering work on a

More information

Compiler Construction

Compiler Construction Compiler Construction Regular expressions Scanning Görel Hedin Reviderad 2013 01 23.a 2013 Compiler Construction 2013 F02-1 Compiler overview source code lexical analysis tokens intermediate code generation

More information

The Halting Problem is Undecidable

The Halting Problem is Undecidable 185 Corollary G = { M, w w L(M) } is not Turing-recognizable. 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 information

CS 3719 (Theory of Computation and Algorithms) Lecture 4

CS 3719 (Theory of Computation and Algorithms) Lecture 4 CS 3719 (Theory of Computation and Algorithms) Lecture 4 Antonina Kolokolova January 18, 2012 1 Undecidable languages 1.1 Church-Turing thesis Let s recap how it all started. In 1990, Hilbert stated a

More information

Chapter 3. Cartesian Products and Relations. 3.1 Cartesian Products

Chapter 3. Cartesian Products and Relations. 3.1 Cartesian Products Chapter 3 Cartesian Products and Relations The material in this chapter is the first real encounter with abstraction. Relations are very general thing they are a special type of subset. After introducing

More information

Deterministic Finite Automata

Deterministic Finite Automata 1 Deterministic Finite Automata Definition: A deterministic finite automaton (DFA) consists of 1. a finite set of states (often denoted Q) 2. a finite set Σ of symbols (alphabet) 3. a transition function

More information

(IALC, Chapters 8 and 9) Introduction to Turing s life, Turing machines, universal machines, unsolvable problems.

(IALC, Chapters 8 and 9) Introduction to Turing s life, Turing machines, universal machines, unsolvable problems. 3130CIT: Theory of Computation Turing machines and undecidability (IALC, Chapters 8 and 9) Introduction to Turing s life, Turing machines, universal machines, unsolvable problems. An undecidable problem

More information

A Little Set Theory (Never Hurt Anybody)

A Little Set Theory (Never Hurt Anybody) A Little Set Theory (Never Hurt Anybody) Matthew Saltzman Department of Mathematical Sciences Clemson University Draft: August 21, 2013 1 Introduction The fundamental ideas of set theory and the algebra

More information

26 Integers: Multiplication, Division, and Order

26 Integers: Multiplication, Division, and Order 26 Integers: Multiplication, Division, and Order Integer multiplication and division are extensions of whole number multiplication and division. In multiplying and dividing integers, the one new issue

More information

Regular Languages and Finite Automata

Regular Languages and Finite Automata Regular Languages and Finite Automata A C Norman, Lent Term 1996 Part IA 1 Introduction This course is short, but it is present in Part 1A because of the way it introduces links between many different

More information

Informatique Fondamentale IMA S8

Informatique Fondamentale IMA S8 Informatique Fondamentale IMA S8 Cours 1 - Intro + schedule + finite state machines Laure Gonnord http://laure.gonnord.org/pro/teaching/ Laure.Gonnord@polytech-lille.fr Université Lille 1 - Polytech Lille

More information

Practice with Proofs

Practice with Proofs Practice with Proofs October 6, 2014 Recall the following Definition 0.1. A function f is increasing if for every x, y in the domain of f, x < y = f(x) < f(y) 1. Prove that h(x) = x 3 is increasing, using

More information

Preventing Denial of Service Attacks in a Calculus of Mobile Resources

Preventing Denial of Service Attacks in a Calculus of Mobile Resources Preventing Denial of Service Attacks in a Calculus of Mobile Resources Bilge Hösükoǧlu, David Sánchez Hernández, Julian Driver June 1, 2006 Abstract In this paper we introduce membranes for the calculus

More information

So let us begin our quest to find the holy grail of real analysis.

So let us begin our quest to find the holy grail of real analysis. 1 Section 5.2 The Complete Ordered Field: Purpose of Section We present an axiomatic description of the real numbers as a complete ordered field. The axioms which describe the arithmetic of the real numbers

More information

(0, 0) : order 1; (0, 1) : order 4; (0, 2) : order 2; (0, 3) : order 4; (1, 0) : order 2; (1, 1) : order 4; (1, 2) : order 2; (1, 3) : order 4.

(0, 0) : order 1; (0, 1) : order 4; (0, 2) : order 2; (0, 3) : order 4; (1, 0) : order 2; (1, 1) : order 4; (1, 2) : order 2; (1, 3) : order 4. 11.01 List the elements of Z 2 Z 4. Find the order of each of the elements is this group cyclic? Solution: The elements of Z 2 Z 4 are: (0, 0) : order 1; (0, 1) : order 4; (0, 2) : order 2; (0, 3) : order

More information

Algebraic expressions are a combination of numbers and variables. Here are examples of some basic algebraic expressions.

Algebraic expressions are a combination of numbers and variables. Here are examples of some basic algebraic expressions. Page 1 of 13 Review of Linear Expressions and Equations Skills involving linear equations can be divided into the following groups: Simplifying algebraic expressions. Linear expressions. Solving linear

More information

1. Prove that the empty set is a subset of every set.

1. Prove that the empty set is a subset of every set. 1. Prove that the empty set is a subset of every set. Basic Topology Written by Men-Gen Tsai email: b89902089@ntu.edu.tw Proof: For any element x of the empty set, x is also an element of every set since

More information

MATH 22. THE FUNDAMENTAL THEOREM of ARITHMETIC. Lecture R: 10/30/2003

MATH 22. THE FUNDAMENTAL THEOREM of ARITHMETIC. Lecture R: 10/30/2003 MATH 22 Lecture R: 10/30/2003 THE FUNDAMENTAL THEOREM of ARITHMETIC You must remember this, A kiss is still a kiss, A sigh is just a sigh; The fundamental things apply, As time goes by. Herman Hupfeld

More information

Mathematical Induction

Mathematical 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 information

Row Echelon Form and Reduced Row Echelon Form

Row Echelon Form and Reduced Row Echelon Form These notes closely follow the presentation of the material given in David C Lay s textbook Linear Algebra and its Applications (3rd edition) These notes are intended primarily for in-class presentation

More information

Properties of Real Numbers

Properties of Real Numbers 16 Chapter P Prerequisites P.2 Properties of Real Numbers What you should learn: Identify and use the basic properties of real numbers Develop and use additional properties of real numbers Why you should

More information

If n is odd, then 3n + 7 is even.

If n is odd, then 3n + 7 is even. Proof: Proof: We suppose... that 3n + 7 is even. that 3n + 7 is even. Since n is odd, there exists an integer k so that n = 2k + 1. that 3n + 7 is even. Since n is odd, there exists an integer k so that

More information

Math 223 Abstract Algebra Lecture Notes

Math 223 Abstract Algebra Lecture Notes Math 223 Abstract Algebra Lecture Notes Steven Tschantz Spring 2001 (Apr. 23 version) Preamble These notes are intended to supplement the lectures and make up for the lack of a textbook for the course

More information

CS154. Turing Machines. Turing Machine. Turing Machines versus DFAs FINITE STATE CONTROL AI N P U T INFINITE TAPE. read write move.

CS154. Turing Machines. Turing Machine. Turing Machines versus DFAs FINITE STATE CONTROL AI N P U T INFINITE TAPE. read write move. CS54 Turing Machines Turing Machine q 0 AI N P U T IN TAPE read write move read write move Language = {0} q This Turing machine recognizes the language {0} Turing Machines versus DFAs TM can both write

More information

Lecture I FINITE AUTOMATA

Lecture I FINITE AUTOMATA 1. Regular Sets and DFA Lecture I Page 1 Lecture I FINITE AUTOMATA Lecture 1: Honors Theory, Spring 02, Yap We introduce finite automata (deterministic and nondeterministic) and regular languages. Some

More information

Sample Induction Proofs

Sample Induction Proofs Math 3 Worksheet: Induction Proofs III, Sample Proofs A.J. Hildebrand Sample Induction Proofs Below are model solutions to some of the practice problems on the induction worksheets. The solutions given

More information

Cartesian Products and Relations

Cartesian Products and Relations Cartesian Products and Relations Definition (Cartesian product) If A and B are sets, the Cartesian product of A and B is the set A B = {(a, b) :(a A) and (b B)}. The following points are worth special

More information

Introduction to Automata Theory. Reading: Chapter 1

Introduction 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 information

ω-automata Automata that accept (or reject) words of infinite length. Languages of infinite words appear:

ω-automata Automata that accept (or reject) words of infinite length. Languages of infinite words appear: ω-automata ω-automata Automata that accept (or reject) words of infinite length. Languages of infinite words appear: in verification, as encodings of non-terminating executions of a program. in arithmetic,

More information

CS5236 Advanced Automata Theory

CS5236 Advanced Automata Theory CS5236 Advanced Automata Theory Frank Stephan Semester I, Academic Year 2012-2013 Advanced Automata Theory is a lecture which will first review the basics of formal languages and automata theory and then

More information

Notes on Algebraic Structures. Peter J. Cameron

Notes on Algebraic Structures. Peter J. Cameron Notes on Algebraic Structures Peter J. Cameron ii Preface These are the notes of the second-year course Algebraic Structures I at Queen Mary, University of London, as I taught it in the second semester

More information

Regular Languages and Finite State Machines

Regular Languages and Finite State Machines Regular Languages and Finite State Machines Plan for the Day: Mathematical preliminaries - some review One application formal definition of finite automata Examples 1 Sets A set is an unordered collection

More information

We can express this in decimal notation (in contrast to the underline notation we have been using) as follows: 9081 + 900b + 90c = 9001 + 100c + 10b

We can express this in decimal notation (in contrast to the underline notation we have been using) as follows: 9081 + 900b + 90c = 9001 + 100c + 10b In this session, we ll learn how to solve problems related to place value. This is one of the fundamental concepts in arithmetic, something every elementary and middle school mathematics teacher should

More information

MACM 101 Discrete Mathematics I

MACM 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 information

9.2 Summation Notation

9.2 Summation Notation 9. Summation Notation 66 9. Summation Notation In the previous section, we introduced sequences and now we shall present notation and theorems concerning the sum of terms of a sequence. We begin with a

More information

ML-Flex Implementation Notes

ML-Flex Implementation Notes ML-Flex Implementation Notes Aaron Turon adrassi@uchicago.edu February 17, 2006 Contents 1 Organization 2 2 Theory 3 2.1 Regular expressions................................ 3 2.2 Derivatives.....................................

More information

Mathematics for Computer Science/Software Engineering. Notes for the course MSM1F3 Dr. R. A. Wilson

Mathematics for Computer Science/Software Engineering. Notes for the course MSM1F3 Dr. R. A. Wilson Mathematics for Computer Science/Software Engineering Notes for the course MSM1F3 Dr. R. A. Wilson October 1996 Chapter 1 Logic Lecture no. 1. We introduce the concept of a proposition, which is a statement

More information

3515ICT Theory of Computation Turing Machines

3515ICT 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) 9-0 Overview Turing machines: a general model of computation

More information

Catalan Numbers. Thomas A. Dowling, Department of Mathematics, Ohio State Uni- versity.

Catalan Numbers. Thomas A. Dowling, Department of Mathematics, Ohio State Uni- versity. 7 Catalan Numbers Thomas A. Dowling, Department of Mathematics, Ohio State Uni- Author: versity. Prerequisites: The prerequisites for this chapter are recursive definitions, basic counting principles,

More information

Answer Key for California State Standards: Algebra I

Answer Key for California State Standards: Algebra I Algebra I: Symbolic reasoning and calculations with symbols are central in algebra. Through the study of algebra, a student develops an understanding of the symbolic language of mathematics and the sciences.

More information

WHAT ARE MATHEMATICAL PROOFS AND WHY THEY ARE IMPORTANT?

WHAT ARE MATHEMATICAL PROOFS AND WHY THEY ARE IMPORTANT? WHAT ARE MATHEMATICAL PROOFS AND WHY THEY ARE IMPORTANT? introduction Many students seem to have trouble with the notion of a mathematical proof. People that come to a course like Math 216, who certainly

More information

CSE 135: Introduction to Theory of Computation Decidability and Recognizability

CSE 135: Introduction to Theory of Computation Decidability and Recognizability CSE 135: Introduction to Theory of Computation Decidability and Recognizability Sungjin Im University of California, Merced 04-28, 30-2014 High-Level Descriptions of Computation Instead of giving a Turing

More information

Kevin James. MTHSC 412 Section 2.4 Prime Factors and Greatest Comm

Kevin James. MTHSC 412 Section 2.4 Prime Factors and Greatest Comm MTHSC 412 Section 2.4 Prime Factors and Greatest Common Divisor Greatest Common Divisor Definition Suppose that a, b Z. Then we say that d Z is a greatest common divisor (gcd) of a and b if the following

More information

Lights and Darks of the Star-Free Star

Lights and Darks of the Star-Free Star Lights and Darks of the Star-Free Star Edward Ochmański & Krystyna Stawikowska Nicolaus Copernicus University, Toruń, Poland Introduction: star may destroy recognizability In (finitely generated) trace

More information

ASSIGNMENT ONE SOLUTIONS MATH 4805 / COMP 4805 / MATH 5605

ASSIGNMENT ONE SOLUTIONS MATH 4805 / COMP 4805 / MATH 5605 ASSIGNMENT ONE SOLUTIONS MATH 4805 / COMP 4805 / MATH 5605 (1) (a) (0 + 1) 010 (finite automata below). (b) First observe that the following regular expression generates the binary strings with an even

More information

Automata and Computability. Solutions to Exercises

Automata 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 information

MATH10212 Linear Algebra. Systems of Linear Equations. Definition. An n-dimensional vector is a row or a column of n numbers (or letters): a 1.

MATH10212 Linear Algebra. Systems of Linear Equations. Definition. An n-dimensional 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 0-534-40596-7. Systems of Linear Equations Definition. An n-dimensional vector is a row or a column

More information

3. Mathematical Induction

3. Mathematical Induction 3. MATHEMATICAL INDUCTION 83 3. Mathematical Induction 3.1. First Principle of Mathematical Induction. Let P (n) be a predicate with domain of discourse (over) the natural numbers N = {0, 1,,...}. If (1)

More information

o-minimality and Uniformity in n 1 Graphs

o-minimality and Uniformity in n 1 Graphs o-minimality and Uniformity in n 1 Graphs Reid Dale July 10, 2013 Contents 1 Introduction 2 2 Languages and Structures 2 3 Definability and Tame Geometry 4 4 Applications to n 1 Graphs 6 5 Further Directions

More information

Student Outcomes. Lesson Notes. Classwork. Discussion (10 minutes)

Student Outcomes. Lesson Notes. Classwork. Discussion (10 minutes) NYS COMMON CORE MATHEMATICS CURRICULUM Lesson 5 8 Student Outcomes Students know the definition of a number raised to a negative exponent. Students simplify and write equivalent expressions that contain

More information

The Set Data Model CHAPTER 7. 7.1 What This Chapter Is About

The Set Data Model CHAPTER 7. 7.1 What This Chapter Is About CHAPTER 7 The Set Data Model The set is the most fundamental data model of mathematics. Every concept in mathematics, from trees to real numbers, is expressible as a special kind of set. In this book,

More information

Correspondence analysis for strong three-valued logic

Correspondence analysis for strong three-valued logic Correspondence analysis for strong three-valued logic A. Tamminga abstract. I apply Kooi and Tamminga s (2012) idea of correspondence analysis for many-valued logics to strong three-valued logic (K 3 ).

More information

Data Structures and Algorithms V22.0102. Otávio Braga

Data Structures and Algorithms V22.0102. Otávio Braga Data Structures and Algorithms V22.0102 Otávio Braga We use a stack When an operand is read, output it When an operator is read Pop until the top of the stack has an element of lower precedence Then push

More information

CPS 140 - Mathematical Foundations of CS Dr. S. Rodger Section: Properties of Context-Free 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 information

How To Know If A Domain Is Unique In An Octempo (Euclidean) Or Not (Ecl)

How To Know If A Domain Is Unique In An Octempo (Euclidean) Or Not (Ecl) Subsets of Euclidean domains possessing a unique division algorithm Andrew D. Lewis 2009/03/16 Abstract Subsets of a Euclidean domain are characterised with the following objectives: (1) ensuring uniqueness

More information

Lecture 1: Course overview, circuits, and formulas

Lecture 1: Course overview, circuits, and formulas Lecture 1: Course overview, circuits, and formulas Topics in Complexity Theory and Pseudorandomness (Spring 2013) Rutgers University Swastik Kopparty Scribes: John Kim, Ben Lund 1 Course Information Swastik

More information

Aikaterini Marazopoulou

Aikaterini Marazopoulou Imperial College London Department of Computing Tableau Compiled Labelled Deductive Systems with an application to Description Logics by Aikaterini Marazopoulou Submitted in partial fulfilment of the requirements

More information

Continued Fractions and the Euclidean Algorithm

Continued Fractions and the Euclidean Algorithm Continued Fractions and the Euclidean Algorithm Lecture notes prepared for MATH 326, Spring 997 Department of Mathematics and Statistics University at Albany William F Hammond Table of Contents Introduction

More information

Math 4310 Handout - Quotient Vector Spaces

Math 4310 Handout - Quotient Vector Spaces Math 4310 Handout - Quotient Vector Spaces Dan Collins The textbook defines a subspace of a vector space in Chapter 4, but it avoids ever discussing the notion of a quotient space. This is understandable

More information

Click on the links below to jump directly to the relevant section

Click on the links below to jump directly to the relevant section Click on the links below to jump directly to the relevant section What is algebra? Operations with algebraic terms Mathematical properties of real numbers Order of operations What is Algebra? Algebra is

More information

Vector Math Computer Graphics Scott D. Anderson

Vector Math Computer Graphics Scott D. Anderson Vector Math Computer Graphics Scott D. Anderson 1 Dot Product The notation v w means the dot product or scalar product or inner product of two vectors, v and w. In abstract mathematics, we can talk about

More information

Graph Theory Problems and Solutions

Graph Theory Problems and Solutions raph Theory Problems and Solutions Tom Davis tomrdavis@earthlink.net http://www.geometer.org/mathcircles November, 005 Problems. Prove that the sum of the degrees of the vertices of any finite graph is

More information

Lexical analysis FORMAL LANGUAGES AND COMPILERS. Floriano Scioscia. Formal Languages and Compilers A.Y. 2015/2016

Lexical analysis FORMAL LANGUAGES AND COMPILERS. Floriano Scioscia. Formal Languages and Compilers A.Y. 2015/2016 Master s Degree Course in Computer Engineering Formal Languages FORMAL LANGUAGES AND COMPILERS Lexical analysis Floriano Scioscia 1 Introductive terminological distinction Lexical string or lexeme = meaningful

More information

CHAPTER 7 GENERAL PROOF SYSTEMS

CHAPTER 7 GENERAL PROOF SYSTEMS CHAPTER 7 GENERAL PROOF SYSTEMS 1 Introduction Proof systems are built to prove statements. They can be thought as an inference machine with special statements, called provable statements, or sometimes

More information

BEGINNING ALGEBRA ACKNOWLEDMENTS

BEGINNING ALGEBRA ACKNOWLEDMENTS BEGINNING ALGEBRA The Nursing Department of Labouré College requested the Department of Academic Planning and Support Services to help with mathematics preparatory materials for its Bachelor of Science

More information

CMCS 312: Programming Languages Lecture 3: Lambda Calculus (Syntax, Substitution, Beta Reduction) Acar & Ahmed 17 January 2008

CMCS 312: Programming Languages Lecture 3: Lambda Calculus (Syntax, Substitution, Beta Reduction) Acar & Ahmed 17 January 2008 CMCS 312: Programming Languages Lecture 3: Lambda Calculus (Syntax, Substitution, Beta Reduction) Acar & Ahmed 17 January 2008 Contents 1 Announcements 1 2 Introduction 1 3 Abstract Syntax 1 4 Bound and

More information

Algebraic Structures II

Algebraic Structures II MAS 305 Algebraic Structures II Notes 12 Autumn 2006 Factorization in integral domains Lemma If a, b, c are elements of an integral domain R and ab = ac then either a = 0 R or b = c. Proof ab = ac a(b

More information

The following themes form the major topics of this chapter: The terms and concepts related to trees (Section 5.2).

The following themes form the major topics of this chapter: The terms and concepts related to trees (Section 5.2). CHAPTER 5 The Tree Data Model There are many situations in which information has a hierarchical or nested structure like that found in family trees or organization charts. The abstraction that models hierarchical

More information

How To Compare A Markov Algorithm To A Turing Machine

How To Compare A Markov Algorithm To A Turing Machine Markov Algorithm CHEN Yuanmi December 18, 2007 1 Abstract Markov Algorithm can be understood as a priority string rewriting system. In this short paper we give the definition of Markov algorithm and also

More information

Indiana State Core Curriculum Standards updated 2009 Algebra I

Indiana State Core Curriculum Standards updated 2009 Algebra I Indiana State Core Curriculum Standards updated 2009 Algebra I Strand Description Boardworks High School Algebra presentations Operations With Real Numbers Linear Equations and A1.1 Students simplify and

More information

You know from calculus that functions play a fundamental role in mathematics.

You know from calculus that functions play a fundamental role in mathematics. CHPTER 12 Functions You know from calculus that functions play a fundamental role in mathematics. You likely view a function as a kind of formula that describes a relationship between two (or more) quantities.

More information

Undergraduate Notes in Mathematics. Arkansas Tech University Department of Mathematics

Undergraduate Notes in Mathematics. Arkansas Tech University Department of Mathematics Undergraduate Notes in Mathematics Arkansas Tech University Department of Mathematics An Introductory Single Variable Real Analysis: A Learning Approach through Problem Solving Marcel B. Finan c All Rights

More information

Logic in Computer Science: Logic Gates

Logic in Computer Science: Logic Gates Logic in Computer Science: Logic Gates Lila Kari The University of Western Ontario Logic in Computer Science: Logic Gates CS2209, Applied Logic for Computer Science 1 / 49 Logic and bit operations Computers

More information

Lecture 7: Continuous Random Variables

Lecture 7: Continuous Random Variables Lecture 7: Continuous Random Variables 21 September 2005 1 Our First Continuous Random Variable The back of the lecture hall is roughly 10 meters across. Suppose it were exactly 10 meters, and consider

More information

Lecture 17 : Equivalence and Order Relations DRAFT

Lecture 17 : Equivalence and Order Relations DRAFT CS/Math 240: Introduction to Discrete Mathematics 3/31/2011 Lecture 17 : Equivalence and Order Relations Instructor: Dieter van Melkebeek Scribe: Dalibor Zelený DRAFT Last lecture we introduced the notion

More information

MA651 Topology. Lecture 6. Separation Axioms.

MA651 Topology. Lecture 6. Separation Axioms. MA651 Topology. Lecture 6. Separation Axioms. This text is based on the following books: Fundamental concepts of topology by Peter O Neil Elements of Mathematics: General Topology by Nicolas Bourbaki Counterexamples

More information

Non-deterministic Semantics and the Undecidability of Boolean BI

Non-deterministic Semantics and the Undecidability of Boolean BI 1 Non-deterministic Semantics and the Undecidability of Boolean BI DOMINIQUE LARCHEY-WENDLING, LORIA CNRS, Nancy, France DIDIER GALMICHE, LORIA Université Henri Poincaré, Nancy, France We solve the open

More information