====== Logic and Constraint Programming ====== ---- ===== News ===== * Guidelines for the projects' presentations: date and time: 3rd of June, 14:00-16:00; venue: https://unicam.webex.com/meet/francesco.tiezzi; presentation of the work: I expect a presentation with slides, and a demo of the implemented application, you do not need to write a report; presentation duration: 15 minutes (20 minutes at most); material: please, send me the slides and the developed code (it is fine to send it the same day of the exam). * **13/4/2020**: the lectures of 14 and 15 March are postponed; the updated schedules of the next lectures is reported below. * **24/3/2020**: the lecture of 24 March will start later; the beginning of the lecture is delayed to 10:00. * **17/3/2020**: the 3rd hour of the lecture of today is postponed, due to problem with Webex. * **11/3/2020**: please, install SWI Prolog in your machine: https://www.swi-prolog.org/ * **10/3/2020**: first lecture (via Webex: https://unicam.webex.com/meet/francesco.tiezzi) * **Telegram channel: LCP1920@UNICAM** (link: https://t.me/unicam_lcp1920) ---- ===== General Info ===== **Teacher**: * [[https://docenti.unicam.it/pdett.aspx?ids=N&tv=d&UteId=990&ru=PA|Francesco Tiezzi]] **ESSE3 Link** * [[https://didattica.unicam.it/Guide/PaginaADErogata.do?cod_lingua=ita&ad_er_id=2019*N0*N0*S2*15669*9986&ANNO_ACCADEMICO=2019&mostra_percorsi=S|Logic and Constraint Programming - AY 2019/2020]] **Lessons schedule**: * Tue 9:00-12:00, AB1 * Wed 14:00-16:00, AB1 **Students Office hours**: * On appointment (via email), second floor of Polo Lodovici, via Madonna delle Carceri 9, Camerino ---- ===== Course Objectives ===== D1 – KNOWLEDGE AND UNDERSTANDING At the end of the course, the student should be able to: 1- Have the knowledge of the issues concerning logic and constraint programming. 2- Have the knowledge of the syntax and the semantics of the Prolog language. 3- Have the knowledge of the syntax and the semantics of the input languages of Drools. 4- Have the knowledge of the syntax and the semantics of the input languages of Minizinc. D2 – APPLYING KNOWLEDGE AND UNDERSTANDING At the end of the course, the student should be able to: 1- Writing logic programs in Prolog. 2- Writing rule-based programs in Drools. 3- Writing constraint-based programs in Minizinc. 4- Understand technical manuals on the languages and tools presented in the course and similar ones. D3 – MAKING JUDGEMENTS At the end of the course, the student should be able to: 1- Identify the best language suitable for describing the logic of an intelligent system. D4 - COMMUNICATION SKILLS At the end of the course, the student should be able to: 1- Describe in a clear way the behaviour of a logic- and constraint-based program. 2- Write a brief survey and state of the art about a given research topic related to constraint and logic programming by searching the scientific literature. D5 – LEARNING SKILLS At the end of the course, the student should be able to: 1- Search the scientific literature for specific advances in languages and tools for logic and constraint programming. 2- Autonomously understand and learn to use new features added to tools for logic and constraint programming. ---- ===== Course Contents ===== * Logic programming: basic concepts and Prolog language * Rule-based programming: Drools * Constraint programming: Minizinc ---- ===== Study material ===== **Course Slides** * {{ :didattica:magistrale:lcp:ay_1920:lcp_intro1920.pdf |General Info and Introduction}} * {{ :didattica:magistrale:lcp:ay_1920:lpnchapter1.pdf |LPN chapter1}} * {{ :didattica:magistrale:lcp:ay_1920:lpnchapter2.pdf |LPN chapter2}} * {{ :didattica:magistrale:lcp:ay_1920:lpnchapter3.pdf |LPN chapter3}} * {{ :didattica:magistrale:lcp:ay_1920:lpnchapter4.pdf |LPN chapter4}} * {{ :didattica:magistrale:lcp:ay_1920:lpnchapter5.pdf |LPN chapter5}} * {{ :didattica:magistrale:lcp:ay_1920:lpnchapter6.pdf |LPN chapter6}} * {{ :didattica:magistrale:lcp:ay_1920:lpnchapter10.pdf |LPN chapter10}} * {{ :didattica:magistrale:lcp:ay_1920:minizinc.pdf |Minizinc}} * {{ :didattica:magistrale:lcp:ay_1920:drools.pdf |Drools}} **Lectures** * 10/03/2020: general info, SWI Prolog, Declarative Programming, History of Prolog, examples ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/606501b1c9804ef19e766a5de981b7a3|recorded lecture]]). * 11/03/2020: Prolog syntax, exercises ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/604afb43d16c4ef59a8b1cd393a95b94|recorded lecture]]) * 17/03/2020: unification [[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/224a656cbc1246f0b4d21cc8a5abdaf5|recorded lecture 1]] [[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/95b5d1730f22425ab5fe49b9c811854d|recorded lecture 2]] * 18/03/2020: exercises, proof search [[https://drive.google.com/open?id=13gvxX0Ziv5w93xsQ1IqOF5qCQwTMlxeD|recorded lecture]] * 24/03/2020: proof search examples; recursion [[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/f125e84d118d46ee81179534ed007825|recorded lecture]] * 25/03/2020: recursion [[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/44c51e71ace14caf84198e5cca263e24|recorded lecture]] * 31/03/2020: exercises on recursion; lists ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/789bbfe0f0284fecb2ffbfc1068747e2|recorded lecture]]) * 01/04/2020: exercises on lists, arithmetics ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/c2ee511add8049d9bfbd62e6dbb68f87|recorded lecture]]) * 07/04/2020: accumulators and append, exercises ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/515f95e292794389a7d31e9ffe35e5de|recorded lecture]]) * 08/04/2020: cut and negation ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/5dc73c6569a94bfd9cc83f762b49ed85|recorded lecture]]) * 21/04 (09:00-12:00): Partial exam on Prolog. * 22/04 (14:00-16:00): Minizinc 1 ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/f190416230f14a79ab02048400775a34|recorded lecture]]) * 28/04 (09:00-12:00): Minizinc 2 ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/827c0c131ba043efa015753b3a276988|recorded lecture]]) * 29/04 (14:00-16:00): Minizinc 3, Drools 1 ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/62e255ff3792427ba5eabbeb49b62965|recorded lecture]]) * 05/05 (09:00-12:00): Drools 2 ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/6d69de9a092748f8968351a7d6e919a8|recorded lecture]]) * 06/05 (14:00-16:00): Drools 3 ([[https://unicam.webex.com/recordingservice/sites/unicam/recording/playback/2d0bc1a0fecf48b0a5b80805de179db3|recorded lecture]]) * 12/05 (09:00-11:00): Discussion about projects. * 26/05 (09:00-10:00): Discussion about projects. * 03/06 (14:00-16:00): Projects' presentations. /* **Practical sessions** * 11/03/2020: {{ :didattica:magistrale:lcp:ay_1920:20200311_exercises.zip |exercises}} - {{ :didattica:magistrale:lcp:ay_1920:20200311_solutions.zip |solutions}} * 18/03/2020: {{ :didattica:magistrale:lcp:ay_1920:exercises_2.zip |exercises}} {{ :didattica:magistrale:lcp:ay_1920:ex2.4_solution.pl.zip |solution}} * 31/03/2020: {{ :didattica:magistrale:lcp:ay_1920:lcp1819_ex3.zip |exercises}} {{ :didattica:magistrale:lcp:ay_1920:ch3_solutions.zip |solutions}} * 01/04/2020: {{ :didattica:magistrale:lcp:ay_1920:exercise_ch4.zip |exercises}} {{ :didattica:magistrale:lcp:ay_1920:solutions_ch4.zip |solutions}} * 07/04/2020: {{ :didattica:magistrale:lcp:ay_1920:exercises_ch5_lcp2020.zip |exercises}} {{ :didattica:magistrale:lcp:ay_1920:exercises_ch5_solutions_lcp2020.zip |solutions}} {{ :didattica:magistrale:lcp:ay_1920:homework.zip |homework}} {{ :didattica:magistrale:lcp:ay_1920:ex6_solution_lcp20.zip |solution}} * 08/04/2020: {{ :didattica:magistrale:lcp:ay_1920:ex10_lcp20.zip |exercise}} */ **Reference books** The main material of the course consists of: * Stuart J. Russell and Peter Norvig. Artificial Intelligence A Modern Approach. Third Edition. Pearon, 2016. * Patrick Blackburn, Johan Bos, Kristina Striegnitz. Learn Prolog Now! 2001 * Tutorial of Drools, Minizinc. * Course's slides. Moreover, lecture notes, papers and slides may be given by the teacher for studying and for exercises. ---- ===== Exams ===== **Exam Dates A.Y. 2015/2016** * Winter session dates here * Summer session dates here * Autumn session dates here * Winter session dates here (2016) **Exam rules**: ** Exam Results ** * N/A