Added docstrings to sage functions