renaming of functions
add documentation
whitespace cleanup