Automata and Grammars
Code  Completion  Credits  Range  Language 

BIKAAG.21  Z,ZK  5  14KP+4KC  Czech 
 Garant předmětu:
 Jan Holub
 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. Sipser M. : Introduction to the Theory of Computation. Cengage Learning Custom Publishing, 2020. ISBN 9780357670583.
2. Hopcroft J.E., Motwani R., Ullman J. D. : Introduction to Automata Theory, Languages, and Computation, 3rd Edition. Pearson, 2008. ISBN 9788131720479.
3. Kozen D. C. : Automata and Computability. Springer, 1997. ISBN 9780387949079.
4. Šestáková E.: Automaty a gramatiky: Sbírka řešených příkladů, ČVUT 2017, ISBN 9788001063064
5. Šestáková E.: Automata and Grammars, A Collection of exercises and Solutions, ČVUT, 2018, ISBN 9788001064627
 Note:
 Timetable for winter semester 2024/2025:
 Timetable is not available yet
 Timetable for summer semester 2024/2025:
 Timetable is not available yet
 The course is a part of the following study plans:

 Bachelor specialization Information Security, parttime, in Czech, 2021 (compulsory course in the program)
 Bachelor specialization Software Engineering, parttime, in Czech, 2021 (compulsory course in the program)
 Bachelor specialization Computer Networks and Internet, parttime, in Czech, 2021 (compulsory course in the program)
 Bachelor specialization Computer Systems and Virtualization, parttime, in Czech, 2021 (compulsory course in the program)
 Bachelor program, unspecified specialization, parttime, in Czech, 2021 (compulsory course in the program)