Add documentation for several functions