C339: An Introduction to programming in Prolog

To introduce the student to the Prolog programming language. This includes both reaching a level of competence in programming and also understanding the meaning of such programs. It is intended to provide the student with an alternative tool for solving problems of a symbolic non-numeric type such as problems encountered in Artificial Intelligence.

Term Prerequisites Core For
1 Basic computing skills and knowledge of Unix and text editing N/A

Taught By

Mark Levene (1)

Syllabus

An overview of Prolog. Prolog is a declarative language as opposed to a procedural language such as C++ for symbolic non-numeric computation. The philosophy of Prolog is that deduction = computation that is programming in Prolog is the activity of po· An overview of Prolog.

· The components of a Prolog program.

· The syntax of Prolog. The meaning of a Prolog program.

· Lists; the Prolog list structure and useful list operations. Structures which generalise lists into data objects having several components. Two classical problems; the eight queens problem and the four colours problem; solved using Prolog.

· Elementary arithmetic operations. Basic operators and some examples of their use. Input and output in Prolog.

· Prolog queries and the mechanism of backtracking. How the programmer can control backtracking mainly in order to obtain a more efficient program. The infamous cut operator and examples of "green" and "red" cuts.

· Application areas of Prolog; knowledge-based systems and cognitive science. The relationship between logic and Prolog; parsing of simple natural-language sentences and finding of optimal routes in structures (e.g. maps of city underground train networks) where heuristics or "rules of thumb" influence what is optimal and what is not.

Assessment

Weighting No. Exam Questions No. Courseworks
30% coursework, 70% examination 6 at least 3

Examination Rubric

TBN

Reading list

Recommended Text: I. Bratko, Prolog: Programming for Artificial Intelligence, 2nd Ed. Addison-Wesley, 1990. W.F. Clocksin, C.S. Mellish, Programming in Prolog, 3rd Ed., Springer-Verlad, 1987. H. Konigsberger, F. de Bruyn, Prolog from the beginning, McGraw-Hill, 1991. K.A. Bowen, Prolog and Expert Systems, McGraw-Hill, 1990. K.A. Bowen, Prolog and Expert Systems, McGraw-Hill, 1991. L. Sterling, E. Shapiro, The Art of Prolog, MIT Press, 1986.