Automata and Grammars
Code  Completion  Credits  Range  Language 

BIKAAG  Z,ZK  6  13KP+4KC  Czech 
 Lecturer:
 Ondřej Guth, Eliška Šestáková
 Tutor:
 Ondřej Guth, Eliška Šestáková
 Supervisor:
 Department of Theoretical Computer Science
 Synopsis:

Students are introduced to basic theoretical and implementation principles of the following topics: construction, use and mutual transformations of finite automata, regular expressions, and regular grammars, translation finite automata, construction and use of pushdown automata, hierarchy of formal languages. Knowledge acquired through the module is applicable to creation of algorithms for pattern matching, data compression, translation, simple parsing, and creation of digital circuits.
 Requirements:

Knowledge of basic data structures and computer programming.
 Syllabus of lectures:

1. Motivation to study formal languages. Basic notions (language, alphabet, grammar, automaton), Chomsky hierarchy. Nondeterministic and deterministic finite automata (NFA, DFA), NFA with epsilon transitions.
2. Operations on automata (transformation to NFA without epsilon transitions, to DFA, minimalization), intersection, union. Programming implementations of DFA and NFA, curcuit implementations.
3. Extensions to translation, Mealey, Moore, conversions. Operations on regular grammars, conversions to FA.
4. Regular expressions, conversions among regular expressions, finite automata and regular grammars, Kleene theorem. Principles of use of regular expressions in UNIXu (grep, egrep, perl, PHP, ...).
5. Finite automaton as lexical analyzer, lex/flex generators. Properties of regular languages (pumping lemma, Nerode theorem).
6. Contextfree languages, pushdown automaton. Parsing of contextfree languages (nondeterministic versus deterministic).
7. Contextsensitive and recursively enumerable languages, Turing machine.
 Syllabus of tutorials:

1. Examples of formal languages. Intuitive considerations of grammars for given languages. Estimation of the classification of given language in Chomsky hierarchy. Intuitive creation of finite automata (DFA, NFA, with epsilon transitions) for given langauage. Transformations and compositins of FA. Implementation of FA. FA with output function and its implementation.
2. Conversions of grammars to FA and vice versa. Considerations, modifications and transformations of regular expressions. Use of regular expressions for solving tasks of processing text (e.g. sh, grep, sed, perl). Creation and implementation of lexical analyzer. Classification of languages.
3. Examples of contextfree languages, creation of pushdown automata. Examples of deterministic parsing of contextfree languages (e.g. LL, yacc, bison). Examples of contextsensitive and recursively enumerable languages, creation of Turing machines.
 Study Objective:

The course introduces students to finite automata, regular expressions, regular grammars and translation finite automata with stress on their practical use. Furthermore, the course introduces students to the class of contextfree languages and basic use of pushdown automata. Chomsky hierarchy of languages is also introduced for students to better understand the automata theory. Knowledge acquired through the course is applicable to creation of algoritmhs for pattern matching, data compression, translation, simple parsing, and creation of digital circuits.
 Study materials:

1. Aho, A. V., Lam, M. S., Sethi, R., Ullman, J. D. ''Compilers: Principles, Techniques, and Tools (2nd Edition)''. Addison Wesley, 2007. ISBN 0321486811.
2. Kozen, D. C. ''Automata and Computability''. Springer, 1997. ISBN 0387949070.
3. Melichar, B., Holub, J., Mužátko, P. ''Languages and Translations''. Praha: Publishing House of CTU, 1997. ISBN 8001016927.
 Note:
 Further information:
 https://courses.fit.cvut.cz/BIKAAG/
 Timetable for winter semester 2019/2020:
 Timetable is not available yet
 Timetable for summer semester 2019/2020:
 Timetable is not available yet
 The course is a part of the following study plans:

 Bc. Programme Informatics, Part Time Form of Study, in Czech, Version 2015  2020 (compulsory course in the program)
 Bc Branch Security and Information Technology, PartTime Form, in Czech, Version 2015 to 2020 (compulsory course in the program)
 Bc.Branch WSI, Specialization Software Engineering, PartTime Form, Versionverze 2015  2020 (compulsory course in the program)