Title:

Functional and Logic Programming

Code:FLP
Ac.Year:ukončen 2006/2007
Term:Summer
Curriculums:
ProgrammeBranchYearDuty
EI-MSC-3VTN3rdElective
EI-MSC-5VTI2nd Stage/3rd YearElective
Language:Czech
Public info:http://www.fit.vutbr.cz/study/courses/FLP/public/
Private info:http://www.fit.vutbr.cz/study/courses/FLP/private/
Credits:5
Completion:accreditation+exam (written)
Type of
instruction:
Hour/semLecturesSem. ExercisesLab. exercisesComp. exercisesOther
Hours:26001214
 ExaminationTestsExercisesLaboratoriesOther
Points:60200020
Guarantee:Kolář Dušan, doc. Dr. Ing., DIFS
Lecturer:Kolář Dušan, doc. Dr. Ing., DIFS
Faculty:Faculty of Information Technology BUT
Department:Department of Information Systems FIT BUT
Prerequisites: 
Programming Languages (PRJ), DIFS
 
Learning objectives:
  Obtaining of basic knowledge and experience in functional and logic programming. Introduction into formal concepts used as a theoretical basis for both paradigms.
Description:
  Practical applications and broader introduction into lambda calculus and predicate logic within the context of functional and logic programming languages. It will be discussed abstract data types, use of recursion and induction, manipulation of lists and infinite data structures. Experience in programming is gained in programming languages Haskell, Prolog, and Goedel. Moreover, principles of their implementation are mentioned too.
Knowledge and skills required for the course:
  Processing (analysis, evaluation/interpretion/compilation) of programming languages, predicate logic.
Subject specific learning outcomes and competences:
  Students will get basic knowledge and practical experience in functional and logic programming (two important representatives of declarative programming). Moreover, they will get basic information about theoretical basis of both paradigms and implementation techniques.
Generic learning outcomes and competences:
  Use and understanding of recursion for expression of algorithms.
Syllabus of lectures:
 
  • Introduction to functional programming, lambda calculus
  • Programming language Haskell, introduction, lists
  • User-defined data types, type classes, arrays
  • Input/Ouput
  • Simple applications/programs
  • Proofs in functional programming
  • Denotational semantics, implementation of functional languages
  • Introduction to logic programming, Prolog
  • Lists, cut operator, sorting
  • Data structures, text strings, operators
  • Searching state space, clause management, parsing
  • Goedel
  • Implementation of logic languages, CLP, conclusion
Syllabus of computer exercises:
 
  • Introduction to Haskell environment (Hugs), simple functions, recursion, lists
  • Infinite data structures
  • User defined data types, input/output
  • Practical problem
  • Introduction to Prolog environment (Hugs), lists
  • Practical problem
Syllabus - others, projects and individual work of students:
 
  1. A simple program in Haskell programming language (Hugs, GHC, GHCi).
  2. A simple program in Prolog/Gödel/CLP(R) (SWIPL, Gödel, CiaoProlog).
Fundamental literature:
 
  • Thompson, S.: Haskell, The Craft of Functional Programming, ADDISON-WESLEY, 1999, ISBN 0-201-34275-8
  • Hill, P., Lloyd, J.: The Gödel Programming Language, MIT Press, 1994, ISBN 0-262-08229-2
Study literature:
 
  • Lecture notes in electronic format
  • Haskell (Hugs) language tutorial, http://www.haskell.org
  • SWI-Prolog language tutorial, http://www.swi-prolog.org
Controlled instruction:
  
  • Mid-term exam - written form, questions and exersises to be answered and solved (there are even questions with selection of one from several predefined answers), no possibility to have a second/alternative trial - 20 points.
  • Projects realization - 2 projects, implementation of a simple program according to the given specification - one in a functional programming language the other in a logic programming language - 20 points all together.
  • Final exam - written form, questions and exersises to be answered and solved (there are even questions with selection of one from several predefined answers), 2 another corrections trials possible - 60 points.
Progress assessment:
  
  • Mid-term exam, for which there is only one schedule and, thus, there is no possibility to have another trial.
  • Two projects should be solved and delivered in a given date during a term.
Exam prerequisites:
  At the end of a term, a student should have at least 50% of points that he or she could obtain during the term; that means at least 20 points out of 40.