Closes #43, tests passing, documentation written