Course description: This course is for students interested in programming with logic, especially powerful logic languages, efficient implementations, and diverse applications (exactly those that LLMs cannot do). Official course information
Student will learn logic languages as tools for expressing knowledge and queries, as well as solution strategies, for complex application problems, and will learn systems that implement these languages for efficiently solving the problems. We will also discuss computing with logic at large for reasoning and learning with uncertainty, supporting explainable AI, and for theorem proving, program verification, and distributed programming.
The course will touch on a variety of powerful languages and systems. Rather than dwell on the features of any particular language, we will focus instead on understanding the commonalities and differences, the reasons for them, and the implications of them in applications.
Students will do programming assignments and a course project involving knowledge representation and reasoning.
Prerequisites: Undergraduate discrete math with good analytical experience (predicate logic, sets, functions, relations, probability) plus good experience with commonly-used programming languages and algorithms. | Credits: 3
Instructor: Annie Liu | Office: New CS 237 | Phone: 631-632-8463 | Email: liu@cs.stonybrook.edu | Office hours: Mon 10:20-11 AM, 12:20-1 PM, Wed 2-2:40 PM, Thu 4:20-5 PM, or email for an appointment.
Lectures: Mon Wed 11 AM - 12:20 PM, CS 2311.
Textbook: There is no required textbook for this course; best relevant book chapters, other references, and slides will be given as the course proceeds.
Grading: Lecture critiques: 5% | In-class exercises: 10% | Assignments: 20% | 2 Exams: 2 x 15% | Course project: 35% | No late submission will receive credit.
Course homepage: http://www.cs.stonybrook.edu/~liu/cse505/
Schedule
14 weeks total for 4 units, including 2 exams
Unit 1: Overview and preparation - 2 weeks (1/27-)
An overview of the course (with logic puzzles and advanced applications);
and a brief review of logic in database programming (with sets and
relations) and functional programming (with recursive functions).
We will introduce a simple unified view of logic in programming and the
essence of a powerful method for generating efficient algorithms and programs.
Mon 2/3 Project problem interest due
Mon 2/10 Project problem interest update due
Unit 2: Programming with logic - 6 weeks (2/10-)
Programming with logic rules and constraints, including key language
features and main implementation methods.
We will study programming in powerful logic languages: (1) Datalog, the
core of logic rules; (2) Prolog and answer-set programming (ASP), two
main classes; (3) languages with combined, advanced, or specialized
features. We will discuss constraint programming (CP) and mathematical
programming (MP) that are closely related to logic programming (LP).
We will study efficient implementations: bottom-up inference starting
from given facts, top-down search directed by queries/goals, grounding,
backtracking, backjumping, tabling, indexing, and demand transformation.
We will see how languages can support diverse programming models: logic,
relational, recursive, procedural, objects, transactional updates, and more.
Mon 2/10 Assignment 1
Fri 2/28 Assignment 1 due
Fri 2/28 Assignment 2
Fri 3/14 Assignment 2 due
Fri 3/14 Assignment 3
Fri 3/28 Assignment 3 due
3/17-21 Spring break week
Mon 3/24 Exam 1 preparation
Wed 3/26 Exam 1, in class
Unit 3: Computing with logic at large - 5 weeks (3/31-)
This will include logic and probability supporting explainable AI: (1)
knowledge representation using circuits and rules extended with
probabilities or weights; (2) efficient inference with decision diagrams
and SAT solving; (3) learning of circuit structures and weights and
learning of rules.
We will also discuss languages and systems supporting theorem proving,
program verification, and distributed programming.
Fri 4/11 Assignment 4
Fri 4/25 Assignment 4 due
Fri 4/18 Project design and test program (with prototype skeleton) due
Mon 4/28 Exam 2 preparation
Wed 4/30 Exam 2
Unit 4: Review and outlook - 1 week (5/5-)
Review of a unified view of logic in programming, efficient
implementations, and combining logical and statistical reasoning for
advanced applications.
Fri 5/9 Project due
Wed 5/14 Project presentations, 2-4PM
Google Classroom for this course, for students in the course
Follow information in the Google Classroom for this course.
Attend lectures and take good notes. This is the most efficient way to learn the course materials, because we will both distill and elaborate written materials and discuss important related materials. We will start promptly on time. We will have every student participate in solving problems and presenting solutions in class.
Do course work. The readings are to help you preview and review the materials discussed in the lectures. The assignments and project are to provide concrete experiences with the concepts and methods covered in the lectures. The exercises are to help check that you are keeping up with the lectures and the assignments. The exams will be comprehensive.
If you have any questions, ask. Ask questions in class, in office hours, and in the Q&A group. Talk with your classmates, and share ideas, but not solutions to assignments.
Your submitted work
Submission issues
Grading issues
University Policies
Computer Science Department Policies and Procedures Governing Graduate Academic Dishonesty