Functional Programming
Personal
Lecture | Prof. Dr. Peter Thiemann | thiemann@info... |
Exercise | Gabriel Radanne | radanne@info... |
Assistant | Felix Karg | kargf@info... |
News
2017-10-16 | Github page |
2017-10-04 | Homepage online |
Lecture Materials
Date | Content | Code | Recording |
---|---|---|---|
20171016 | 00-intro.pdf | none | |
20171016 | 01-starting-haskell.pdf | Examples (after lecture) | 720p480p |
20171018 | 03-haskell-types.pdf | Examples (before lecture) | 720p480p |
20171023 | 04-define-types.pdf | Examples (after lecture), M04TypeAliases.hs, M04Cards.hs (incomplete), | 03 continued (720p480p), 04 first part (720p480p) |
20171025 | 04 continued | M04Cards.hs (incomplete), | 04 next part (720p480p) |
20171030 | 04 continued, 05-more-about-lists.pdf | M05Lists.hs, | 04 last part (720p480p), 05 (720p480p) |
20171106 | 06, 06-higher-order.pdf | M06HO.hs, | 06 part 1 (720p480p), 06 part 2 (720p480p) |
20171108 | 07, 07-io.pdf | 06 part 3 (720p480p), 07 part 1 (720p480p) | |
20171113 | 08, 08-type-classes.pdf | 07 part 2 (720p480p), 08 (720p480p) | |
20171115 | 09, 09-test-data-generators.pdf | 09 (720p480p) | |
20171120 | 10, 10-monadic-interpreter.pdf | 10 (720p480p) | |
20171122 | 11, 11-parsing.pdf | M11-parser-20171122.lhs | 11 (720p480p) |
20171127 | 11, 11-parsing.pdf | M11-parser-20171128.lhs | 11 part 2 (720p480p) |
20171129 | 11, 11-parsing.pdf | M11-parser-20171129.lhs | 11 part 3 (720p480p) |
20171204 | 11-parsing.pdf, 12-lambda-calculus.pdf | M11-parser.lhs | 11 part 4 (720p480p), 12 part 1 (720p480p), |
20171206 | 12-lambda-calculus.pdf cont'd | 12 part 2 (720p480p), | |
20171211 | 13-evaluation-strategies.pdf and simple types | no recording (QuickTime failed) | |
20171213 | 13 continued/finished | no recording (audio input failed) | |
20171218 | 14-polymorphic-types.pdf | M14inference.hs | 14 part 2 (720p480p), discussion of the code (720p480p) |
20171220 | M14inference.hs | discussion of the code part 2 (720p480p) | |
20170108 | 15-monad-transformers.pdf | M15monadtransformers.hs | |
20170110 | 16-gadt.pdf | M16GADT.hs | |
20180117 | Data types a la carte (no slides) | M17alacarte.lhs | screen recording (720p480p) |
20180122 | Data types a la carte (cont) | M17alacarte.lhs | screen recording (720p480p) |
20180124 | Generic programming Generics for the Masses | M18generic.lhs | screen recording (720p480p) |
20180129 | Generic programming (cont'd), Purely functional data structures | M19functionaldata.lhs | screen recording (part 1: generics 720p480p), (part 2: purely functional data structures 720p480p) |
20180131 | Purely functional data structures (cont'd) | screen recording (720p480p) | |
20180205 | Purely functional data structures (cont'd), A taste of Agda (not relevant for exam) | Agda Tutorial | screen recording (data structures 720p480p) (Agda 720p480p) |
20180207 | A taste of Agda (not relevant for exam) | screen recording (Agda 720p480p) |
Note: "Recordings" are unedited screen recordings of the lecture. Only available inside Uni Freiburg network.
Exercises
Date of issue | Exercise Session | Solutions | ||
---|---|---|---|---|
2017-10-18 | n/a | Exercise 0 (Installation) | ||
2017-10-18 | 2017-10-25 | Exercise Sheet 1 - First steps | ||
2017-10-25 | 2017-11-08 | Exercise Sheet 2 - Recursion, Datatypes Tracks.hs | ||
2017-11-20 | 2017-11-22 | Exercise Sheet 3 - Datatypes, Typeclasses Logs.hs | Pics.hs | |
2017-11-27 | 2017-11-29 | Exercise Sheet 4 - High order functions, IO | StackCacl.hs | |
2017-12-11 | 2017-12-13 | Exercise Sheet 5 - Parsing ParserCon.hs MiniWhile.hs | ||
2017-12-18 | 2017-12-20 | Exercise Sheet 6 - State monad | SolutionEx6.hs SolutionMiniWhile.hs | |
2017-01-08 | 2017-01-10 | Exercise Sheet 7 - Monads, Monad transformers | ||
2017-01-22 | 2017-01-24 | Exercise Sheet 8 - GADTs | ||
2017-01-29 | 2017-01-31 | Exercise Sheet 9 - Data Types à la carte |
Project
The description of the project is available here.
The regex test library is RegexTestLib.hs.
07/02/2018: Fix in Figure 4, The definition of derive(r*) was erronous.
14/02/2018: Add the testsuite, along with some documentation.
Content
This course conveys fundamental concepts of functional programming using the programming language Haskell.
Goal
Learning objectives from the module compendium: “Development of an alternative non-procedural view on algorithms and data structures, confident handling of higher-order functions and data, knowledge and ability to apply fundamental functional programming techniques, knowledge of advanced programming concepts, ability to develop medium-size functional programs independently.”
Topic List
- Definition of functions, pattern matching, higher-order functions
- Types and type classes
- Algebraic data types
- Functional data structures
- Applicative parsers
- Monads and monad transformers
- Arrows
- Verification of functional programs
- Monadic I/O and stream I/O
Preliminaries
Interest in programming and in learning and applying new programming concepts and languages. No previous knowledge of Haskell is required.
Literature
The book Programming in Haskell by Graham Hutton is the basis for the first 30% of the lecture. This book is available in the TF-library.
Stephen Diehl's WHAT I WISH I KNEW WHEN LEARNING HASKELL
Organization
Schedule
Lecture | Mo 14-16 ct | Geb. 101 - SR 01-016 |
We 14-15 ct | Geb. 101 - SR 01-016 | |
Exercise | We 15-16 ct | Geb. 101 - SR 01-016 |
Modality of exercise
Exercise sheets are added to the website one week in advance. Exercises are not graded and solutions do not have to be sent for evaluation. If you want to check your work, you are of course welcome to ask during the exercise sessions or by email. It is expected that each student work on each exercise sheet. You thus have to demonstrate that you are following the exercises, either physically by comming to the exercises sessions or digitally by sending an email showing your progress. Solutions will be provided "on demand" for specific exercises.
Preliminaries
To be admitted to the exam, each participant has to process every exercise sheet. If participants cannot come up with a useful answer to the exercise, they should submit a rationale instead.
Exam
If there are less than 20 registrations for the exam, there will be an oral exam during the examination period. Otherwise, there will be a written exam (closed book). We offer a graded programming project at the end of the teaching period. Students who pass the final exam can improve their grade with a passed programming project.
Communication
Announcement will be posted on this page under the rubric News. Urgent announcements will also be sent via email through HisInOne. If you do not want to miss these announcements, you should register for the course in HisInOne!