Download presentation

Presentation is loading. Please wait.

1
Costas Busch - RPI1 Undecidable problems for Recursively enumerable languages continued…

2
Costas Busch - RPI2 is empty? is finite? contains two different strings of the same length? Take a recursively enumerable language Decision problems: All these problems are undecidable

3
Costas Busch - RPI3 Theorem: For a recursively enumerable language it is undecidable to determine whether is finite Proof: We will reduce the halting problem to this problem

4
Costas Busch - RPI4 finite language problem decider YES NO Suppose we have a decider for the finite language problem: Let be the TM with finite not finite

5
Costas Busch - RPI5 Halting problem decider YES NO halts on We will build a decider for the halting problem: doesn’t halt on

6
Costas Busch - RPI6 YES NO YES Halting problem decider finite language problem decider We want to reduce the halting problem to the finite language problem

7
Costas Busch - RPI7 YES NO YES Halting problem decider finite language problem decider We need to convert one problem instance to the other problem instance convert input ?

8
Costas Busch - RPI8 Construct machine : If enters a halt state, accept ( inifinite language) Initially, simulates on input Otherwise, reject ( finite language) On arbitrary input string

9
Costas Busch - RPI9 halts on is infinite if and only if

10
Costas Busch - RPI10 construct YES NO YES halting problem decider finite language problem decider

11
Costas Busch - RPI11 is empty? is finite? contains two different strings of the same length? Take a recursively enumerable language Decision problems: All these problems are undecidable

12
Costas Busch - RPI12 Theorem: For a recursively enumerable language it is undecidable to determine whether contains two different strings of same length Proof: We will reduce the halting problem to this problem

13
Costas Busch - RPI13 Two-strings problem decider YES NO Suppose we have the decider for the two-strings problem: Let be the TM with contains Doesn’t contain two equal length strings

14
Costas Busch - RPI14 Halting problem decider YES NO halts on We will build a decider for the halting problem: doesn’t halt on

15
Costas Busch - RPI15 YES NO YES NO Halting problem decider Two-strings problem decider We want to reduce the halting problem to the empty language problem

16
Costas Busch - RPI16 YES NO YES NO Halting problem decider Two-strings problem decider We need to convert one problem instance to the other problem instance convert inputs ?

17
Costas Busch - RPI17 Construct machine : When enters a halt state, accept if or Initially, simulate on input (two equal length strings ) On arbitrary input string Otherwise, reject ( )

18
Costas Busch - RPI18 halts on if and only if accepts two equal length strings accepts and

19
Costas Busch - RPI19 construct YES NO YES NO Halting problem decider Two-strings problem decider

20
Costas Busch - RPI20 Rice’s Theorem

21
Costas Busch - RPI21 Non-trivial properties of recursively enumerable languages: any property possessed by some (not all) recursively enumerable languages Definition:

22
Costas Busch - RPI22 Some non-trivial properties of recursively enumerable languages: is empty is finite contains two different strings of the same length

23
Costas Busch - RPI23 Rice’s Theorem: Any non-trivial property of a recursively enumerable language is undecidable

24
Costas Busch - RPI24 The Post Correspondence Problem

25
Costas Busch - RPI25 Some undecidable problems for context-free languages: Is context-free grammar ambiguous? Is ? are context-free grammars

26
Costas Busch - RPI26 We need a tool to prove that the previous problems for context-free languages are undecidable: The Post Correspondence Problem

27
Costas Busch - RPI27 The Post Correspondence Problem Input: Two sequences of strings

28
Costas Busch - RPI28 There is a Post Correspondence Solution if there is a sequence such that: PC-solution: Indeces may be repeated or ommited

29
Costas Busch - RPI29 Example: PC-solution:

30
Costas Busch - RPI30 Example: There is no solution Because total length of strings from is smaller than total length of strings from

31
Costas Busch - RPI31 The Modified Post Correspondence Problem Inputs: MPC-solution:

32
Costas Busch - RPI32 Example: MPC-solution:

33
Costas Busch - RPI33 1. The MPC problem is undecidable 2. The PC problem is undecidable (by reducing MPC to PC) (by reducing the membership to MPC) We will show:

34
Costas Busch - RPI34 Theorem: The MPC problem is undecidable Proof: We will reduce the membership problem to the MPC problem

35
Costas Busch - RPI35 Membership problem Input: recursive language string Question: Undecidable

36
Costas Busch - RPI36 Membership problem Input: unrestricted grammar string Question: Undecidable

