Logic Programming (326.121, 326.122)
Logic programming sits at the intersection of mathematics, computer science, and artificial intelligence. It shows how abstract mathematical logic can drive real computation, turning formulas into executable programs. Logic programming encourages declarative thinking, emphasizing what a solution should be rather than how to compute it: a perspective that can influence many different areas, ranging from database design to AI reasoning systems. In modern AI, logic programming plays a key role in areas such as knowledge representation and reasoning, planning and problem solving, and neuro-symbolic integration, bridging the gap between symbolic logic and data-driven approaches. It is a tool that lets AI systems combine raw data with logical thinking, opening the door to explainable and trustworthy intelligence.
This course introduces the logical foundations and computational model of logic programming and provides training in practical programming skills, showing how declarative problem solving emerges from simple formal principles. Students will learn how logic programs are executed, how they can express complex computations, and how these ideas extend to modern paradigms that are based on constraint or probabilistic models.
Grading is based on programming assignments and in-class quizzes. No prior experience in logic programming or Prolog is required.
Winter Semester 2025.
| Number: | 326.121 and 326.122 |
| Title: | Logic Programming |
| Lecturer: | Temur Kutsia |
| Time: | Wednesday 16:15-18:00 |
| Room: | S2 120 (this is an onsite course) |
| Language: | English |
| First meeting: | October 15 |
| Registration: | Via the KUSSS system |
| Grading: | Assignments and quizzes during the semester |
Book:
-
W. F. Clocksin and C. S. Mellish. Programming in Prolog. Fifth edition. Springer. 2003.
Contents:
- Logical foundations. Introduction to Prolog programming.
- Questions, variables, conjunctions, rules, goals.
- Prolog syntax. Characters, operators, equality and matching, arithmetic.
- Using data structures. Programming techniques on Prolog (Mapping, recursion, accumulators, difference structures).
- Backtracking, generating multiple solutions, the cut.
- Selected examples.
- Unification, computational model of logic programs.
- Grammar rules (DCG).
- Efficiency issues.
- Related frameworks: probabilistic logic programming, constraint logic programming.
Slides and other course materials are available in Moodle.
Assignments will be posted on the course Moodle page and are to be completed individually. Quizzes will take place in class and will be announced in advance. Further details can be found on Moodle.
Books, papers, slides:
-
M. A. Covington, R. Bagnara, R. A. O'Keefe, J. Wielemaker, S. Price. Coding Guidelines for Prolog. Theory and Practice of Logic Programming. 12(6): 889-927 (2012) (Highly recommended).
-
M. A. Covington. Efficient Prolog: A Practical Guide. Research Report AI-1989-08, The University of Georgia, Athens, Georgia, 1989.
-
W. F. Clocksin. Prolog Programming (PowerPoint format).
-
J. Lloyd. Foundations of Logic Programming, second edition. Springer, 1987.
-
R. O'Keefe. The Craft of Prolog. MIT Press, 1990.
-
Open lists and difference lists. A section from Paul Brna's online Prolog book.
- L. de Raedt. Probabilistic Logic Programming and its Applications.
-
P. Gloess. Constraint Logic Programming (PowerPoint format).
Some interesting on-line resources: