Spring 2008

cs302: Theory of Computation

Coach
David Evans
evans@cs.virginia.edu

Assistant Coaches
Suzanne Collier
Qi Mi
Joe Talbott
Wuttisak Trongsiriwat

Class Meetings
Tuesdays and Thursdays
2-3:15pm in Olsson 120
Office Hours (OLS 236A)
Mondays, 2-3pm
Wednesday, 9:30-10:30am
Problem-Solving Sessions (OLS 228E)
Mondays, 5:30-6:30pm
Wednesday, 6-7pm

# Exam 1

Exam 1 will be in class, Thursday, February 28. It covers material from Lectures 1-10, Problem Sets 1-3 (including the comments), and Sipser Chapters 0-2. The preponderance of the exam questions will focus on understanding of concepts that have been covered in all three ways (lecture, problem set, and book).

You may bring a single page, one side, of prepared notes to use during the exam. You may not use any other resources during the exam.

If you can do these things, you should do well on the exam:

• Provide clear and precise definitions of basic concepts including: computer, deterministic, graph, language, problem, and subgraph.
• Determine the language described by a given Deterministic Finite Automaton (DFA), Nondeterministic Finite Automaton (NFA), Deterministic Pushdown Automaton (DPDA), Nondeterministic Pushdown Automaton (NDPDA), and Context-Free Grammar (CFG).
• For a given language, construct a DFA, NFA, DPDA, NDPDA, or CFG that recognizes that language.
• For a given language, determine the simplest type of machine or grammar that can recognize it.
• Construct and/or understand a proof-by-induction, proof-by-construction, and proof-by-contradiction.
• Prove that a given language is non-regular.
• Prove that a given language is not context-free.
• Reason about closure properties of a language class.

I recommend studying by doing as many of these things as you can (in roughly this order):

1. Review Problem Sets 1-3 and the provided comments. If there are questions you could not solve yourself originally, try them again and then use the comments for help.
2. Review the course notes and slides. Try to solve the questions in the course notes.
3. Review the book. For topics on which you are under-confident, try example problems and exercises in the book. (Many of these have solutions.)
4. Try the practice exams (see below). Try to solve the questions yourself, before discussing them with others or looking at the solutions.
I also recommend getting help with any topics or questions you have by going to office hours (in Olsson 226D, Monday, 2-3pm; Wednesday, 9:30-10:30am) and the help session (Monday 5:30pm, Olsson 228E) and review session (Wednesday, 6pm).

### Practice Exams

MIT 6.045J Practice Quiz 1 (Nancy Lynch and Elena Grigorescu)
You should not worry about Problem 3 and 4 of this exam, which focus on regular expressions (which we have covered only lightly in this class). Otherwise, you should be able to answer all the problems on this exam. (Solutions to the quiz are available here, but it is recommend to try it yourself before looking at them.)
University of Washington CSE 322: 2004 sample midterm; 2005 sample midterm
You should be able to do all the questions on both exams, except 2c from the 2004 midterm.