beginning to write better inline documentation. needs a lot of work.