Student#: CISC-462 Exam, December XY, 2017 Page 1 of 12

Similar documents
6.045 Final Exam Solutions

Midterm Exam 2 CS 341: Foundations of Computer Science II Fall 2018, face-to-face day section Prof. Marvin K. Nakayama

CSCE 551 Final Exam, Spring 2004 Answer Key

Midterm Exam 2 CS 341: Foundations of Computer Science II Fall 2016, face-to-face day section Prof. Marvin K. Nakayama

Computability and Complexity CISC462, Fall 2018, Space complexity 1

Computability and Complexity

Exam Computability and Complexity

3130CIT Theory of Computation

1 Showing Recognizability

Homework Assignment 6 Answers

FORMAL LANGUAGES, AUTOMATA AND COMPUTATION

QUEEN S UNIVERSITY FINAL EXAMINATION FACULTY OF ARTS AND SCIENCE DEPARTMENT OF ECONOMICS APRIL 2018

Name: Student ID: Instructions:

I II III IV V VI VII VIII IX X Total

I II III IV V VI VII VIII IX Total

CP405 Theory of Computation

UNIT-VIII COMPUTABILITY THEORY

Complexity Theory 112. Space Complexity

CSE 105 THEORY OF COMPUTATION

CSE 105 THEORY OF COMPUTATION. Spring 2018 review class

ECS 120: Theory of Computation UC Davis Phillip Rogaway February 16, Midterm Exam

CS 311 Sample Final Examination

I II III IV V VI VII VIII IX Total

I II III IV V VI VII VIII IX Total

DEPARTMENT OF MANAGEMENT AND ECONOMICS Royal Military College of Canada. ECE Modelling in Economics Instructor: Lenin Arango-Castillo

THEORY OF COMPUTATION (AUBER) EXAM CRIB SHEET

Undecidable Problems and Reducibility

Lecture 21: Space Complexity (The Final Exam Frontier?)

COL 352 Introduction to Automata and Theory of Computation Major Exam, Sem II , Max 80, Time 2 hr. Name Entry No. Group

452 FINAL- VERSION E Do not open this exam until you are told. Read these instructions:

CS 154 Introduction to Automata and Complexity Theory

I II III IV V VI VII VIII IX Total

V Honors Theory of Computation

Computability Theory

I II III IV V VI VII VIII IX Total

SYLLABUS. Introduction to Finite Automata, Central Concepts of Automata Theory. CHAPTER - 3 : REGULAR EXPRESSIONS AND LANGUAGES

Theory Bridge Exam Example Questions

CSE 105 THEORY OF COMPUTATION

Languages, regular languages, finite automata

Polynomial Time Computation. Topics in Logic and Complexity Handout 2. Nondeterministic Polynomial Time. Succinct Certificates.

No textbook, lecture note, calculator, computer, or other aid of any sort is allowed.

ACS2: Decidability Decidability

Theory of Computation (IX) Yijia Chen Fudan University

Theory of Computation

CSE 105 THEORY OF COMPUTATION

Lecture 22: PSPACE

1. (a) Explain the procedure to convert Context Free Grammar to Push Down Automata.

cse303 ELEMENTS OF THE THEORY OF COMPUTATION Professor Anita Wasilewska

Computation Histories

I have read and understand all of the instructions below, and I will obey the University Code on Academic Integrity.

Chapter 2: Finite Automata

MTAT Complexity Theory October 13th-14th, Lecture 6

CS 455/555: Finite automata

CS Lecture 29 P, NP, and NP-Completeness. k ) for all k. Fall The class P. The class NP

CS 154, Lecture 2: Finite Automata, Closure Properties Nondeterminism,

CS5371 Theory of Computation. Lecture 23: Complexity VIII (Space Complexity)

6.045J/18.400J: Automata, Computability and Complexity Final Exam. There are two sheets of scratch paper at the end of this exam.

Final Exam Version A December 16, 2014 Name: NetID: Section: # Total Score

Part I: Definitions and Properties

Lecture Notes On THEORY OF COMPUTATION MODULE -1 UNIT - 2

Final Exam (Version B) December 16, 2014 Name: NetID: Section: 1 2 3

CPSC 421: Tutorial #1

Complexity. Complexity Theory Lecture 3. Decidability and Complexity. Complexity Classes

DM17. Beregnelighed. Jacob Aae Mikkelsen

Uses of finite automata

Could we potentially place A in a smaller complexity class if we consider other computational models?

CSCE 551: Chin-Tser Huang. University of South Carolina

CS154, Lecture 17: conp, Oracles again, Space Complexity

