Documentation and Cleanup

(minor) Wrote additional comments so I don't forget what a few
particular things do later on.