Extract support code to separate files
Remove some comments to make code fit into single-page handout form