Cleaned up code a little
Added final comments to header