Caml
Power

Schedule

Warning: The schedule below is only approximate. It will almost certainly change --- we make no promises. Amended lectures notes that better reflect the content of the lecture may be posted after class.

Note: reading assigments in "RWO" refer to the Real World OCaml book, which is also available online.

Dates Topic Notes/Code Reading
The Basics
W Sep 14 Course Introduction Course Intro -
W Sep 14 OCaml Introduction OCaml Intro, hello.ml, sum.ml, Makefile, .merlin Functional Basics, Type Checking, Optional: RWO pp 1-10
Th Sep 15 Precept 1: OCaml Intro assert.ml ticket.ml .merlin fizzbuzz.ml exercise1.ml (Dropbox)
M Sep 19 Simple Immutable Data: Variables, Tuples, Options Let, Tuples, Unit, Options; Type-directed Programming;
Optional: RWO Chap 2
W Sep 21 Thinking Inductively Induction, Lists and Nats Thinking Inductively;
Optional: RWO Chap 3
W Sep 21 Assign 1 Due
Th Sep 22 Precept 2: Lists merge.ml exercise2.ml (Dropbox)
M Sep 26 Poly-HO: Polymorphism and Higher-Order Programming Inductive programming with the Naturals; Poly-HO Polymorphism and Higher-order Programming
W Sep 28 Datatypes and Functional Design Lists and Pipe; Datatypes pipeline.ml Optional: RWO Chapter 6
W Sep 28 Assign 2 Due
Th Sep 29 Precept 3: Assignment 3, Map, Fold and Datatypes exercise3.ml (Dropbox)
Reasoning About Programs
M Oct 3 Datatype design and Error Processing Datatype Design; gml.ml; Error Processing; Evaluation Optional: Blog on F#, Error Processing and Functional Design;
Optional: RWO Chapter 7;
Operational Semantics
W Oct 5 Evaluation and Proving Programs Correct OCaml Interpreter; interpreter code: eval0.ml; with recursive functions: eval3.ml Equational Reasoning
Th Oct 6 Precept 4: Datatypes, Equational Reasoning exercise4.ml (Dropbox)
M Oct 10 Proving Programs Correct Proofs about Programs; Permutations
W Oct 12 Space Model Space Model
W Oct 12 Assign 3 Due
Th Oct 13 Precept 5: Closures and More Equational Reasoning exercise5.ml (solution)
M Oct 17 Continuation-Passing Style Continuation-passing Style; tail.ml; tree_increment_cps.ml; assert.ml Equational Reasoning about Natural Numbers and Trees;
Optional Reading: Odd-Order Theorem;
Four-Color Theorem;
tree-increment-cps.ml
W Oct 19 Proofs about data types Proofs about Datatypes
W Oct 19 Assign 4 Due
Th Oct 20 Precept 6: Tail Recursion and More Equational Reasoning Map CPS Proof Example; Reverse Generalized Proof Example; exercise6.ml (Solution: code, proofs)
Modularity
M Oct 24 Modules Modules (not on the midterm)
W Oct 26 Midterm Exam
Fall Break
M Nov 14 Invited Lecturer: Yaron Minsky, Jane St Capital Effective ML -
W Nov 9 Reasoning about Modules Representation Invariants and Abstraction Functions, RWO: Optional: Chap 4 (Modules), 9 (Functors); Optional: Abstraction and Representation Invariants
T Nov 10 Precept 7: Midterm recap Solutions
Effects, Parallelism and Concurrency
M Nov 14 References Reference Types Optional: RWO Chapter 8
W Nov 16 Streams and Lazy Evaluation Streams Inf.mli, Inf.ml, Main.ml
T Nov 17 Precept 8: Modules range.mli ; exercise.txt ; range.ml implementation(s) ; proofs for LoHiPairRange
M Nov 21 Parallelism Intro Call-by-Name vs Call-by-Value vs Lazy; Parallelism and Threads Using threads and futures
M Nov 21 Assign 5 Due (this is the new extended deadline!)
Thanksgiving Break
M Nov 28 Futures, Threads, and Locks Futures and locks Using threads and futures
W Nov 30 Parallel Complexity Parallel complexity; Parallel Collections Parallel Complexity Models, Parallel Scheduling
Th Dec 1 Precept 9: References and Futures range.mli;
exercise.txt
M Dec 5 Parallel Sequences Parallel Collections Parallel Sequences, Optional Reading: NESL
M Dec 5 Assign 6 Due
W Dec 7 Haskell Parallelism and A7 Assignment 7
Th Dec 8 Precept 10: Functional data type proof of correctness bst.ml ; proofs from precept ; exercise.txt Modules II lecture notes
F Dec 9 Final Assignment Handout: Due Dean's Date
M Dec 12 Haskell Haskell Optional Reading: Learn you a Haskell for Great Good
W Dec 14 Software Transactional Memory Haskell STM and COS 510 Haskell STM; 510 Preview: Preface and Basics
T Dec 15 Precept 11: Map/Reduce Parallel lecture notes: (20) and (21)
Winter Break
T Jan 17 Dean's Date: Assign 7 Due at 4:59pm
Th Jan 26, 7:30pm Final Exam: McCosh Hall 46