added some function explanatory stuff