This course introduces formal models of computation including finite automata, regular languages, context-free grammars, and Turing machines. These models provide a mathematical basis for the study of computability - the study of what problems can be solved and what problems cannot be solved. Applications to compiler design and program verification will also be covered.We all have problems. Some problems are easier to solve than others; some are unsolvable. But what is a problem? And what is a solution? In this course, we will develop models of computation that make rigorous the idea of problem and solution. In other words, we will provide a language to describe computation so we can reason about it formally. The models we will develop are easy to describe (think flow charts for toasters and elevators), yet computationally very powerful (we can, for example, use them to find the minimal mileage route for the Williamstown snowplow fleet). The rewarding part is understanding the limitations and power of each model.

Here is the breakdown:

- 50%: Ten homework assignments each worth 5% of your grade. You have a total of 4 late days at your disposal. A partial late day counts toward one whole late day. For example, if you turn in a homework 25 hours late, then it counts as 2 late days.
- 20%: A takehome midterm.
- 25%: A takehome, 24-hour, cumulative final.
- 5%: A class participation grade based on your attendance, promptness, and participation in lecture.

Some points of clarification:

- The teaching assistant will give provisional grades on your assignments based on sample solutions and grading criteria I provide. In addition, I'll examine every problem set so that I know what topics you've individually mastered. On most problem sets, I'll exclusively correct one of the problems, paying particular attention to your style and prose. I will meet individually with you several times during the semester to discuss your proof style. I will also adjust the provisional grades when appropriate.
- The homework counts significantly toward your grade. I expect you
will discuss the problems with members of the class, but I expect you
will not discuss the solutions, nor will you write up solutions
together. Deviation is considered an honor code violation.
**Insightful discussion with others must be cited in your homework solution**. You will not lose points for citations, nor will you fall from my good graces; quite the contrary, citation gives credit where credit is due. Your understanding of the problems should be sufficient enough to recount the key arguments of the solution by yourself. - Homework is due at the beginning of class. Homework cannot be turned in via proxy (e.g., via an email attachment or a friend) without prior arrangement.
- Homework should be written clearly and concisely. Rewrite your proofs if they do not flow well. If your handwriting is messy, consider using LaTeX. If your handwriting is not messy, still consider using LaTeX. Also, check out Graphviz for easy finite automata figure creation.
- Homework solutions will be distributed the Monday following the Wednesday due date.
- Each homework question will be graded on a 5 point scale. Here's
the breakdown:
- 5: The solution is clear and correct. This solution would easily find a home in a research paper.
- 4: The solution contains a few mistakes, but they are mostly arithmetic or of little significance to the overall argument.
- 3: The solution hits on the main points, but has at least one logical gap.
- 2: The solution contains several logical mistakes, but parts of it are salvageable.
- 1: The solution is just plain wrong.
- 0: No attempt is made at solving the problem.

A few notes on the midterm:

- The midterm will be take home. You may only use your course notes, course text, homework, and homework solutions.
- The midterm will be very similar to a problem set.
- It will be assigned: 12.00, 17 October 2008.
- It will be due: 17.00, 20 October 2008.
- No collaboration is allowed.
- I will be available by email all weekend. I will also be in my office Saturday morning from 09.00-12.00.

- Optional, but strongly encouraged evening lectures :: 21.00 Monday, 22 Sept 2008 :: 19.00 Tuesday, 23 Sept 2008
- Hunger Strike by Temple the Dog
- A copy of the text is now on reserve in Schow Library
- Several copies of the text are available at the 1914 library. These copies were donated for use during the semester so please take good care of them.

- Mathematical Sophistication
- Lecture 01 :: 05 September 2008 :: A review of mathematical objects
including sets, sequences, and graphs.

Reading: Chapter 0. Please pay particular attention to the*finding proofs*section on pages 17-25 of the text. - Lecture 02 :: 08 September 2008 :: Further review of mathematical
objects including functions and relations.

Reading: Handout from class. Also available here in full form. - Regular Languages
- Lecture 03 :: 10 September 2008 :: An introduction to regular
languages and deterministic finite automata (DFAs).

Reading: Pages 31-43. - Lecture 04 :: 12 September 2008 :: Proving languages are
regular.

Reading: Pages 44-47. - Lecture 05 :: 15 September 2008 :: An introduction to
non-deterministic finite automata (NFAs).

Reading: Pages 47-53. - Lecture 06 :: 17 September 2008 :: Equivalence of DFAs and NFAs. Closure properties.

Reading: Pages 54-62. - Lecture 07 :: 19 September 2008 :: Regular expressions and their
equivalence with finite automata.

Reading: Pages 63-76. - Non-regular Languages
- Lecture 08 :: 22 September :: Non-regular languages and the pumping lemma.

Reading: Pages 77-82. - Lecture 09 :: 22-23 September (optional, but heavily encouraged evening lecture) :: Proving non-regularity with PL and closure properties. :: 09.22.2008 at 21.00 in TPL 205 :: 09.23.2008 at 19.00 in TCL 202.
- Lecture 10 :: 24 September :: Socratic Method Lecture: State minimization and the MyHill-Nerode theorem; Exactly characterizing the regular languages
- No Lecture :: 26 September 2008 :: Away in SF for a wedding :: (covered by evening lecture 09)

- No Lecture :: 29 September 2008 :: Away in SF for a wedding :: (covered by takehome midterm)
- Lecture 11 :: 01 October 2008 :: Proving non-regularity with the MyHill-Nerode theorem.
- Context-Free Languages
- Lecture 12 :: 03 October 2008 :: Context-free grammars

