Summary Summary Automata Finite Automata single start state
- Slides: 36
Summary
Summary Automata
Finite Automata (single) start state 1 states 0 0, 1 alphabet Σ = {0, 1} (several) accept states transition for each symbol 0, 1 n read input one symbol at a time; follow arrows; accept if end in accept state
Finite Automata n n Non-deterministic variant: NFA Regular expressions built up from: ¡ ¡ ¡ unions concatenations star operations Main results: same set of languages recognized by FA, NFA and regular expressions (“regular languages”).
Pushdown Automata finite control input tape 0 1 1 0 0 1 q 0 New capabilities: (infinite) stack 0 1 1 0 : • can push symbol onto stack • can pop symbol off of stack
Context-Free Grammars terminal symbols start symbol A → 0 A 1 A→B B→# production non-terminal symbols
n CFL-> PDA n PDA-> CFL
Pushdown Automata Main results: same set of languages recognized by NPDA, and contextfree grammars (“context-free languages”). L (P)? N(P)? n n and DPDA’s weaker than NPDA’s… again, L (P)? N(P)?
Non-regular languages Pumping Lemma: Let L be a regular language. There exists an integer p (“pumping length”) for which every w L with |w| p can be written as w = xyz such that 1. 2. 3. for every i 0, xyiz L , and |y| > 0, and |xy| p. Reason?
Pumping Lemma for CFLs CFL Pumping Lemma: Let L be a CFL. There exists an integer p (“pumping length”) for which every w L with |w| p can be written as w = uvxyz such that 1. 2. 3. for every i 0, uvixyiz L , and |vy| > 0, and |vxy| p. Reason?
Summary Turing Machines and decidability
Turing Machines input tape finite control q 0 n 0 1 1 0 0 1 1 1 0 0 read/write head New capabilities: ¡ ¡ ¡ infinite tape can read OR write to tape read/write head can move left and right …
Deciding and Recognizing • accept n TM M: ¡ ¡ input machine • reject • loop forever L(M) is the language it recognizes by final state if M rejects every x L(M) it decides L set of languages recognized by some TM is called Turingrecognizable or recursively enumerable (RE) set of languages decided by some TM is called Turingdecidable or recursive
n Extension ¡ Multiple track Multiple tape State with Buffer Nondeterministic ¡ 。。。 ¡ ¡ ¡
The Halting Problem n Definition of the “Halting Problem”: HALT = { <M, x> | TM M halts on input x } n Is HALT decidable?
The Halting Problem Theorem: HALT is not decidable (undecidable). Proof: ¡ Suppose TM H decides HALT n n ¡ Define new TM H’: on input <M> n n ¡ if H accepts <M, <M>>, then loop if H rejects <M, <M>>, then halt consider H’ on input <H’>: n n ¡ if M accept x, H accept if M does not accept x, H reject if it halts, then H rejects <H’, <H’>>, which implies it cannot halt if it loops, then H accepts <H’, <H’>>, which implies it must halt contradiction. Thus neither H nor H’ can exist
H’ is the opposite of the diagonals: n Entry i, j is the value of H on input <Mi, <Mj>> <M 1> <M 2> <M 3> <M 4> … M 1 M 2 M 3 M 4 … H’ A A R A R A A A R R R R A A <H’> ?
Decidable, RE, co. RE… co-HALT {anbn : n ≥ 0 } co-RE decidable some language regular languages all languages context free languages RE {anbncn : n ≥ 0 } HALT some problems (e. g HALT) have no algorithms
Definition of reduction A yes no f f yes no B reduction from language A to language B
Using reductions n Used reductions to prove lots of problems were: ¡ ¡ undecidable (reduce from undecidable) non-RE (reduce from non-RE) n ¡ non-co. RE (reduce from non-co. RE) n n or show undecidable, and co. RE or show undecidable, and RE Reduction Direction!
Summary Complexity
Complexity n Complexity Theory = study of what is computationally feasible (or tractable) with limited resources: ¡ ¡ ¡ running time storage space number of random bits degree of parallelism rounds of interaction others… main focus not in this course
Time and Space Complexity Definition: the time complexity of a TM M is a function f: N → N, where f(n) is the maximum number of steps M uses on any input of length n. Definition: the space complexity of a TM M is a function f: N → N, where f(n) is the maximum number of tape cells M scans on any input of length n.
Complexity Classes Definition: TIME(t(n)) = {L : there exists a TM M that decides L in space O(t(n))} P = k ≥ 1 TIME(nk) EXP = k ≥ 1 k n TIME(2 ) Definition: SPACE(t(n)) = {L : there exists a TM M that decides L in space O(t(n))} PSPACE = k ≥ 1 SPACE(nk)
Complexity Classes Definition: NTIME(t(n)) = {L : there exists a NTM M that decides L in time O(t(n))} NP = k ≥ 1 NTIME(nk) n n n Theorem: P EXP P NP PSPACE EXP Don’t know if any of the containments are proper.
Poly-time reductions n Type of reduction we will use: ¡ ¡ A “many-one” poly-time reduction (commonly) “mapping” poly-time reduction (book) yes no f f yes no 1. f poly-time B computable 2. YES maps to YES 3. NO maps to NO
Hardness and completeness Definition: a language L is C-hard if for every language A C, A polytime reduces to L; i. e. , A ≤P L. can show L is C-hard by reducing from a known C-hard problem Definition: a language L is C-complete if L is C-hard and L C
Complexity classes EXP P co. NP PSPACE decidable languages NP
Decidability and Closure Property
n RL n Parallel Production n CFL n Clean、CYK n TM Construction
n Closure Property n Use known statement to Prove unknown argument n Closure of complexity class n Consider operation between languages in different classes
Models
n Transition System ¡ ¡ Semantic Basis Definition Equivalence Temporal Logic
n Petri Net ¡ ¡ Concurrency Token Game Model a concurrency System Relation Between PN and TS
n Timed Automata Definition ¡ ¡ ¡ Continuous time domain When should we use such model? Invariant, Guard, Reset? Model a real system!
Recruitment n bulei@nju. edu. cn n No. 308, CS Building n 2 Positions left
- Soal teori bahasa dan automata
- Finite automata dikelompokkan menjadi
- Finite state automata didefinisikan dengan
- Mesin mealy adalah
- Apa yang dimaksud dengan tata bahasa dan aturan produksi
- Deterministic finite state automata
- Contoh kasus finite state automata
- Finite and non finite subordinate clauses
- What is finite verb
- Learning objectives of non finite verbs
- Finite and non-finite verb
- Finite and non finite
- String matching with finite automata
- Finite automata
- Lexical analysis finite automata
- Transition diagram in automata
- Automata
- Kleene theorem part 3
- Theory of computation
- Finite automata
- An informal picture of finite automata
- Limitations of finite state machine
- Finite automata
- Finite automata
- Unempty
- Deterministic finite automata adalah
- Finite automata with epsilon transitions
- Forevers gotta start tonight
- Jump triage
- Size of tcp segment header
- Finite state machine sequential circuits
- Finite state machine with datapath
- Finite state machine minimization
- Vhdl finite state machine
- Traffic light finite state machine
- Transport layer primitives
- Fsm