Terms, Syntactic unification. Clausal form. Proof theory: an Hilbert Calculus. Herbrand Algebra and Herbrand theorem.Resolution Calculus for general clauses, its correctness and completeness. Horn clauses Logic. Logic Programming and SLD Resolution. Semantics of logic programming, negation and SLDNF resolution. Prolog language. Sample case studies: difference lists and DCG, terms manipulation, interpreter/compiler construction.
L. Console, E. Lamma, P. Mello, M. Milano - Programmazione Logica e Prolog, Utet, Torino
V. Sperschneider, G. Antoniou - Logic: A Foundation for Computer Science, Addison Wesley Pub. Co.
J.W. LLoyd - Foundations of Logic Programming, Springer Verlag
K.R. Apt - From Logic Programming to Prolog, Prentice Hall,1997
Learning Objectives
Knowledge acquired:
Theoretical basis (term unification, resolution principle) and practical applications of declarative programming paradigm based on predicate logic. Prolog programming language.
Competence acquired
Suitable use of declarative programming paradigm, particularly use of recursion and information representation by means of terms in the solution of various kind of problems.
Skills acquired (at the end of the course):
Realization of a project as the solution of an actual problem by using logic programming methodologies and Prolog language.
Prerequisites
None
Teaching Methods
Total hours of the course (including the time spent in attending lectures, seminars, private study, examinations, etc...): 150
Hours reserved to private study and other indivual formative activities: 102
Further information
Frequency of lectures, practice and lab: Recommended
Teaching Tools
UniFi E-Learning: http://e-l.unifi.it
Exam modality:
Oral exam and discussion of an elaborate (in Prolog).
Course program
Course Contents (detailed programme):
Syntactic unification among terms and its decidability.
Proof theory. Hilbert Calculus. Normal forms of formulas, clausal form. Herbrand Algebra and Herbrand theorem. Proof by refutation, Resolution Calculus for general clauses, its correctness and completeness.
Horn clauses Logic.
Logic Programming and SLD Resolution.
Operational semantics of logic programming. The negation: SLDNF resolution.
Prolog language.
Applications: difference lists and DCG, terms manipulation, interpreter/compiler construction.