Decidability (What, stuff is unsolvable?)

COMP/MATH 300 Topics for Spring 2017 June 5, Review and Regular Languages

FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY

Mapping Reducibility. Human-aware Robotics. 2017/11/16 Chapter 5.3 in Sipser Ø Announcement:

Time to learn about NP-completeness!

Chapter 5. Finite Automata

Undecidability COMS Ashley Montanaro 4 April Department of Computer Science, University of Bristol Bristol, UK

Midterm II : Formal Languages, Automata, and Computability

Closure under the Regular Operations

cse303 ELEMENTS OF THE THEORY OF COMPUTATION Professor Anita Wasilewska

CS5371 Theory of Computation. Lecture 14: Computability V (Prove by Reduction)

Theory of Computation

Finite Automata and Regular languages

Advanced topic: Space complexity

Review of Basic Computational Complexity

Automata Theory. Lecture on Discussion Course of CS120. Runzhe SJTU ACM CLASS

Let us first give some intuitive idea about a state of a system and state transitions before describing finite automata.

Nondeterministic Finite Automata

Theory of Computation

NODIA AND COMPANY. GATE SOLVED PAPER Computer Science Engineering Theory of Computation. Copyright By NODIA & COMPANY

CSE 105 THEORY OF COMPUTATION

conp, Oracles, Space Complexity

Finite-State Machines (Automata) lecture 12

Sample Midterm. Understanding the questions is part of the exam; you are not allowed to ask questions during the exam.

UNIVERSITY OF CALIFORNIA, RIVERSIDE

CpSc 421 Final Exam December 15, 2006

CSCE 551 Final Exam, April 28, 2016 Answer Key

T (s, xa) = T (T (s, x), a). The language recognized by M, denoted L(M), is the set of strings accepted by M. That is,

CSE 555 HW 5 SAMPLE SOLUTION. Question 1.

Clarifications from last time. This Lecture. Last Lecture. CMSC 330: Organization of Programming Languages. Finite Automata.

CS 301. Lecture 18 Decidable languages. Stephen Checkoway. April 2, 2018

Introduction to the Theory of Computation. Automata 1VO + 1PS. Lecturer: Dr. Ana Sokolova.

Transcription:

Student#: CISC-462 Exam, December XY, 2017 Page 1 of 12 Queen s University, Faculty of Arts and Science, School of Computing CISC-462 Final Exam, December XY, 2017 (Instructor: Kai Salomaa) INSTRUCTIONS Aids allowed: You may bring in one 8.5 11 inch sheet of paper containing notes, and use it during the exam. The sheet can be written/printed on both sides. This examination is THREE HOURS in length. Answer each question in the space provided (on the question paper). There is an extra page at the end of the exam, if more space is needed. Please write legibly. Each of the 11 questions is worth 10 marks. The exam is marked out of 100 possible marks, and your mark is calculated as the sum of your 10 best answers. You can answer all 11 questions and only the 10 best answers are included in the mark. PLEASE NOTE: Proctors are unable to respond to queries about the interpretation of exam questions. Do your best to answer exam questions as written. STUDENT NUMBER: Please write extremely carefully. Problem 1 /10 Problem 2 /10 Problem 3 /10 Problem 4 /10 Problem 5 /10 Problem 6 /10 Problem 7 /10 Problem 8 /10 Problem 9 /10 Problem 10 /10 Problem 11 /10 Total /100 The total mark is calculated as the sum of your 10 best answers. This material is copyrighted and is for the sole use of students registered in CISC 462 and writing this exam. This material shall not be distributed or disseminated. Failure to abide by these conditions is a breach of copyright and may also constitute a breach of academic integrity under the University Senate s Academic Integrity Policy Statement.

Student#: CISC-462 Exam, December XY, 2017 Page 2 of 12 a b a a a b b M 1 M 2 Figure 1: Finite automaton M 1 (on the left) and finite automaton M 2 (on the right). 1. Define: A NF A = { < M, w > M is an NFA, w is a string and w L(M)} EQ DF A,REX = { < M, R > M is a DFA, R is a regular expression, and L(M) = L(R) }. Recall that DFA (respectively, NFA) stands for deterministic (respectively, nondeterministic) finite automaton. Let M 1 and M 2 be the finite automata given in Figure 1 and let R 1 be the regular expression a b(a b) Answer the following questions and give reasons for your answers. (i) Is < M 1, aba > A NF A? b (ii) Is < M 1, bab > A NF A? (iii) Is < M 2, abb > A NF A? (iv) Is < M 2, abab > A NF A? (v) Is < M 1, R 1 > EQ DF A,REX? (vi) Is < M 2, R 1 > EQ DF A,REX? (vii) Is < M 1, M 1 > EQ DF A,REX? (viii) Is < M 1, M 2 > EQ DF A,REX? (ix) Is < R 1, R 1 > EQ DF A,REX?

Student#: CISC-462 Exam, December XY, 2017 Page 3 of 12 2. Give a complete construction, that is, a state transition diagram of a single-tape deterministic Turing machine M that decides the language { b i c i i 0 } Give also the sequence of configurations that your Turing machine M enters when started on input string bbc. (Note: The string bbc should be rejected.)

Student#: CISC-462 Exam, December XY, 2017 Page 4 of 12 3. (i) (3 marks) Consider the function f : IN IN defined by f(n) = (2 n) 1. (Here IN = {1, 2, 3,...} is the set of positive integers.) Answer the following questions and give reasons for your answers. (a) Is f onto? (b) Is f one-to-one? (c) Is f a correspondence? (ii) (7 marks) Let T = {(i, j, k) i, j, k N}. Show that T is countable.

Student#: CISC-462 Exam, December XY, 2017 Page 5 of 12 4. Give an implementation-level description of a deterministic Turing machine M that decides the following language A over the alphabet Σ = {b, c}. A = { w Σ w b = 2 ( w c) } Above the number of occurrences of symbol b (respectively, c) in a string w is denoted as w b (respectively, w c ). 2 ( w c) denotes 2 to the power w c. If you wish, your deterministic TM M can use more than one tape.

Student#: CISC-462 Exam, December XY, 2017 Page 6 of 12 5. (i) (4 marks) Does the following instance of the Post Correspondence Problem have a match (that is, a solution). Justify your answer. { [ baab bab baab ], [ ], [ ab baab baaab ], [ ab abba ] } (ii) (6 marks) We define the following language P CP = {< P > P is an instance of the Post Correspondence Problem with a match } Answer the following questions and justify your answers. (a) Does there exist a decidable language A such that P CP m A? (b) Does there exist an undecidable language B such that P CP m B? (c) Does there exist a decidable language C such that C m P CP?

Student#: CISC-462 Exam, December XY, 2017 Page 7 of 12 6. Let B TM = { < M > M is a deterministic Turing machine with input alphabet {a, b}, such that all strings accepted by M begin with b and L(M) }. Without using Rice s theorem show that B TM is undecidable.

Student#: CISC-462 Exam, December XY, 2017 Page 8 of 12 7. (i) (4 marks) In each part circle the correct answer. (a) n 2 = O((log n) 5 n) TRUE FALSE (b) n log n = o(n 2 ) TRUE FALSE (c) 2 n = o(3 n ) TRUE FALSE (d) 1 = O(n 2 ) TRUE FALSE (ii) (6 marks) We define ALL DF A = { < A > A is a DFA with alphabet Σ and L(A) = Σ }. Show that ALL DF A is in P. In your solution you can assume known that the reachability problem on directed graphs (PATH) is in P.

Student#: CISC-462 Exam, December XY, 2017 Page 9 of 12 8. Give an example of a non-context-free language A such that A is in the class L (= SPACE(log n)). You should briefly explain how a logarithmic space deterministic TM decides your language A. You do not need to prove that A is non-context-free. 9. Let B be NP-complete and assume that B P B. (Here B is the complement of B and P is polynomial time reducibility.) Show that the above implies NP = conp.

Student#: CISC-462 Exam, December XY, 2017 Page 10 of 12 10. Recall that L denotes the logarithmic space reducibility. Answer the following questions and justify your answers. Note: To show that an implication does not hold, one should give a counter-example. (i) Let B be an NP-complete language and A is a language such that A L B. Does this imply that A is in NP? (ii) Let B be a context-free language and A is a language such that A L B. Does this imply that A is in NP? (iii) Let B be a context-free language and A is a language such that B L A. Does this imply that A is in NP?

Student#: CISC-462 Exam, December XY, 2017 Page 11 of 12 11. What is the relationship (equal = ; strict inclusion or ; inclusion that is not known to be strict or ) between the following pairs of complexity classes. Justify your answers. (i) TIME(n 3 ) and TIME(n 3 log n) (ii) SPACE(n 3 + n 2 (log n) 3 ) and SPACE(n 3 log n) (iii) SPACE(2 n ) and SPACE(2 n+5 ) (iv) TIME(2 n ) and TIME(3 n ) (v) SPACE(n 5 ) and NSPACE(n 2 log n)

Student#: CISC-462 Exam, December XY, 2017 Page 12 of 12 Extra page.