OCAML Teaching Resources

carlos-molina edited this page Dec 16, 2014 · 90 revisions

Recommended Textbooks

List of OCAML books [More books]

List of books on Awesome OCaml repo

Downloadable books

  • Developing Applications With Objective Caml. By Emmanuel Chailloux and Pascal Manoury and Bruno Pagano

  • Think OCaml: How to Think Like a (Functional) Computer Scientist, by Allen Downey and Nicholas Monje.

  • Unix System Programming in OCaml

  • Using, Understanding, and Unraveling OCaml

Using, Understanding, and Unraveling The OCaml Language by Didier Rémy

Programmation du système Unix en Objective Caml (in French)

A Concise Introduction to Objective Caml

[Introduction to Objective Caml, by Jason Hickey, 2008] (http://courses.cms.caltech.edu/cs134/cs134b/book.pdf)

Lab

Toolkits

In the browser

Run and explore OCaml without installing it.

  1. A compiler from OCaml bytecode to Javascript
  2. Try OCaml
  3. Compile OCaml Online
  4. Codepad
  5. Run OCaml Code Online

Understanding the OCaml top-level (interactive) system

To use the OCaml top level system effectively it is advisable to understand its inputs and outputs.

  1. [Formal description of OCaml top level system] (http://caml.inria.fr/pub/docs/manual-ocaml-400/manual023.html)
  2. [Explanation of the output of the OCaml top level system] ---waiting for contribution.
  3. [QUICKSTART--The most important ways to use findlib] (http://projects.camlcity.org/projects/dl/findlib-1.3.1/doc/guide-html/quickstart.html). This page shows how findlib works and how to use it from the top-level and ocamlfind level.

OCaml installation

  1. OPAM quick install
  2. Installation Instructions from Real World OCaml book

Troubleshooting

Linux
Mac
Win

IDEs

  1. Turn your editor into a full fledged OCaml IDE
  2. OCaml-Top
  3. Eclipse
  1. EMACS with OCaml
  1. VIM with OCaml

VM images

  1. Ocaml 4.01 for MAC
  2. Cornell's Linux VM VirtualBox image (more info here)
  3. Princeton's Ubuntu VirtualBox VM (more info on the course's site )

Exercises

  1. 99 Problems (solved) in OCaml
  2. Examples and Exercises for the book "More OCaml"
  3. From UMass's CS691F Programming languages course
  4. Try OCaml

Tutorials

  1. From UMass's CS691F Programming languages course, at University of Massachusetts Amherst

  2. OCaml Core tutorials

  3. A Concise Introduction to Objective Caml, at Villanova University

  4. Beginner's guide to OCaml beginner's guides.

  5. CSE 130: Programming Languages Course, at University of California San Diego. Click on [Lectures] (http://cseweb.ucsd.edu/classes/wi11/cse130/) and [Discussion Notes] (http://cseweb.ucsd.edu/classes/wi11/cse130/). Have a look at Lec 7 (a pp presentation by Zach) for an inspiring introduction into map and fold.

  6. CS 3110 Fall 2013 :: Data Structures and Functional Programming, at Cornell University. The lecturing materials explain OCaml on the basis of the fundamental concepts of functional programming languages. For instance, [Lecture 4] (http://www.cs.cornell.edu/courses/CS3110/2011sp/lectures/lec04-types/types.htm) includes an excellent discussion of parameterized variant types.

  7. CIS 500: Software Foundations, at University of Pennsyvania. A Software Foundations course with strong emphasis on Types. The [OCaml Tutorial] (http://www.seas.upenn.edu/~cis500/cis500-f05/resources/seas-ocaml.html) includes a gentle introduction to the OCaml interactive top-level system and compilation in OCaml.

  8. [Tutorial: OCaml for scientific computation, at University of Southampton] (http://www.southampton.ac.uk/~fangohr/software/ocamltutorial/). Lecture 2 (Functions) includes an in-depth discussion of the concept of functions in programming languages.

  9. OCaml for the Skeptical, at University of Chicago. The [Course Material] (http://www2.lib.uchicago.edu/keith/ocaml-class/class-01.html) link takes you to OCaml in a Nutshell where you will find a tutorial. The Compiling and Running Programs section has some examples of compilation with command line options and discusses some make-like tools that look after dependencies.

  10. [COS 326 Functional Programming, at Princeton University] (http://www.cs.princeton.edu/~dpw/courses/cos326-12/info). The [Lectures] (http://www.cs.princeton.edu/~dpw/courses/cos326-12/lectures) link takes you to lectures slides.

  11. [Functional, at University of Wroclaw] (https://www.ii.uni.wroc.pl/~lukstafi/pmwiki/index.php?n=Functional.Functional) The focus of the course is on the foundations of Functional Programming. They use OCaml as an example of a funcional language. The Lectures and assigned material section contains examples of OCaml code with explanation of fundamental concepts such as type inference.

  12. [Programming in OCAML, at University of Innsbruck] (http://cl-informatik.uibk.ac.at/teaching/ss06/ocaml/schedule.php). The slides include a gentle introduction to Ocaml. For instance, transparences 2-up explain the use of the Formatter module in the printing data structures.

  13. [Theory of Programming Languages, at Wellesley College] (http://cs.wellesley.edu/~cs251/). OCaml is used to teach fundamental concepts (syntax, naming, state, data control, concurrency, nondeterminism, and types) of programming languages.

Tutorials in other languages

  1. [Introduction to OCaml] (http://habrahabr.ru/post/108529/) This is a basic introduction to OCaml in Russian (на русском языке).

  2. Metodologias de Programacion: Programacion Funcional, at Universidad Veracruzana, Mexico. This is a Functional Programming course based on OCaml and Lisp. The teaching materials (Notas) are in Spanish (en Español) and explained with the level of details and depth of book chapters.

  3. Introduction au langage OCaml in french

Three fundamental concepts of Functional Programming

To feel at home with OCaml and (any other Functional Language) it helps to have some understanding of types, recursion and Lambda Calculus as these three concepts are at the heart Functional Programming. The following links point to some introductory references.

  • Types

  • Recursion: A good discussion of how recursion is implemented at compiler level is presented in Section 5-4 (Subprogram Sequence Control, pages 147-178) of Programming Languages: Design and Implementation, Terrance W. Pratt, Prentice Hall, Inc, 1975.

  • Lambda Calculus: A Tutorial Introduction to the Lambda Calculus, Raul Rojas, FU Berlin, WS-97/98, is a nine-page concise introduction to Lambda Calculus.

Five of the most influential publications on Functional Languages

The content and length of this list is based on personal opinion.

  • A Basis for a Mathematical Theory of Computation, John McCarthy. In P. Braffort and D. Hirschberg, editors, Computer Programming and Formal Systems, North-Holland, 1963.

This is a seminal article on the topic....

  • Can Programming Be Liberated from the von Neumann Style? A Functional Style and Its Algebra of Programs, John Backus. Communications of the ACM, Aug 1978, V.21, N.8.

This article explains the influence of the von Neumann architecture on early programming languages such as Fortran and Algol. The author discusses the impact of the assignment statement on the way computation is conceived in these languages.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.