Reading: Pages 99-114. - Lecture 13 :: 06 October 2008 :: Non-deterministic Push Down Automata. Reading: Pages 115-128.
- Lecture 14 :: 08 October 2008 :: CFGs on NPDAs :: Some fun context-free languages.
- No Lecture :: 10 October 2008 :: Mountain Day Placeholders.
- No Lecture :: 13 October 2008 :: Reading period
- Turing Machines and other Models of Computation
- Lecture 15 :: 15 October 2008 :: The Church-Turing Thesis.

Reading: Pages 137-159. - Review Session :: 16 October 2008 :: Evening review session TBA.
- Lecture 16 :: 17 October 2008 :: Models of Computation and TMs. :: Take home midterm handed out at end of class
- Computability and Recognizability
- Lecture 17 :: 20 October 2008 :: Decidable and recognizable sets.
Examples. Equivalent models of computation :: Take home midterm due at 17.00 in my
office.

Reading: Pages 165-172. - Lecture 18 :: 22 October 2008 :: More decidability.
- Lecture 19 :: 24 October 2008 :: Undecidable sets. Diagonalization.

Reading: Pages 173-182. - No Lecture :: 27 October 2008 :: Away at FOCS 2008.
- Lecture 20 :: 29 October 2008 :: Reductions.

Reading: Pages 187-198, 206-210. - Lecture 21 :: 31 October 2008 :: More undecidability. co-RE.
- Lecture 22 :: 03 November 2008 :: Neither RE nor co-RE sets.
- Lecture 23 :: 05 November 2008 :: The Post Correspondence Problem.

Reading: Pages 199-205. - Lecture 24 :: 07 November 2008 :: Socratic Method Lecture: Rice's Theorem.
- Lecture 25 :: 10 November 2008 :: The Recursion Theorem.

Reading: Pages 217-223. - Complexity Theory
- Lecture 26 :: 12 November 2008 :: The complexity classes P and NP.

Reading: Pages 245-270. - Lecture 27 :: 14 November 2008 :: NP-completeness and reductions.

Reading: Pages 271-276. - Lecture 28 :: 17 November 2008 :: NP-complete problems.

Reading: Pages 283-294. - Lecture 29 :: 19 November 2008 :: The Cook-Levin Theorem.

Reading: Pages 271-276. - Lecture 30 :: 21 November 2008 :: Space Complexity and Savitch's Theorem.

Reading: Pages 303-324. This includes some extra reading on space complexity. - Lecture 31 :: 24 November 2008 :: The philosophy of mind lecture.

Reading: Dennett handout [Williams College Access Only] - No Lecture :: 26 November 2008 :: Thanksgiving break.
- No Lecture :: 28 November 2008 :: Thanksgivign break.
- Lecture 32 :: 01 December 2008 :: Relativization.

Reading: Pages 348-350. - Lecture 33 :: 03 December 2008 :: Cryptography.

Reading: Pages 405-411. - Lecture 34 :: 05 December 2008 :: Review.

- Homework 0 [TeX] :: Assigned: 11.00 EDT 05 September 2008 :: Due: 12.00 EDT 07 September 2008
- Homework 1 [TeX] :: Assigned: 11.00 EDT 10 September 2008 :: Due: 11.00 EDT 17 September 2008
- Homework 2 [TeX] :: Assigned: 11.00 EDT 17 September 2008 :: Due: 11.00 EDT 24 September 2008
- Homework 3 [TeX] :: Assigned: 11.00 EDT 24 September 2008 :: Due: 23.59 EDT 01 October 2008
- Homework 4 [TeX] :: Assigned: 11.00 EDT 01 October 2008 :: Due: 11.00 EDT 08 October 2008
- Homework 5 [TeX] :: Assigned: 11.00 EDT 08 October 2008 :: Due: 11.00 EDT 17 October 2008 :: This is the LaTeX assignment. You must typeset your solutions in LaTeX
- Homework 6 [TeX] :: Assigned: 11.00 EDT 22 October 2008 :: Due: 11.00 EDT 29 October 2008
- Homework 7 [TeX] :: Assigned: 12.00 EDT 29 October 2008 :: Due: 11.00 EST 05 November 2008
- Homework 8 [TeX] :: Assigned: 11.00 EST 05 November 2008 :: Due: 11.00 EST 12 November 2008 :: Busy-beaver question
- Homework 9 [TeX] :: Assigned: 11.00 EST 12 November 2008 :: Due: 11.00 EST 21 November 2008
- Homework 10 :: Assigned: 11.00 EST 21 November 2008 :: Proposal Due: 08.00 EST 25 November 2008 :: Due: 11.00 EST 05 December 2008

- Computer Science Cheat Sheet [pdf]
- Princeton CS resources (books, notes, and LaTeX)
- Check out Graphviz for easy, slick, and beautiful creation of finite automata figures.
- Complexity Zoo
- Theoretical Computer Science Blogs

- Computational Complexity :: Lance Fortnow and Bill Gasarch
- WebDiarios de Motocicleta :: Mihai Pătraşcu
- My Biased Coin :: Michael Mitzenmacher
- Andy's Research :: Andy Drucker
- In Theory :: Luca Trevisan
- The Geomblog :: Suresh Venkatasubramanian
- 0xDE :: David Eppstein