updated comments

updated the comments with the definitions of the functions and the
overall descriptions of the functions together.