2IPH0       Declarative programming                                     20170704 

Running in this theatre: 2016/17 Q3

This web page will be under construction permanently

for questions and other communication
contact
j.c.s.p.v.d.woude@tue.nl

NEW  20170421 Exam and solutions (pdf)

NEWER  20170704 Exam and solutions (pdf)

This course is an experimental pilot, so any remark and criticism is welcomed warmly and easily dealt with by referring to the experimetal character.

The webpage should inform you on the course, its materials, duties and possibilities. So most of it will consist of  references and directives, can't make it much cosier.

Some details

The course runs in quartile 3 block E (Tuesday afternoon and Thursday morning).
Responsible staff: Jaap van der Woude and Arthur van Goethem
level 3 , 5ects, exam and assignment  (70%-30%)
Roomservice: Tuesdays 5+6 in MF14
Exam date: yet to be defined.


Study guide

In order to  define the course content and help you study it there is a study guide, with a definition of the subject and material to study it per week. The guide will grow but now only addresses the first two weeks.
study guide

It is very important to get to grips with the literature mentioned in the study guide, but it is evenly important to do the exercises. So we have a host of exercises. The study guide mentiones what exercises are relevant. Some are in the literature for the subject, but most are from the reader of 2IA05 the old course in functional programming. For the moment not every exercise has been translated, but within a few days they will be.
exercises


General references

There are many places to get your fp-knowledge from. Mr Google will help you, so do we by presenting a few references here.

books

We do not really use books, but it doesn't hurt to have some.
Some of them are available on line
paperware
Graham Hutton, Programming in Haskell, snd edition
Richard Bird, Thinking functionally with Haskell,
Simon Thompson, Haskell, the craft of functional programming
Paul Hudak, School of expression   (slightly old but interesting for music lovers)
Simon Peyton Jones, Haskell 98 language and libraries   (unreadable, only for reference)
online
Wikibooks, Haskell,  pdf       extensive but informative (~600 pages)
Real world Haskell,   url         idem
Miran Lipovaca, Learn you a Haskell for great good, pdf     ( too informal and too easy going)
Hal Daume III, yet another Haskell tutorial,  pdf  (?)

Weekly references

The literature mentioned in the study guide is here refered to. The list will grow soon.
All of the nonlocal papers are available freely, but the reference here is to a local store.

week1

2IA05, A quicky on lambda calculus,  pdf
Raul Rojas, A tutorial introduction to lambda calculus,  pdf
slides 2IA05 on lambda calculus , pdf
Paul Hudak, A gentle introduction to Haskell , pdf
Graham Hutton, powerpoint slides ch1, ch 2, ch4  (with greatly acknowledged permission)
Haskell standard  prelude, htm
sudoku.hs, testEnSStack.hs  Haskelll scripts to play around with in GHCi

week2

Predefined types, ch 6 from the Haskell report, htm
Graham Hutton powerpoint slides ch3, ch10
inductive sets, the algebraic way, pdf
polymorphic typing, pdf
slides 2IA05 2007/8, pdf
Wadler, theorems for free, pdf

week3

Wikipedia about recursion, htm
Graham Hutton, powerpoint slides, ch 5, ch6, (ch7)
how to work on lists-HaskellWiki, pdf
tupling, pdf
accumulation, pdf
Huffman coding exercise, pdf

week4

Graham Hutton, powerpoint slides, ch7
Graham Hutton, A tutorial on the universality and expressiveness of fold, pdf
Inductive sets, the algebraic way, pdf
slides 2IA05 on inductivity, pdf
additional slides on foldn, pdf
Jeremy Gibbons, Calculating functional programs, ch 5 of algebraic and coalgebraic methods in the mathematics of program construction, pdf

week5

Graham Hutton, powerpoint slides,  ch9
Learn you a Haskell for great good ch 9.1-3, pdf
A gentle introduction to Haskell-IO, htm
Yann Esposito, Yblog- learn Haskell Fast and Hard, htm
Nim exercise, pdf  more files in the directory nim

Graham Hutton, powerpoint slides, ch8
2IA05 parserslides, pdf
Hutton-Meijer, monadic parser combinators, pdf
Pico exercise, pdf  more files in the directory pico

week6

Dan Piponi, You could have invented monads, pdf
Rik and Jaap, Monaatje, pdf
HaskellWiki monads, three papers (monads, as containers, as computation), pdf
Wikibooks monads and categories, two papers, pdf
All about monads, pdf
Brent Yorgey, Typeclassopedia, pdf

Rik and Jaap, standard algorithms, three papers,  pdf

week7

Rik and Jaap, Streams, pdf

week8 (voluntary, optional, not for exam)

Rik van Geldrop, Bird's eye view of Logic Programming, pdf
Eugen Schindler, Getting started with SWI, pdf
lpexercises, pdf
prolog files, dir

Solutions to exercises

In my perception of a self-tuition course students ought to do the exercises themselves and the teacher should provide some solutions to inform the students about the style and content. Let me stress that solutions are not to be read before you do the exercise, it only is useful and informative if you first try to solve the problems yourself.
I will provide solutions after the corresponding exercise sessions.

Not every exercise has a latexed solution, but many do. A draw back may be that many of the solutions are Dutch. We hope it still is useful for non-dutch speaking students. The calculations and formulae are the same in all languages.

V,  PL,  
TB,  S,  A

Some other parafernalia

On the introduction of the course on 20170207  in  MF14, 15 students were present. The others may want to refer to my cheat sheets.
intro slides

In order to work with the soft ware, you have to get it and install it. The process  is described in
installation remarks

Arduin mentioned that the proud Mac OS user might want to get 'homebrew' from
www.brew.sh
Just type and run in your terminal
brew install ghc cabal-install

For those interested in the genesis of the course: here is the definition of it after adaptation to several boundary conditions.
Text of course definition