Documentation

Adds docstrings and a first draft of a user manual.
It's even declared twice, for crying out loud.