expanded OCaml links
[lambda.git] / offsite_reading.mdwn
1 Many off these links are to Wikipedia. You can learn a lot from such articles,
2 so long as you remember they may sometimes mislead or make mistakes. However, I
3 hope at this point in your education you'll have learned to be a guarded reader
4 even of authoritative treatises by eminent authors. So you shouldn't need any
5 Wikipedia-specific warnings.
6
7 For most readers, many bits of reading we point you to will be hairy in one way
8 or another. It may be aimed at audiences with more programming experience; it
9 may be aimed at audiences with specific logical background you don't yet have;
10 it may be aimed at audiences familiar with technical areas in linguistics you're
11 first encountering. Or perhaps several of these at once. We hope you will
12 already have mastered the skill of leveraged reading: getting what you can out
13 of an article you don't fully understand, so that you can discuss it with the rest of
14 the group and hopefully get to a point where you can read it again and
15 get more out of out. (Rinse and repeat.)
16
17
18 ## General issues about variables and binding in programming languages ##
19
20 *       [[!wikipedia Variable (programming) desc="Variables"]]
21 *       [[!wikipedia Variable shadowing]]
22 *       [[!wikipedia Scope (programming) desc="Variable scope"]]
23 *       [[!wikipedia Free variables and bound variables]]
24 *       [[!wikipedia Name binding]]
25 *       [[!wikipedia Name resolution]]
26 *       [[!wikipedia Parameter (computer science) desc="Function parameters"]]
27
28 ## Functions as values, etc ##
29
30 *       [[!wikipedia Higher-order function]]
31 *       [[!wikipedia First-class function]]
32 *       [[!wikipedia Closure (computer science) desc="Closures"]]
33 *       [[!wikipedia Currying]]
34
35 ## Functional vs imperative programming ##
36
37 *       [[!wikipedia Declarative programming]]
38 *       [[!wikipedia Functional programming]]
39 *       [[!wikipedia Purely functional]]
40 *       [[!wikipedia Referential transparency (computer science)]]
41 *       [[!wikipedia Imperative programming]]
42
43 ## Untyped lambda calculus and combinatory logic ##
44
45 *       [[!wikipedia Lambda calculus]]
46 *       [Chris Barker's Lambda Tutorial](http://homepages.nyu.edu/~cb125/Lambda)
47 *       [Lambda Animator](http://thyer.name/lambda-animator/)<p>
48 *       [[!wikipedia Haskell Curry]]
49 *       [[!wikipedia Moses Schönfinkel]]
50 *       [[!wikipedia Alonzo Church]]<p>
51 *       [[!wikipedia Combinatory logic]]
52 *       [Combinatory logic](http://plato.stanford.edu/entries/logic-combinatory/) at the Stanford Encyclopedia of Philosophy
53 *       [[!wikipedia SKI combinatory calculus]]<p>
54 *       [[!wikipedia B,C,K,W system]]
55 *       [[!wikipedia Church-Rosser theorem]]
56 *       [[!wikipedia Normalization property]]
57 *       [[!wikipedia Turing completeness]]<p>
58 *       [Scooping the Loop Snooper](http://www.cl.cam.ac.uk/teaching/0910/CompTheory/scooping.pdf), a proof of the undecidability of the halting problem in the style of Dr Seuss by Geoffrey K. Pullum
59 *       [[!wikipedia Church encoding]]
60
61 ## Learning Scheme ##
62
63 *       [[!wikipedia Scheme (programming language) desc="Wikipedia overview of Scheme"]]
64
65 *       If you are new to programming or if you have the patience to work through a textbook, you should work through a textbook. Some good choices are The Little Schemer book(s) we recommended for the seminar; and also:
66
67         +       [How to Design Programs](http://www.htdp.org/2003-09-26/), by Matthias Felleisen, et al., which the Racket groups recommends. Whenever the book says "Scheme," you can read it as "Racket."
68
69         Another warmly-recommended introduction available online is:
70
71         +       [Teach Yourself Scheme in Fixnum Days](http://www.ccs.neu.edu/home/dorai/t-y-scheme/t-y-scheme.html)
72
73 *       If you're already a programmer and you're in more of a hurry, you could instead look at the [Quick Introduction to Racket](http://docs.racket-lang.org/quick/index.html). This tutorial provides a brief introduction to the Racket programming language by using DrRacket and one of Racket's picture-drawing libraries.
74
75 *       [An Introduction to Lambda Calculus and Scheme](http://www.jetcafe.org/~jim/lambda.html) is also aimed at programmers.
76
77 *       After any of the preceding, you could move on to [Racket Guide](http://docs.racket-lang.org/guide/index.html). This starts with a tutorial on Racket basics; then it describes the rest of the Racket language. This guide is intended for programmers who are new to Racket or new to some part of Racket. It assumes programming experience, so if you are new to programming, you should instead start with one of the textbooks listed above. This Guide describes parts of the Racket language which go beyond the learning-oriented fragments of How to Design Programs.
78
79 *       The [Complete Racket Reference Manual](http://docs.racket-lang.org/reference/index.html) defines the core Racket language and describes its most prominent libraries. The Racket Guide is friendlier; though less precise and less complete.
80
81 *       The Scheme language is standardized; the various implementations of the
82 language usually adhere to what's published in the current standard and add on
83 different handy extensions. The first standard was published in 1975. A
84 revision was published in 1978 called "The revised report on Scheme, a
85 dialect of Lisp." Thereafter, revisions of the standard were titled "The
86 Revised Revised Report..." and so on, or "The Revised^n Report..." for
87 short, for increasing n. The most widely implemented standard is [The
88 Revised^5 Report on Scheme](http://docs.racket-lang.org/r5rs/index.html),
89 or R5RS, published in 1998.
90 \[ [Alt link](http://www.schemers.org/Documents/Standards/R5RS/HTML/) \]
91 A new standard [R6RS](http://docs.racket-lang.org/r6rs/index.html) was ratified
92 in 2007, but this has many detractors and has not been fully accepted in the
93 community.
94 \[ [Alt link](http://www.r6rs.org/final/html/r6rs/r6rs.html);
95 [Libraries](http://www.r6rs.org/final/html/r6rs-lib/r6rs-lib.html) \]
96
97 *       [Scheme FAQ](http://community.schemewiki.org/?scheme-faq)
98
99 *       [Scheme Requests for Implementation](http://srfi.schemers.org/) (SRFI)
100
101 *       The [Schematics Scheme Cookbook](http://schemecookbook.org/) is a collaborative effort to produce documentation and recipes for using Scheme for common tasks.
102
103
104 ## Recursion and the Y Combinator ##
105
106 *       [[!wikipedia Recursion (computer science) desc="Recursion"]]
107 *       [[!wikipedia Y combinator]]
108 *       [Chapter 9 from The Little Schemer](http://www.ccs.neu.edu/home/matthias/BTLS/sample.ps) on the Y Combinator "...and Again, and Again, and Again..."
109 *       [The Y combinator](http://mvanier.livejournal.com/2700.html)
110 *       [The Y Combinator (Slight Return), or: How to Succeed at Recursion Without Really Recursing](http://mvanier.livejournal.com/2897.html)
111 *       [Y Combinator for Dysfunctional Non-Schemers](http://rayfd.wordpress.com/2007/05/06/y-combinator-for-dysfunctional-non-schemers/)
112 *       [The Y Combinator](http://www.ece.uc.edu/~franco/C511/html/Scheme/ycomb.html)
113 *       [The Y Combinator](http://dangermouse.brynmawr.edu/cs245/ycomb_jim.html), described as:
114         > This is the derivation of the applicative-order Y-combinator from scratch, in Scheme. The following derivation is similar in flavor to the derivation found in The Little LISPer by Friedman/Felleisen, but uses a slightly different starting approach...
115
116 ## Evaluation Order ##
117
118 *       [[!wikipedia Evaluation strategy]]
119 *       [[!wikipedia Eager evaluation]]
120 *       [[!wikipedia Lazy evaluation]]
121 *       [[!wikipedia Strict programming language]]
122
123
124 ## Types ##
125
126 *       [[!wikipedia Tagged union]]
127 *       [[!wikipedia Algebraic data type]]
128 *       [[!wikipedia Pattern matching]]
129 *       [[!wikipedia Unit type]]
130 *       [[!wikipedia Bottom type]]
131 *       [[!wikipedia Typed lambda calculus]]
132 *       [[!wikipedia Simply typed lambda calculus]]
133 *       [Type Theory](http://plato.stanford.edu/entries/type-theory/) at the Stanford Encyclopedia of Philosophy
134 *       [Church's Type Theory](http://plato.stanford.edu/entries/type-theory-church/) at the Stanford Encyclopedia of Philosophy
135 *       The [[!wikipedia Curry-Howard isomorphism]]
136 *       [The Curry-Howard correspondence in Haskell](http://www.thenewsh.com/~newsham/formal/curryhoward/)<p>
137 *       [[!wikipedia Type polymorphism]]
138 *       [[!wikipedia System F]]
139
140 ## Learning OCaml ##
141
142 *       [[!wikipedia Objective Caml desc="Wikipedia overview of OCaml"]]
143
144 *       [A Concise Introduction to Objective Caml](http://www.csc.villanova.edu/~dmatusze/resources/ocaml/ocaml.html)
145
146 *       Here are [two](http://www.cs.jhu.edu/~scott/pl/lectures/caml-intro.html) [other](http://pauillac.inria.fr/caml/FAQ/stephan.html) bried overviews of OCaml, aimed at readers who already have some programming experience.
147
148 *       Here's a [more detailed tutorial](http://www.ocaml-tutorial.org/) for OCaml.
149
150 *       Jason Hickey has posted a [draft of a nice book introducing OCaml](http://www.cs.caltech.edu/courses/cs134/cs134b/book.pdf).
151
152
153 ## Side-effects / mutation ##
154
155 *       [[!wikipedia Side effect (computer science) desc="Side effects"]]
156 *       [[!wikipedia Reference (computer science) desc="References"]]
157 *       [[!wikipedia Pointer (computing) desc="Pointers"]]
158
159 ## Monads ##
160
161 *       [[!wikipedia Monad (functional programming) desc="Monads in Functional Programming"]]
162
163 *       [A Gentle Intro to Haskell: About Monads](http://www.haskell.org/tutorial/monads.html)
164
165 *       [Understanding Haskell Monads](http://ertes.de/articles/monads.html)
166
167 *       [The State Monad: a tutorial for the confused?](http://coder.bsimmons.name/blog/2009/10/the-state-monad-a-tutorial-for-the-confused/)
168
169 *       [Beyond Monads](http://blog.sigfpe.com/2009/02/beyond-monads.html)
170
171 *       [Simple Explanation of a Monad](http://math.stackexchange.com/questions/405/simple-explanation-of-a-monad)
172
173 *       [What is a Monad?](http://stackoverflow.com/questions/44965/what-is-a-monad)
174
175 *       [Can Anyone Explain Monads?](http://stackoverflow.com/questions/2366/can-anyone-explain-monads)
176
177 *       [Monad in Plain English...](http://stackoverflow.com/questions/2704652/monad-in-plain-english-for-the-oop-programmer-with-no-fp-background)
178
179 *       [Monad in non-programming terms](http://stackoverflow.com/questions/3261729/monad-in-non-programming-terms)
180
181 *       [Real World Haskell: chapter on Monads](http://book.realworldhaskell.org/read/monads.html)
182
183 *       [Learn You a Haskell for Great Good: chapter on Functors, Applicative Functors and Monoids](http://www.learnyouahaskell.com/functors-applicative-functors-and-monoids)
184
185 *       Monads are Elephants:
186 [Part 1](http://james-iry.blogspot.com/2007/09/monads-are-elephants-part-1.html)
187 [Part 2](http://james-iry.blogspot.com/2007/10/monads-are-elephants-part-2.html)
188 [Part 3](http://james-iry.blogspot.com/2007/10/monads-are-elephants-part-3.html)
189 [Part 4](http://james-iry.blogspot.com/2007/11/monads-are-elephants-part-4.html)
190
191 *       [Brian Beckman: Don't fear the Monad (67 minute video)](http://channel9.msdn.com/shows/Going+Deep/Brian-Beckman-Dont-fear-the-Monads/)
192
193 *       [A monad non-tutorial...or why you shouldn't ask what a monad is](http://strongtyped.blogspot.com/2010/01/monad-non-tutorial.html)
194
195 *       [The Mother of all Monads](http://blog.sigfpe.com/2008/12/mother-of-all-monads.html)
196
197 *       [You Could Have Invented Monads! (And Maybe You Already Have.)](http://blog.sigfpe.com/2006/08/you-could-have-invented-monads-and.html)
198
199 *       [Monads! (and Why Monad Tutorials Are All Awful)](http://ahamsandwich.wordpress.com/2007/07/26/monads-and-why-monad-tutorials-are-all-awful/)
200
201 *       [Of monads and spacesuits (archived)](http://www.iterasi.net/openviewer.aspx?sqrlitid=ixx7fcluvek_9lfolsxr_g)
202
203 *       [Haskell wikibook: Understanding monads](http://en.wikibooks.org/wiki/Haskell/Understanding_monads)
204
205 *       Haskell state monads: [part 1](http://mvanier.livejournal.com/1765.html) [part 2](http://mvanier.livejournal.com/1901.html)
206
207 *       [How not to explain Haskell monads](http://mvanier.livejournal.com/1205.html)
208
209 *       Yet Another Monad Tutorial: [part 1](http://mvanier.livejournal.com/3917.html) [part 2](http://mvanier.livejournal.com/4305.html)
210         [part 3](http://mvanier.livejournal.com/4586.html) [part 4](http://mvanier.livejournal.com/4647.html)
211
212 *       [Research Papers/Monads and Arrows](http://www.haskell.org/haskellwiki/Research_papers/Monads_and_arrows)
213
214 *       [Philip Wadler. Monads for Functional Programming](http://homepages.inf.ed.ac.uk/wadler/papers/marktoberdorf/baastad.pdf):
215 in M. Broy, editor, *Marktoberdorf Summer School on Program Design Calculi*, Springer Verlag, NATO ASI Series F: Computer and systems sciences, Volume 118, August 1992. Also in J. Jeuring and E. Meijer, editors, *Advanced Functional Programming*, Springer Verlag, LNCS 925, 1995. Some errata fixed August 2001.
216
217         The use of monads to structure functional programs is described. Monads provide a convenient framework for simulating effects found in other languages, such as global state, exception handling, output, or non-determinism. Three case studies are looked at in detail: how monads ease the modification of a simple evaluator; how monads act as the basis of a datatype of arrays subject to in-place update; and how monads can be used to build parsers.
218
219 *       [Philip Wadler. The essence of functional programming](http://homepages.inf.ed.ac.uk/wadler/papers/essence/essence.ps):
220 invited talk, *19'th Symposium on Principles of Programming Languages*, ACM Press, Albuquerque, January 1992.
221
222         This paper explores the use monads to structure functional programs. No prior knowledge of monads or category theory is required.
223
224         Monads increase the ease with which programs may be modified. They can mimic the effect of impure features such as exceptions, state, and continuations; and also provide effects not easily achieved with such features. The types of a program reflect which effects occur.
225
226         The first section is an extended example of the use of monads. A simple interpreter is modified to support various extra features: error messages, state, output, and non-deterministic choice. The second section describes the relation between monads and continuation-passing style. The third section sketches how monads are used in a compiler for Haskell that is written in Haskell.
227
228 ## Monads in Category Theory ##
229
230 *       [Category Theory at SEP](http://plato.stanford.edu/entries/category-theory/)
231 *       [[!wikipedia Category theory]]
232 *       [[!wikipedia Category (mathematics) desc="Category"]]
233 *       [[!wikipedia Morphism]]
234 *       [[!wikipedia Functor]]
235 *       [[!wikipedia Natural transformation]]
236 *       [[!wikipedia Monad (category theory) desc="Monads in category theory"]]
237 *       [Haskell/Category Theory](http://en.wikibooks.org/wiki/Haskell/Category_theory)
238 *       [Category Theory & Functional Programming](http://blog.mestan.fr/2009/01/09/category-theory-functional-programming/)
239 *       [Learning Haskell through Category Theory, and Adventuring in Category Land](http://dekudekuplex.wordpress.com/2009/01/16/learning-haskell-through-category-theory-and-adventuring-in-category-land-like-flatterland-only-about-categories/)
240 *       [Resources for learning practical category theory](http://mathoverflow.net/questions/903/resources-for-learning-practical-category-theory)
241 *       [A Partial Ordering of some Category Theory applied to Haskell](http://blog.sigfpe.com/2010/03/partial-ordering-of-some-category.html)
242
243
244 ## Continuations ##
245
246 *       [[!wikipedia Continuation]]
247 *       [[!wikipedia Continuation-passing style]]
248 *       [[!wikipedia Call-with-current-continuation]]
249 *       [Intro to call/cc](http://community.schemewiki.org/?call-with-current-continuation) at SchemeWiki
250 *       [[!wikipedia Delimited continuation]]
251 *       [Delimited/composable continuations tutorial](composable-continuations-tutorial) at SchemeWiki
252
253 *       [Call With Current Continuation](http://www.c2.com/cgi/wiki?CallWithCurrentContinuation)
254
255 *       [Continuations Made Simple and Illustrated](http://www.ps.uni-saarland.de/~duchier/python/continuations.html)
256
257 *       [Continuation kata](http://programming-musings.org/2006/02/12/continuation-kata/)
258
259 *       [Understanding continuations](http://keithdevens.com/weblog/archive/2004/Jul/11/continuations) [Commentary](http://lambda-the-ultimate.org/node/86)
260
261 *       http://en.wikipedia.org/wiki/Continuation
262
263 *       http://www.haskell.org/haskellwiki/Continuation
264
265 *       [Continuations In Scheme](http://tech.phillipwright.com/2010/05/23/continuations-in-scheme/)
266
267 *       [Understanding Scheme Continuations](http://sanjaypande.blogspot.com/2004/06/understanding-scheme-continuations.html). This is tagged "Part I" but I think there's no further parts.
268
269 *       [Continuations for Curmudgeons](http://www.intertwingly.net/blog/2005/04/13/Continuations-for-Curmudgeons) [Commentary](http://lambda-the-ultimate.org/node/643)
270
271 *       [composable-continuations-tutorial](http://community.schemewiki.org/?composable-continuations-tutorial)
272
273 *       [Post by Ken on Lambda the Ultimate explaining difference btw undelimited and delimited continuations](http://lambda-the-ultimate.org/node/1197#comment-12927)
274
275 *       [shift, reset and streams](http://chneukirchen.org/blog/archive/2005/04/shift-reset-and-streams.html)
276
277 *       [guile and delimited continuations](http://www.wingolog.org/archives/2010/02/26/guile-and-delimited-continuations)
278
279 *       [Delimited continuations in Scala](http://blog.richdougherty.com/2009/02/delimited-continuations-in-scala_24.html)
280
281 *       [Delimited Continuations Explained (in Scala)](http://dcsobral.blogspot.com/2009/07/delimited-continuations-explained-in.html)
282
283 *       [Partial Continuations](http://www.bluishcoder.co.nz/articles/scheme/partial-continuations.html)
284
285 *       [Online Bibliography of Scheme Research: Continuations and Continuation Passing Style](http://library.readscheme.org/page6.html)
286
287 *       Delimited Continuations in MzScheme:
288 [Part 1](http://schemekeys.blogspot.com/2006/11/prompts-their-interaction-with-dynamic.html)
289 [Part 2](http://schemekeys.blogspot.com/2006/12/delimited-continuations-in-mzscheme.html)
290 [Part 3](http://schemekeys.blogspot.com/2007/01/going-further-with-primitives.html)
291 [Part 4](http://schemekeys.blogspot.com/2007/01/odd-and-ends.html)
292
293 *       [Delimited continuations in natural language semantics](http://okmij.org/ftp/gengo/)
294
295
296 ## Linear Logic ##
297
298 *       [[!wikipedia Linear logic]]
299
300