GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - DumpAnalysis/DSLsofMath: Domain-Specific Languages of Mathematics

BranchesTags
Open more actions menu
 
 

Latest commit

 

History

1,990 Commits
1,990 Commits

Folders and files

NameName
Last commit message
Last commit date
Exam
Exam
 
 
L
L
 
 
PedProj
PedProj
 
 
Wisla23
Wisla23
 
 
admin
admin
 
 
old
old
 
 
.gitignore
.gitignore
 
 
DSL_def.txt
DSL_def.txt
 
 
LICENSE
LICENSE
 
 
Lectures
Lectures
 
 
README.md
README.md
 
 

Repository files navigation

Domain-Specific Languages of Mathematics

GitHub repository for open source material related the book "Domain-Specific Languages of Mathematics" published in 2022 by College Publications (available from Adlibris.se, Amazon UK, Amazon.com.

The book and the repository are used in a BSc-level course at Chalmers and GU.

The main course homepage (2026) is in the Canvas LMS:

  • 2026: Main course page

Course codes: DAT326 / DIT983

News

  • 2026-03-21: Course discontinuation and future exams: The 2026 instance was the final ordinary run of the course. If you still need to pass the exam, please read the important information regarding the transition period and upcoming re-exam opportunities.
  • 2026-01-20: First lecture of the 2026 course instance.
  • 2022: Course book available from Amazon and from other sources. Bibtex entry.
  • Lecture note snapshots with drafts of the full course book
  • YouTube playlist collecting the 2022 lectures (all in English)
    • Also available: the recorded lectures from the 2021 course instance (most in Swedish, some in English).

Contributors

  • Main author, examiner, lecturer: Patrik Jansson (patrikj AT)
  • First version (and continued support): Cezar Ionescu (cezar AT)
  • Book co-author: Jean-Philippe Bernardy
  • Teaching assistants:
    • 2026: Freek Geerligs (geerligs AT), Jeremy Pope (popje AT)
    • 2025: Felix Cherubini (felixche AT), Freek Geerligs (geerligs AT)
    • 2024: Felix Cherubini (felixche AT), Freek Geerligs (geerligs AT), Rachel Samuelsson (lambda AT)
    • 2023: David Wärn (warnd AT), Felix Cherubini (felixche AT), Sikai Lu (sikai AT),
    • 2022: Sólrún Einarsdóttir (slrn AT), David Wärn (warnd AT), and Felix Cherubini (felixche AT)
    • 2021: Maximilian Algehed (algehed AT) and Víctor López Juan (lopezv AT)
    • 2020: Sólrún Einarsdóttir (slrn AT) and Víctor López Juan (lopezv AT)
    • 2019: Maximilian Algehed (algehed AT) and Abhiroop Sarkar (sarkara AT)
    • 2018: Daniel Schoepe (schoepe AT)
    • 2017: Frederik Hanghøj Iversen (hanghj AT student) and Daniel Schoepe (schoepe AT)
    • 2016: Irene Lobo Valbuena (lobo AT)
  • Project assistants: Daniel Heurlin, Sólrún Einarsdóttir, Adam Sandberg Ericsson (saadam AT)

where AT = @chalmers.se

Course material

This repository is mainly the home of the DSLsofMath book (originating from the course lecture notes), also available in print from Amazon.

Comments and contributions are always welcome – especially in the form of pull requests.

The main references are listed below.

Objectives

The course presents classical mathematical topics from a computing science perspective: giving specifications of the concepts introduced, paying attention to syntax and types, and ultimately constructing DSLs of some mathematical areas mentioned below.

Learning outcomes as in the course syllabus.

  • Knowledge and understanding
    • design and implement a DSL (Domain-Specific Language) for a new domain
    • organize areas of mathematics in DSL terms
    • explain main concepts of elementary real and complex analysis, algebra, and linear algebra
  • Skills and abilities
    • develop adequate notation for mathematical concepts
    • perform calculational proofs
    • use power series for solving differential equations
    • use Laplace transforms for solving differential equations
  • Judgement and approach
    • discuss and compare different software implementations of mathematical concepts

The course is elective for both computer science and mathematics students at both Chalmers and GU.

Course setup

  • Lectures
    • Introduction: Haskell, complex numbers, syntax, semantics, evaluation, approximation
    • Basic concepts of analysis: sequences, limits, convergence, ...
    • Types and mathematics: logic, quantifiers, proofs and programs, Curry–Howard, ...
      • Type classes, derivatives, differentiation, calculational proofs
    • Domain-Specific Languages and algebraic structures, algebras, homomorphisms
    • Polynomials, series, power series
    • Power series and differential equations, exp, sin, log, Taylor series, ...
    • Linear algebra: vectors, matrices, functions, bases, dynamical systems as matrices and graphs
    • Laplace transform: exp, powers series cont., solving PDEs with Laplace
  • Weekly exercise sessions
    • Half time helping students solve problems in small groups
    • Half time joint problem solving at the whiteboard

Lectures

The latest PDF snapshot of the book can be found in L/snapshots but please also consider buying the "real thing".

The "source code" for the chapters are in subdirectories of L/: L/01/, L/02/, etc. where chapter N is approximately course week N.

Exercises

Most chapters end with weekly exercises.

In L/RecEx.md you will find a list of recommended exercises for each chapter of the lecture notes.

Exams

The exams + solutions are available under the Exam/ subdirectory:

  • 2016-Practice/, 2016-03/, 2016-08/,
  • 2017-03/, 2017-08/,
  • 2018-03/, 2018-08/,
  • 2019-03/, 2019-08/,
  • 2020-03/, 2020-08/,
  • 2021-03/, 2021-08/,
  • 2022-03/, 2022-06/, 2022-08/,
  • 2023-03/, 2023-06/, 2023-08/,
  • 2024-03/, 2024-06/, 2024-08/.
  • 2025-03/, 2025-06/, 2025-08/.
  • 2026-03/, 2026-06/, TODO 2025-08/.

References

Some important references:

Functional programming

  • Thinking Functionally with Haskell, Richard Bird, Cambridge University Press, 2014 URL
  • Introduction to Functional Programming Using Haskell, Richard Bird, Prentice Hall, 1998. A previous (but clearly different) version of the above.
  • An Introduction to Functional Programming, Richard Bird and Phil Wadler, Prentice Hall, 1988. A previous (but clearly different) version of both of the above.

DSLs

  • Functional Programming for Domain-Specific Languages, Jeremy Gibbons. In Central European Functional Programming School 2015, LNCS 8606, 2015. URL

    This is currently the standard reference to DSLs for the functional programmer.

  • Folding Domain-Specific Languages: Deep and Shallow Embeddings, Jeremy Gibbons and Nicolas Wu, ICFP 2014. URL

    Available at the same link: a highly recommended short version and the two videos of Jeremy presenting the most important ideas of DSLs in a very accessible way.

  • Programming Languages, Mike Spivey. Lecture notes of a course given at the CS Department in Oxford. Useful material for understanding the design and implementation of embedded DSLs. URL

  • Domain-Specific Languages, Martin Fowler, 2011. URL

    The view from the object-oriented programming perspective.

The computer science perspective

  • Communicating Mathematics: Useful Ideas from Computer Science, Charles Wells, American Mathematical Monthly, May 1995. URL

    This article was one of the main triggers of this course.

    Short summary of the recommendations

Mathematics

  • The Language of First-Order Logic, 3rd Edition, Jon Barwise and John Etchemendy, 1993. Out of print, but you can get it for one penny from Amazon UK. A vast improvement over its successors (as Tony Hoare said about Algol 60).

  • Mathematics: Form and Function, Saunders Mac Lane, Springer 1986. An overview of the relationships between the many mathematical domains. Entertaining, challenging, rewarding. Fulltext from the library

  • Functional Differential Geometry, Gerald Jay Sussman and Jack Wisdom, 2013, MIT. A book about using programming as a means of understanding differential geometry. Similar in spirit to the course, but more advanced and very different in form. An earlier version appeared as an AIM report.

License: CC-BY-NC-SA 4.0

Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

About

Domain-Specific Languages of Mathematics

Resources

Readme
License
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.