added docstrings for functions, enhanced some function logic, changed function names, updated license date.