Commented file with explanations of how the mechanics work.