Added doc strings to all the functions... not much left to do.