Presentation is loading. Please wait.

Presentation is loading. Please wait.

Prof. Busch - RPI1 Decidable Problems of Regular Languages.

Similar presentations


Presentation on theme: "Prof. Busch - RPI1 Decidable Problems of Regular Languages."— Presentation transcript:

1 Prof. Busch - RPI1 Decidable Problems of Regular Languages

2 Prof. Busch - RPI2 Membership Question Question:Given regular language and string how can we check if ? Answer:Take the DFA that accepts and check if is accepted

3 Prof. Busch - RPI3 DFA

4 Prof. Busch - RPI4 Given regular language how can we check if is empty: ? Take the DFA that accepts Check if there is any path from the initial state to an accepting state Question: Answer:

5 Prof. Busch - RPI5 DFA

6 Prof. Busch - RPI6 Given regular language how can we check if is finite? Take the DFA that accepts Check if there is a walk with cycle from the initial state to a final state Question: Answer:

7 Prof. Busch - RPI7 DFA is infinite DFA is finite

8 Prof. Busch - RPI8 Given regular languages and how can we check if ? Question: Find if Answer:

9 Prof. Busch - RPI9 and

10 Prof. Busch - RPI10 or

11 Prof. Busch - RPI11 Decidable Problems of Context-Free Languages

12 Prof. Busch - RPI12 Membership Question: for context-free grammar find if string Membership Algorithms: Parsers Exhaustive search parser CYK parsing algorithm

13 Prof. Busch - RPI13 Empty Language Question: for context-free grammar find if Algorithm: 1.Remove useless variables 2.Check if start variable is useless

14 Prof. Busch - RPI14 Infinite Language Question: for context-free grammar find if is infinite Algorithm: 1. Remove useless variables 2. Remove unit and productions 3. Create dependency graph for variables 4. If there is a loop in the dependency graph then the language is infinite

15 Prof. Busch - RPI15 Example: Dependency graph Infinite language

16 Prof. Busch - RPI16


Download ppt "Prof. Busch - RPI1 Decidable Problems of Regular Languages."

Similar presentations


Ads by Google