Documentation added for everything except the main programme