Edited Martin's initial GitHub contribution for LaTeX formatting and references.