added some comments to functions