Lecture 2: LF Type Theory
Code
Lecture plan
- LF type theory (minus lambda)
- Datatype encodings and (informal) adequacy
Exercises
- Come up with a second proof that
(node (node leaf leaf) (node leaf leaf))
is balanced.
- Come up with both an extrinsic and intrinsic encoding for AVL trees. Show
that the extrinsic encoding is not adequate, and that the intrinsic one
is.
- Exercise (bonus): can you describe a type theory that “stratifies” the
levels of [syntax, judgments, theorems], all of which LF uses dependent
functions to represent? What would the advantages/disadvantages be?
Further reading