**Prerequisites**

CS211 and Math 125 (C or better in both).

**Content**

This course is an introduction to two kinds of formal systems - languages and logics - with important applications to computer science. The study of formal languages underlies important aspects of compilers and other language processing systems, as well as the theory of computation. Various systems of logic and automatic reasoning are put to use in artificial intelligence, database theory and software engineering. The entire course will give you practice in precise thinking and proof methods that play a role in the analysis of algorithms. The programming assignments provide practical experience with some theoretical topics.

**Objectives**

Will understand the concepts and relevance of logic, formal languages and automata theory, and computability.

Will be able to able to do mechanical formal proofs, program
correctness proofs and solve problems in first-order logic.

Will be able to solve problems in elementary machine models: designing finite-state, pushdown and turing machines.

Will be able to solve problems in formal languages: writing regular expressions, regular grammars, and context-free grammars.

**Textbook**

Title: Logic and Languages Models for Computer Science, 3rd edition.

Authors: Dana Richards and Henry Hamberger

Available at the campus bookstore

**Note** that the 3rd
edition is substantially different from the 2nd.

**Grading**

Quizzes -- 20%

Programming assignment -- 20%

Exams -- 60%

Of these exams the highest score will count 35%, and the lowest 25%.

**Homework**

Homework will be assigned each week, but it is ungraded and will not
be collected. However, it will be hard to do well in this class if
you do not do the homework, so you are strongly encouraged to
do *all* of the problems, and to ask questions if you do not
understand any of them.

**Quizzes**

Quizzes will be given in class, typically every other class period.
They will cover the material from that week's homework.
The lowest quiz grade will be dropped.

**Programming Assignments**

There will be a programming assignment in Prolog. Collaboration on
this assignment is NOT allowed. Receiving direct contributions to the
code and submitting them is considered a violation of the Honor
Code. (See here for the GMU and Computer Science guidelines.)
Programs will be marked down 25% each class they are late; in
particular, they are marked down 25% after the due date.

**Exams**

All testing is closed book, and notes are not permitted.
The two exams, including the final, each cover about a half of the
semester. The final is not cumulative.

**Use of electronics in class**

I challenge you to cut yourself off. You
will find that you learn a lot more, and retain the information better
if you remove the distraction!

**Other Policies**

It is a departmental requirement that students in CS330 must see their
advisor and discuss their degree progress. Students not fulfilling
this requirement will receive an Incomplete grade. (Non-majors and
graduate students are not included.) The visit must be documented by
a signed note or email from your advisor.