Finished

Added comments throughout, and changed a few things.