April 28, 2006
See the solutions
to the exam.
April 24, 2006
The scores for the exam
Contact me if you are interested in a meeting to discuss the questions of the exam.
April 12, 2006
See the results
of the ant tournament.
April 3, 2006
The lecture about GADTs is rescheduled
to Friday (for personal reasons). All students have
been informed by email.
March 30, 2006
The deadline for exercise 4 is rescheduled to April 5 (Wednesday). See Kasper's instructions
building hat on the student machines.
March 17, 2006
The fourth (and last) exercise about testing and tracing
is now online.
March 15, 2006
The final exam for AFP has been scheduled. See the Education Page
March 7, 2006
The third exercise on Template Haskell
March 1, 2006
for the wxHaskell docs.
February 27, 2006
The second exercise about XTC
has been published.
February 20, 2006
The Course Schedule
has been slightly changed for week 8.
February 16, 2006
Tomorrow, there will be no lab session after the lecture.
February 14, 2006
The start version for the Programming Assignment
has been put on the Wiki.
February 13, 2006
The first exercise (state monad
) has been published.
February 10, 2006
The DSL topics
have been assigned.
January 20, 2006
Setup of AFP web for 2005/2006
All students have to further investigate one domain specific language: the available topics are listed below, and these will
be assigned in the first week. For each topic, a number of starting points (web sites, papers, etc.) are given. Given these
starting points, try to find
as much relevant information as possible about your assigned topic. The task consists of two parts:
- One 45 minute presentation (in English). You are encouraged to download existing software, to experiment with it, and to show us a (small) demo.
- A review report (about 2 pages). This report should contain at least the following ingredients.
- a summary
- the additional gain of embedding your assigned DSL in a functional language like Haskell.
- your opinion about and experiences with the combinator library.
For this assignment, students may work in pairs. The assignment may also be completed individually, as long as there are enough topics available.
1. XML Tools
A number of Haskell libraries exist for processing XML. These libraries typically offer facilities such as parsing, filtering, transforming, validating, and generating XML documents. Two well-known combinator libraries for processing XML are HaXML
and The Haskell XML Toolbox.
2. Computer Music
(from the Haskore Computer Music System homepage
Haskore is a collection of Haskell modules designed for expressing musical structures in the high-level, declarative style of functional programming. In Haskore, musical objects consist of primitive notions such as notes and rests, operations to transform musical objects such as transpose and tempo-scaling, and operations to combine musical objects to form more complex ones, such as concurrent and sequential composition. From these simple roots, much richer musical ideas can easily be developed.
3. Diagram Editor Blobs
(from the Blobs homepage
Blobs is a front-end for drawing and editing graph diagrams. You must add your own back-end engine if you want it to do some analysis or processing of the graph. There are various analysis engines that use Blobs as a front-end, e.g. Dazzle for bayesian analysis of networks, FPTC for safety analysis of systems designs, and so on, but these are not currently available as open source. We do supply a couple of very simple engines, just to demonstrate how to connect the engine up to Blobs.
4. Haskell DB
(from the Haskell DB homepage
Haskell DB is a combinator library for expressing queries and other operations on relational databases in a type safe and declarative way. All the queries and operations are completely expressed within Haskell, no embedded (SQL) commands are needed. This close integration makes it possible to do arbitrary computations on the database (like computing the transitive closure) and makes it very easy to combine Haskell DB with other combinator libraries (like Erik Meijer's CGI library or John Hughes pretty printer).
5. Financial Combinators
(from Simon PJ's homepage
Financial and insurance contracts do not sound like promising territory for functional programming and formal semantics, but in fact we have discovered that insights from programming languages bear directly on the complex subject of describing and valuing a large class of contracts.
We introduce a combinator library that allows us to describe such contracts precisely, and a compositional denotational semantics that says what such contracts are worth. We sketch an implementation of our combinator library in Haskell. Interestingly, lazy evaluation plays a crucial role.
(from the Pan# homepage)
Pan# combines basic mathematical operations with functional abstraction and a simple vocabulary of images. This language puts the tools of visualization in the hands of the student and instructor rather than hiding them deep inside bundled software. Images are defined in a very simple and direct way, free of the details that tell a computer how to display the image. Because images are described using mathematical functions, this language is entirely appropriate for anyone with knowledge of basic algebra.
7. Pretty Printing
There are a number of combinator libraries around for pretty printing. Papers by
John Hughes and Philip Wadler describe the theory behind these libraries.
8. Web Authoring System Haskell
WASH/CGI is an EDSL for server-side Web scripting with Sessions, Compositional Forms, and Graphics.
9. Web Functions
Robert van Herk wrote his Master's thesis about Web Functions
Web Functions is a DSEL for developing websites, implemented in Haskell. Web Functions is a domain specific embedded language for web authoring, implemented in Haskell. The functionality of the Web Functions framework was inspired by Apple’s Web Objects (http://www.apple.com/WebObjects
(from the Yampa homepage)
Yampa is the culmination of our efforts to provide domain-specific embedded languages for the programming of hybrid systems using the concepts of Functional Reactive Programming (FRP). Yampa is structured using arrows, which greatly reduce the chance of introducing space- and time-leaks into reactive, time-varying systems.
Yampa was used to program the game entities of Frag, a 3D first person shooting game written in Haskell, by Mun Hon Cheong.
(These can only be selected in case we run out of topics)
This article presents one approach to declarative programming of interactive content, as realized in a prototype system called Fran, for "Functional reactive animation" [Elliott and Hudak 1997, Elliott 1997]. Fran is a high level vocabulary that allows one to describe the essential nature of an animated model, while omitting details of presentation. Moreover, because this vocabulary is embedded in a modern functional programming language (Haskell), the animation models thus described are reusable and composable in powerful ways.
Lava is a hardware description language based upon the functional programming language Haskell. Its main aim is to show that modern programming language features such as type inference, polymorphism, higher-order functions, type classes, and laziness are very useful even in hardware description.