37
Costas Busch - RPI37 Suppose we have a decider for the MPC problem MPC solution? YES NO String Sequences MPC problem decider

38
Costas Busch - RPI38 We will build a decider for the membership problem YES NO Membership problem decider

39
Costas Busch - RPI39 MPC problem decider Membership problem decider The reduction of the membership problem to the MPC problem: yes no

40
Costas Busch - RPI40 MPC problem decider Membership problem decider We need to convert the input instance of one problem to the other yes no convert inputs ?

41
Costas Busch - RPI41 : special symbol For every symbol Grammar : start variable For every variable

42
Costas Busch - RPI42 Grammar For every production : special symbol string

43
Costas Busch - RPI43 Example: Grammar : String

44
Costas Busch - RPI44

45
Costas Busch - RPI45

46
Costas Busch - RPI46 Grammar :

47
Costas Busch - RPI47

48
Costas Busch - RPI48

49
Costas Busch - RPI49

50
Costas Busch - RPI50 has an MPC-solution if and only if

51
Costas Busch - RPI51 MPC problem decider Membership problem decider Construct yes no

52
Costas Busch - RPI52 Since the membership problem is undecidable, The MPC problem is uncedecidable END OF PROOF

53
Costas Busch - RPI53 Theorem: The PC problem is undecidable Proof: We will reduce the MPC problem to the PC problem

54
Costas Busch - RPI54 Suppose we have a decider for the PC problem PC solution? YES NO String Sequences PC problem decider

55
Costas Busch - RPI55 We will build a decider for the MPC problem MPC solution? YES NO String Sequences MPC problem decider

56
Costas Busch - RPI56 PC problem decider MPC problem decider The reduction of the MPC problem to the PC problem: yes no

57
Costas Busch - RPI57 PC problem decider MPC problem decider yes no convert inputs ? We need to convert the input instance of one problem to the other

58
Costas Busch - RPI58 : input to the MPC problem

59
Costas Busch - RPI59 We construct new sequences

60
Costas Busch - RPI60 We insert a special symbol between any two symbols

61
Costas Busch - RPI61

62
Costas Busch - RPI62 Special Cases

63
Costas Busch - RPI63 has a PC solution has an MPC solution if and only if

64
Costas Busch - RPI64 PC-solution MPC-solution

65
Costas Busch - RPI65 PC problem decider MPC problem decider yes no Construct

66
Costas Busch - RPI66 Since the MPC problem is undecidable, The PC problem is undecidable END OF PROOF

67
Costas Busch - RPI67 Some undecidable problems for context-free languages: Is context-free grammar ambiguous? Is ? are context-free grammars We reduce the PC problem to these problems

68
Costas Busch - RPI68 Theorem: Proof: Let be context-free grammars. It is undecidable to determine if Rdeduce the PC problem to this problem

69
Costas Busch - RPI69 Suppose we have a decider for the empty-intersection problem Empty- interection problem decider YES NO Context-free grammars

70
Costas Busch - RPI70 We will build a decider for the PC problem PC solution? YES NO String Sequences PC problem decider

71
Costas Busch - RPI71 PC problem decider The reduction of the PC problem to the empty-intersection problem: yes no Empty- interection problem decider

72
Costas Busch - RPI72 PC problem decider noyes no Empty- interection problem decider convert inputs ? We need to convert the input instance of one problem to the other

73
Costas Busch - RPI73 : input to the PC problem

74
Costas Busch - RPI74 Introduce new unique symbols:

75
Costas Busch - RPI75 Context-free grammar :

76
Costas Busch - RPI76 Context-free grammar :

77
Costas Busch - RPI77 if and only if has a PC solution

78
Costas Busch - RPI78 Because are unique There is a PC solution:

79
Costas Busch - RPI79 PC problem decider noyes no Empty- interection problem decider Construct Context-Free Grammars

80
Costas Busch - RPI80 Since PC is undecidable, the empty-intersection problem is undecidable END OF PROOF

81
Costas Busch - RPI81 For a context-free grammar, Theorem: it is undecidable to determine if G is ambiguous Proof: Reduce the PC problem to this problem

82
Costas Busch - RPI82 PC problem decider noyes no Ambiguous- grammar problem decider Construct Context-Free Grammar

83
Costas Busch - RPI83 start variable of

84
Costas Busch - RPI84 if and only if is ambiguous if and only if has a PC solution

Similar presentations

© 2021 SlidePlayer.com Inc.

All rights reserved.

To make this website work, we log user data and share it with processors. To use this website, you must agree to our Privacy Policy, including cookie policy.

Ads by Google