The aim of this course is to introduce you to the theory and practice of logic programming. We teach it in two parts:

**Logic programming - theory:**lectures given by Richard Mayr**Logic programming - programming:**lectures given by James Cheney

There will be 18 lectures, starting Monday 15th September 2014.

** Lectures are in Lecture Theatre 4 of 7 Bristo Square.**

Lectures take place 1510-1600 on Mondays and Thursdays in weeks 1-4 and 6-10 of Semester 1. (Note that
there are **no** lectures in week 5, i.e., no lectures on 13th and 16th October.)

Tutorials are held in weeks 3-10. (Note that tutorials take place as usual in Week 5.)

There will be two, summatively assessed, coursework exercises; each worth 10% of the final grade.

Week |
Begins |
Mon Lec |
Thu Lec |
Tutorials |
Coursework (CW) |

1 | 15 Sep | Theory 1 | Prog 1 | ||

2 | 22 Sep | Prog 2 | Prog 3 | ||

3 | 29 Sep | Theory 2 | Prog 4 | Tut 1 | |

4 | 6 Oct | Theory 3 | Prog 5 | Tut 2 | CW1 handed out: Mon 6 |

5 | 13 Oct | Tut 3 | |||

6 | 20 Oct | Prog 6 | Theory 4 | Tut 4 | CW1 deadline: 3pm Mon 20 |

7 | 27 Oct | Theory 5 | Theory 6 | Tut 5 | CW2 handed out: Mon 27 |

8 | 3 Nov | Theory 7 | Prog 7 | Tut 6 | |

9 | 10 Nov | Theory 8 | Prog 8 | Tut 7 | CW2 deadline: 3pm Mon 10 |

10 | 17 Nov | Theory 9 | Prog 9 | Tut 8 |

The course lecturers are available (during Semester 1) for discussion of course material at the following hours.

- Richard Mayr (IF 4.11): TBA.
- James Cheney (IF 5.29): TBA.

Other useful books on prolog programming are

*Programming in Prolog*by Clocksin and Mellish, Springer. (There are many copies of this in the University library.)-
*The Art of Prolog*by Sterling and Shapiro, MIT Press *Prolog Programming for Artificial Intelligence*by Ivan Bratko, Addison Wesley.

For the theory lectures, the following background material on propositional and predicate will be useful for students who have not previously encountered propositional and predicate logic.

- Wikipedia page on
*Propositional calculus* - Wikipedia page on
*First-order logic* - Wikipedia page on
*Structure (mathematical logic)* - Introductory slides (pdf) on
*Predicate logic and quantifiers*from University of Nebraska

SICStus Prolog is recommended for use in the course and will be
used for the final exam. Any DICE machine (i.e. any Linux machine in
an Informatics computer lab) should have SICStus installed; type
`sicstus`

at a command prompt to start.

The School also has a site license for student use, in case you would prefer to install and run SICStus on your own computer. Contact Computing Support in person or via this form to arrange this.

There is a good emacs mode for editing Prolog code and interacting with execution. To enable this mode for Prolog, add the following line to your .emacs file:

`(load "/opt/sicstus-4.2.0/lib/sicstus-4.2.0/emacs/sicstus_emacs_init" t)`

Then consulting a Prolog file will bring up a menu for Prolog features.

Programming lecture slides will be posted here as the course proceeds.

Theory lecture slides will be posted here as the course proceeds.

- Coursework 1 (programming) will be available October 6.
**Due: 3pm October 20.**

Returned to students: available to collect from ITO from November 3rd. - Coursework 2 (theory) will be available October 27.
**Due: 3pm November 10.**Marked scripts will be available to collect from ITO from November 24th.

Tutorials start Week 3 (September 30). The tutorial group times and membership will be posted early in the semester. Tutorial notes and solutions will also appear here as they become available.

Logic programming offers the following formative feedback:

- Interaction with tutors in tutorials provides general feedback on understanding.
- The week 5 tutorial will be a quiz tutorial. Solutions will be marked and discussed in tutorial.
- Both lecturers have office hours (see above) in which they are available to discuss any aspect of the course. You are very welcome to drop in either individually or in small groups (up to 3 students at a time).

Informatics Forum, 10 Crichton Street, Edinburgh, EH8 9AB, Scotland, UK
Tel: +44 131 651 5661, Fax: +44 131 651 1426, E-mail: school-office@inf.ed.ac.uk Please contact our webadmin with any comments or corrections. Logging and Cookies Unless explicitly stated otherwise, all material is copyright © The University of Edinburgh |