Moved some functions. Added some comment headers.